[PATCH] tevent glib event loop glue

Ralph Boehme rb at sernet.de
Mon Feb 22 19:40:56 UTC 2016

On Mon, Feb 22, 2016 at 07:19:36PM +0000, Noel Power wrote:
> On 16/02/16 10:04, Ralph Boehme wrote:
> > Hi,
> >
> > On Mon, Feb 15, 2016 at 04:56:21PM +0100, Ralph Boehme wrote:
> >> On Sat, Feb 13, 2016 at 09:38:19AM +0100, Stefan Metzmacher wrote:
> >>>> Attached is a patchset that adds support for polling a glib
> >>>> g_main_context from tevent. Later commits make use of it in the mdsvc
> >>>> RPC server.
> >>>>
> >>>> The second patch adds a test binary that can be used to run query
> >>>> Gnome Tracker either using the native glib event loop or tevent.
> >>>>
> >>>> I'm still unsure whether we want this added directly to tevent at this
> >>>> early stage, or instead better put it to source3/lib/. It makes no
> >>>> difference for Samba internal consumers.
> >>> I'd prefer to keep in Samba only for now (as
> >>> lib/util/tevent_glib_glue.[ch]) and adding a 'samba_' prefix to the
> >>> public function,so that we won't conflict, if we later also add this
> >>> to tevent.
> >> Updated patchset attached.
> >>
> >> Please review&push if ok. Thanks!
> > attached is an updated patchset with a slightly modified build: the
> > tevent-glib-glue subsytem is only enabled if requested by other
> > components like the mdssvc RPC service that require it.
> >
> Well, I'd like to ask we hold off committing this (at least until the
> attached patches are evaluated), I've discovered an issue that leads me
> to believe that the current implementation wont work. I've come to the
> conclusion that actually going back to the idea of using trace callbacks
> is probably the only viable solution. The main problem with the current
> solution is that if any glib event sources are modified/created/deleted
> in the context of a tevent handler that isn't associated with the
> integration implementation then we don't pick up any of those
> changes

hm. I haven't yet fully wrapped my head around this, but I'd say that
that simply constitutes an illegal API usage. I'll take a closer look


SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen

More information about the samba-technical mailing list