Re: [RFC 5/7] Deprecate virConnectNumOfDomains()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2018-10-02 at 16:43 +0200, Peter Krempa wrote:
> On Tue, Oct 02, 2018 at 16:14:44 +0200, Andrea Bolognani wrote:
[...]
> > @@ -97,6 +97,11 @@ virConnectNumOfDomains(virConnectPtr conn)
> >          int ret = conn->driver->connectNumOfDomains(conn);
> >          if (ret < 0)
> >              goto error;
> > +
> > +        virReportWarning(VIR_ERR_DEPRECATED_FEATURE,
> > +                         "%s",
> > +                         "virConnectNumOfDomains()");
> > +        virDispatchError(conn);
> 
> I don't think our API contract allows for reporting an error AND
> returning success. And even if we didn't specify it it's pretty much
> assumed right now, so I'm not in support of this.

I'm afraid I don't have a very good answer for this concern, as
for the most part I share it.

This is the best I could come up with on my own; hopefully other
developers such as yourself will contribute to the discussion and
we'll collectively come up with something much better :)

-- 
Andrea Bolognani / Red Hat / Virtualization

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux