[jira] [Resolved] (OWB-1393) OWB stops firing ProcessObserverMethods event, when Extension with non system event observer exists

2021-12-12 Thread Mark Struberg (Jira)


 [ 
https://issues.apache.org/jira/browse/OWB-1393?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mark Struberg resolved OWB-1393.

Fix Version/s: 2.0.25
   (was: 2.0.24)
   Resolution: Fixed

> OWB stops firing ProcessObserverMethods event, when Extension with non system 
> event observer exists
> ---
>
>         Key: OWB-1393
> URL: https://issues.apache.org/jira/browse/OWB-1393
> Project: OpenWebBeans
>  Issue Type: Bug
>Affects Versions: 2.0.23
>Reporter: Arne Limburg
>Assignee: Arne Limburg
>Priority: Major
> Fix For: 2.0.25
>
>
> When an extension is in the classpath, that observes an event that is no 
> system event (like org.apache.cxf.cdi.JAXRSCdiResourceExtension), every 
> extension that is registered after that extension will not receive 
> ProcessObserverMethod events any more.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Reopened] (OWB-1393) OWB stops firing ProcessObserverMethods event, when Extension with non system event observer exists

2021-12-12 Thread Mark Struberg (Jira)


 [ 
https://issues.apache.org/jira/browse/OWB-1393?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mark Struberg reopened OWB-1393:


It appears that this still randomly happens. Just got this in my local build.

> OWB stops firing ProcessObserverMethods event, when Extension with non system 
> event observer exists
> ---
>
>         Key: OWB-1393
> URL: https://issues.apache.org/jira/browse/OWB-1393
> Project: OpenWebBeans
>  Issue Type: Bug
>Affects Versions: 2.0.23
>Reporter: Arne Limburg
>Assignee: Arne Limburg
>Priority: Major
> Fix For: 2.0.24
>
>
> When an extension is in the classpath, that observes an event that is no 
> system event (like org.apache.cxf.cdi.JAXRSCdiResourceExtension), every 
> extension that is registered after that extension will not receive 
> ProcessObserverMethod events any more.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


Re: OWB-1393

2021-11-24 Thread Jean-Louis MONTEIRO
Thanks Romain, I'll proceed with a release then

Le mer. 24 nov. 2021 à 08:47, Romain Manni-Bucau  a
écrit :

> Hi all,
>
> since TomEE is blocked since some weeks due to this issue and I didn't get
> much feedback I went ahead and pushed the proposed patch, feel free to
> review/comment if there is any issue.
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le ven. 15 oct. 2021 à 11:27, Arne Limburg 
> a écrit :
>
> > Hi Romain,
> >
> > now I understand your point and it sounds valid. I can take a deeper look
> > into it this weekend, but feel free to change it by yourself,  if you
> want.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> > Fax: +49 441 - 4082-111
> > arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> > www.openknowledge.de<
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> > >
> > Registergericht: Amtsgericht Oldenburg, HRB 4670
> > Geschäftsführer: Lars Röwekamp, Jens Schumann
> >
> > Treffen Sie uns auf kommenden Konferenzen und Workshops:
> > Zu unseren Events<
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> > >
> >
> > Von: Romain Manni-Bucau 
> > Datum: Montag, 11. Oktober 2021 um 20:51
> > An: openwebbeans-dev 
> > Betreff: Re: OWB-1393
> > Le lun. 11 oct. 2021 à 20:13, Arne Limburg <
> arne.limb...@openknowledge.de>
> > a écrit :
> >
> > > Hi Romain,
> > >
> > > The cache in question explicitly caches extensions per lifecycle event,
> > so
> > > a check for isContainerEvent would not helb. We could completely
> disable
> > > that cache, but I’m afraid, that would decrease startup performance
> even
> > > more. I guess, it is good to know, which extension observes
> > > ProcessAnnotatedType events and which doesn’t.
> > >
> >
> > Yes, please don't disable that cache which helps to startup faster when
> > using extensions with several beans.
> > Point was more:
> >
> > for (method: methods) { if (is container) {} }
> > for (method: methods) { if (!is container) {} }
> >
> > versus
> >
> > for (method: filter(methods)) { if (!is container) { } else { define();
> } }
> >
> > Know it is only #extensions x #methods so likely not crazy but sounds
> more
> > natural to prepare the runtime in one pass for this no?
> > Concretely it would be something like
> > https://gist.github.com/rmannibucau/c0e9f4020c01ddb9465cad373ccbe1b6 or
> > https://gist.github.com/rmannibucau/b0cff6375af78d3702b5a2c7b8a6a99c if
> > you
> > want to bypass container event test for "not extension" instances (can
> save
> > a few tests).
> >
> > Concretely your fix ensures that any extension can catch a container
> > lifecycle event issued of another observer definition which is good but
> > keeps the issue that you can still miss event from another extension.
> > Basically it is the same issue between extensions but for normal events.
> >
> > So I think we should just delay
> >
> > GProcessObserverMethod event = new
> > GProcessObserverMethod(webBeansContext, annotatedMethod, observer);
> > webBeansContext.getBeanManagerImpl().fireEvent(event, true,
> > AnnotationUtil.EMPTY_ANNOTATION_ARRAY);
> >
> >
> > to happen after all observers are defined.
> >
> > So overall I'd be to:
> >
> > 0. we keep the cache during the startup ;)
> > 1. keep the observer definition a single loop
> > 2. move the process observer met

Re: OWB-1393

2021-11-23 Thread Romain Manni-Bucau
Hi all,

since TomEE is blocked since some weeks due to this issue and I didn't get
much feedback I went ahead and pushed the proposed patch, feel free to
review/comment if there is any issue.

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le ven. 15 oct. 2021 à 11:27, Arne Limburg 
a écrit :

> Hi Romain,
>
> now I understand your point and it sounds valid. I can take a deeper look
> into it this weekend, but feel free to change it by yourself,  if you want.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Montag, 11. Oktober 2021 um 20:51
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> Le lun. 11 oct. 2021 à 20:13, Arne Limburg 
> a écrit :
>
> > Hi Romain,
> >
> > The cache in question explicitly caches extensions per lifecycle event,
> so
> > a check for isContainerEvent would not helb. We could completely disable
> > that cache, but I’m afraid, that would decrease startup performance even
> > more. I guess, it is good to know, which extension observes
> > ProcessAnnotatedType events and which doesn’t.
> >
>
> Yes, please don't disable that cache which helps to startup faster when
> using extensions with several beans.
> Point was more:
>
> for (method: methods) { if (is container) {} }
> for (method: methods) { if (!is container) {} }
>
> versus
>
> for (method: filter(methods)) { if (!is container) { } else { define(); } }
>
> Know it is only #extensions x #methods so likely not crazy but sounds more
> natural to prepare the runtime in one pass for this no?
> Concretely it would be something like
> https://gist.github.com/rmannibucau/c0e9f4020c01ddb9465cad373ccbe1b6 or
> https://gist.github.com/rmannibucau/b0cff6375af78d3702b5a2c7b8a6a99c if
> you
> want to bypass container event test for "not extension" instances (can save
> a few tests).
>
> Concretely your fix ensures that any extension can catch a container
> lifecycle event issued of another observer definition which is good but
> keeps the issue that you can still miss event from another extension.
> Basically it is the same issue between extensions but for normal events.
>
> So I think we should just delay
>
> GProcessObserverMethod event = new
> GProcessObserverMethod(webBeansContext, annotatedMethod, observer);
> webBeansContext.getBeanManagerImpl().fireEvent(event, true,
> AnnotationUtil.EMPTY_ANNOTATION_ARRAY);
>
>
> to happen after all observers are defined.
>
> So overall I'd be to:
>
> 0. we keep the cache during the startup ;)
> 1. keep the observer definition a single loop
> 2. move the process observer method event firing after all extensions
> observers definition if possible (means that worse case some vetoed
> observer will be executed during this time but it is unlikely and we can't
> help that anyway, even replaying the missed observers - because not yet
> there - once added)
>
> Hope it makes more sense phrased this way and it is not too late to write a
> technical mail ;).
>
>
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> > Fax: +49 441 - 4082-111
> > arne.limb...@openknowle

AW: OWB-1393

2021-10-15 Thread Arne Limburg
Hi Romain,

now I understand your point and it sounds valid. I can take a deeper look into 
it this weekend, but feel free to change it by yourself,  if you want.

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Romain Manni-Bucau 
Datum: Montag, 11. Oktober 2021 um 20:51
An: openwebbeans-dev 
Betreff: Re: OWB-1393
Le lun. 11 oct. 2021 à 20:13, Arne Limburg 
a écrit :

> Hi Romain,
>
> The cache in question explicitly caches extensions per lifecycle event, so
> a check for isContainerEvent would not helb. We could completely disable
> that cache, but I’m afraid, that would decrease startup performance even
> more. I guess, it is good to know, which extension observes
> ProcessAnnotatedType events and which doesn’t.
>

Yes, please don't disable that cache which helps to startup faster when
using extensions with several beans.
Point was more:

for (method: methods) { if (is container) {} }
for (method: methods) { if (!is container) {} }

versus

for (method: filter(methods)) { if (!is container) { } else { define(); } }

Know it is only #extensions x #methods so likely not crazy but sounds more
natural to prepare the runtime in one pass for this no?
Concretely it would be something like
https://gist.github.com/rmannibucau/c0e9f4020c01ddb9465cad373ccbe1b6 or
https://gist.github.com/rmannibucau/b0cff6375af78d3702b5a2c7b8a6a99c if you
want to bypass container event test for "not extension" instances (can save
a few tests).

Concretely your fix ensures that any extension can catch a container
lifecycle event issued of another observer definition which is good but
keeps the issue that you can still miss event from another extension.
Basically it is the same issue between extensions but for normal events.

So I think we should just delay

GProcessObserverMethod event = new
GProcessObserverMethod(webBeansContext, annotatedMethod, observer);
webBeansContext.getBeanManagerImpl().fireEvent(event, true,
AnnotationUtil.EMPTY_ANNOTATION_ARRAY);


to happen after all observers are defined.

So overall I'd be to:

0. we keep the cache during the startup ;)
1. keep the observer definition a single loop
2. move the process observer method event firing after all extensions
observers definition if possible (means that worse case some vetoed
observer will be executed during this time but it is unlikely and we can't
help that anyway, even replaying the missed observers - because not yet
there - once added)

Hope it makes more sense phrased this way and it is not too late to write a
technical mail ;).


>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<<http://www.openknowledge.de%3c>
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Montag, 11. Oktober 2021 um

Re: OWB-1393

2021-10-11 Thread Romain Manni-Bucau
Le lun. 11 oct. 2021 à 20:13, Arne Limburg 
a écrit :

> Hi Romain,
>
> The cache in question explicitly caches extensions per lifecycle event, so
> a check for isContainerEvent would not helb. We could completely disable
> that cache, but I’m afraid, that would decrease startup performance even
> more. I guess, it is good to know, which extension observes
> ProcessAnnotatedType events and which doesn’t.
>

Yes, please don't disable that cache which helps to startup faster when
using extensions with several beans.
Point was more:

for (method: methods) { if (is container) {} }
for (method: methods) { if (!is container) {} }

versus

for (method: filter(methods)) { if (!is container) { } else { define(); } }

Know it is only #extensions x #methods so likely not crazy but sounds more
natural to prepare the runtime in one pass for this no?
Concretely it would be something like
https://gist.github.com/rmannibucau/c0e9f4020c01ddb9465cad373ccbe1b6 or
https://gist.github.com/rmannibucau/b0cff6375af78d3702b5a2c7b8a6a99c if you
want to bypass container event test for "not extension" instances (can save
a few tests).

Concretely your fix ensures that any extension can catch a container
lifecycle event issued of another observer definition which is good but
keeps the issue that you can still miss event from another extension.
Basically it is the same issue between extensions but for normal events.

So I think we should just delay

GProcessObserverMethod event = new
GProcessObserverMethod(webBeansContext, annotatedMethod, observer);
webBeansContext.getBeanManagerImpl().fireEvent(event, true,
AnnotationUtil.EMPTY_ANNOTATION_ARRAY);


to happen after all observers are defined.

So overall I'd be to:

0. we keep the cache during the startup ;)
1. keep the observer definition a single loop
2. move the process observer method event firing after all extensions
observers definition if possible (means that worse case some vetoed
observer will be executed during this time but it is unlikely and we can't
help that anyway, even replaying the missed observers - because not yet
there - once added)

Hope it makes more sense phrased this way and it is not too late to write a
technical mail ;).


>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Montag, 11. Oktober 2021 um 08:22
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> +1 looks good.
>
> out of curiosity: did you think about using isContainerEvent to check if
> the cache should be setup? wonder if it moves from o(2n) to o(n) the
> complexity (but for an extension n is generally not that crazy not
> shouldn't change drastically the startup).
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le dim. 10 oct. 2021 à 22:12, Arne Limburg 
> a écrit :
>
> > I have pushed a version to the branch OWB-1393.
> >
> > Feel free to take a look at it. If it looks ok, I can merge it tomorrow.
> > With this version we don’t have to touch the cache, simply registering
> the
> > lifecycle observer methods first and only after all lifecycle observer
> > methods of all extensions are registered, registering the non lifecycle
> > observer methods of the extensions (which then throws the
> > ProcessObserverMethod events and correctly sets up the cache).
> >
> > Cheers,
> > A

AW: OWB-1393

2021-10-11 Thread Arne Limburg
Hi Romain,

The cache in question explicitly caches extensions per lifecycle event, so a 
check for isContainerEvent would not helb. We could completely disable that 
cache, but I’m afraid, that would decrease startup performance even more. I 
guess, it is good to know, which extension observes ProcessAnnotatedType events 
and which doesn’t.

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Romain Manni-Bucau 
Datum: Montag, 11. Oktober 2021 um 08:22
An: openwebbeans-dev 
Betreff: Re: OWB-1393
+1 looks good.

out of curiosity: did you think about using isContainerEvent to check if
the cache should be setup? wonder if it moves from o(2n) to o(n) the
complexity (but for an extension n is generally not that crazy not
shouldn't change drastically the startup).

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le dim. 10 oct. 2021 à 22:12, Arne Limburg 
a écrit :

> I have pushed a version to the branch OWB-1393.
>
> Feel free to take a look at it. If it looks ok, I can merge it tomorrow.
> With this version we don’t have to touch the cache, simply registering the
> lifecycle observer methods first and only after all lifecycle observer
> methods of all extensions are registered, registering the non lifecycle
> observer methods of the extensions (which then throws the
> ProcessObserverMethod events and correctly sets up the cache).
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<<http://www.openknowledge.de%3c>
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 20:04
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> +1, thanks Arne
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau><https://github.com/rmannibucau%3e> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le dim. 10 oct. 2021 à 20:02, Arne Limburg 
> a écrit :
>
> > Yes, basically that’s my option 2. I am currently implementing it.
> > Feel free to review it, when I have pushed it.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 

[jira] [Resolved] (OWB-1393) OWB stops firing ProcessObserverMethods event, when Extension with non system event observer exists

2021-10-11 Thread Arne Limburg (Jira)


 [ 
https://issues.apache.org/jira/browse/OWB-1393?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Arne Limburg resolved OWB-1393.
---
Fix Version/s: 2.0.24
   Resolution: Fixed

> OWB stops firing ProcessObserverMethods event, when Extension with non system 
> event observer exists
> ---
>
>         Key: OWB-1393
> URL: https://issues.apache.org/jira/browse/OWB-1393
> Project: OpenWebBeans
>  Issue Type: Bug
>Affects Versions: 2.0.23
>Reporter: Arne Limburg
>Assignee: Arne Limburg
>Priority: Major
> Fix For: 2.0.24
>
>
> When an extension is in the classpath, that observes an event that is no 
> system event (like org.apache.cxf.cdi.JAXRSCdiResourceExtension), every 
> extension that is registered after that extension will not receive 
> ProcessObserverMethod events any more.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


Re: OWB-1393

2021-10-11 Thread Romain Manni-Bucau
+1 looks good.

out of curiosity: did you think about using isContainerEvent to check if
the cache should be setup? wonder if it moves from o(2n) to o(n) the
complexity (but for an extension n is generally not that crazy not
shouldn't change drastically the startup).

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le dim. 10 oct. 2021 à 22:12, Arne Limburg 
a écrit :

> I have pushed a version to the branch OWB-1393.
>
> Feel free to take a look at it. If it looks ok, I can merge it tomorrow.
> With this version we don’t have to touch the cache, simply registering the
> lifecycle observer methods first and only after all lifecycle observer
> methods of all extensions are registered, registering the non lifecycle
> observer methods of the extensions (which then throws the
> ProcessObserverMethod events and correctly sets up the cache).
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 20:04
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> +1, thanks Arne
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://rmannibucau.metawerx.net/> | Old Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> <
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> >
>
>
> Le dim. 10 oct. 2021 à 20:02, Arne Limburg 
> a écrit :
>
> > Yes, basically that’s my option 2. I am currently implementing it.
> > Feel free to review it, when I have pushed it.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> > Fax: +49 441 - 4082-111
> > arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> > www.openknowledge.de<<http://www.openknowledge.de%3c>
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> > >
> > Registergericht: Amtsgericht Oldenburg, HRB 4670
> > Geschäftsführer: Lars Röwekamp, Jens Schumann
> >
> > Treffen Sie uns auf kommenden Konferenzen und Workshops:
> > Zu unseren Events<
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> > >
> >
> > Von: Romain Manni-Bucau 
> > Datum: Sonntag, 10. Oktober 2021 um 18:32
> > An: openwebbeans-dev 
> > Betreff: Re: OWB-1393
> > Hmm,
> >
> > Maybe I misread the options (or misinterpreted them) but think we should:
> >
> > 1. Register all extensions without any fire
> > 2. Start firing events
> >
> &

AW: OWB-1393

2021-10-10 Thread Arne Limburg
I have pushed a version to the branch OWB-1393.

Feel free to take a look at it. If it looks ok, I can merge it tomorrow.
With this version we don’t have to touch the cache, simply registering the 
lifecycle observer methods first and only after all lifecycle observer methods 
of all extensions are registered, registering the non lifecycle observer 
methods of the extensions (which then throws the ProcessObserverMethod events 
and correctly sets up the cache).

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Romain Manni-Bucau 
Datum: Sonntag, 10. Oktober 2021 um 20:04
An: openwebbeans-dev 
Betreff: Re: OWB-1393
+1, thanks Arne

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le dim. 10 oct. 2021 à 20:02, Arne Limburg 
a écrit :

> Yes, basically that’s my option 2. I am currently implementing it.
> Feel free to review it, when I have pushed it.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<<http://www.openknowledge.de%3c>
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 18:32
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> Hmm,
>
> Maybe I misread the options (or misinterpreted them) but think we should:
>
> 1. Register all extensions without any fire
> 2. Start firing events
>
> 2. Means we keep the lazy resolution of observers and can destroy/reset the
> cache after afterdeploymentvalidation event.
>
>
> No?
>
> Le dim. 10 oct. 2021 à 18:03, Arne Limburg 
> a écrit :
>
> > Hi,
> >
> > you can fire any Event from extensions and listen to any event in
> > extensions with every of the three options.
> > The first option would have the disadvantage that an extension, that
> > listens to ProcessObserverMethod would not receive the
> > ProcessObserverMethod event for non-lifecycle observer methods of other
> > extensions, which would not be a problem I guess (also I don’t know what
> > the spec says about it).
> >
> > Imho the second option would be the cleanest. It would basically mean:
> > First register every lifecycle event observer of every extension, then
> > register every non-lifecycle event of every extension (and fire
> > ProcessObserverMethod for every of that observer methods). This would be
> > valid, too. But it’s the hardest option to implement with the curren

Re: OWB-1393

2021-10-10 Thread Romain Manni-Bucau
+1, thanks Arne

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le dim. 10 oct. 2021 à 20:02, Arne Limburg 
a écrit :

> Yes, basically that’s my option 2. I am currently implementing it.
> Feel free to review it, when I have pushed it.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 18:32
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> Hmm,
>
> Maybe I misread the options (or misinterpreted them) but think we should:
>
> 1. Register all extensions without any fire
> 2. Start firing events
>
> 2. Means we keep the lazy resolution of observers and can destroy/reset the
> cache after afterdeploymentvalidation event.
>
>
> No?
>
> Le dim. 10 oct. 2021 à 18:03, Arne Limburg 
> a écrit :
>
> > Hi,
> >
> > you can fire any Event from extensions and listen to any event in
> > extensions with every of the three options.
> > The first option would have the disadvantage that an extension, that
> > listens to ProcessObserverMethod would not receive the
> > ProcessObserverMethod event for non-lifecycle observer methods of other
> > extensions, which would not be a problem I guess (also I don’t know what
> > the spec says about it).
> >
> > Imho the second option would be the cleanest. It would basically mean:
> > First register every lifecycle event observer of every extension, then
> > register every non-lifecycle event of every extension (and fire
> > ProcessObserverMethod for every of that observer methods). This would be
> > valid, too. But it’s the hardest option to implement with the current
> code
> > base.
> >
> > The third variant would mean, that ProcessObserverMethod would be thrown
> > again, but not every extension would get every ProcessObserverMethod
> event
> > for every non-lifecycle-event of other extensions (which again should be
> no
> > problem). Or we should disable that cache completely during extension
> > registration.
> >
> > Writing that, I will take a deeper look at variant two or three.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> > Fax: +49 441 - 4082-111
> > arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> > www.openknowledge.de<<http://www.openknowledge.de%3c>
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> > >
> > Registergericht: Amtsgericht Oldenburg, HRB 4670
> > Geschäftsführer: Lars Röwekamp, Jens Schumann
> >
> > Treffen Sie uns auf kommenden Konferenzen und Workshops:
> > Zu unseren Events<
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAw

AW: OWB-1393

2021-10-10 Thread Arne Limburg
Yes, basically that’s my option 2. I am currently implementing it.
Feel free to review it, when I have pushed it.

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Romain Manni-Bucau 
Datum: Sonntag, 10. Oktober 2021 um 18:32
An: openwebbeans-dev 
Betreff: Re: OWB-1393
Hmm,

Maybe I misread the options (or misinterpreted them) but think we should:

1. Register all extensions without any fire
2. Start firing events

2. Means we keep the lazy resolution of observers and can destroy/reset the
cache after afterdeploymentvalidation event.


No?

Le dim. 10 oct. 2021 à 18:03, Arne Limburg 
a écrit :

> Hi,
>
> you can fire any Event from extensions and listen to any event in
> extensions with every of the three options.
> The first option would have the disadvantage that an extension, that
> listens to ProcessObserverMethod would not receive the
> ProcessObserverMethod event for non-lifecycle observer methods of other
> extensions, which would not be a problem I guess (also I don’t know what
> the spec says about it).
>
> Imho the second option would be the cleanest. It would basically mean:
> First register every lifecycle event observer of every extension, then
> register every non-lifecycle event of every extension (and fire
> ProcessObserverMethod for every of that observer methods). This would be
> valid, too. But it’s the hardest option to implement with the current code
> base.
>
> The third variant would mean, that ProcessObserverMethod would be thrown
> again, but not every extension would get every ProcessObserverMethod event
> for every non-lifecycle-event of other extensions (which again should be no
> problem). Or we should disable that cache completely during extension
> registration.
>
> Writing that, I will take a deeper look at variant two or three.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<<http://www.openknowledge.de%3c>
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 17:39
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> Hi
>
> 3 sounds the only valid option since it is valid and used to fire any event
> in extensions and is used to communicate between them from time to time.
>
> Hope it helps.
>
> Le dim. 10 oct. 2021 à 13:57, Arne Limburg 
> a écrit :
>
> > FYI,
> > I now went with solution 1 and pushed it to a branch. If there are no
> > objections, I’ll merge it tomorrow or so.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> &

Re: OWB-1393

2021-10-10 Thread Romain Manni-Bucau
Hmm,

Maybe I misread the options (or misinterpreted them) but think we should:

1. Register all extensions without any fire
2. Start firing events

2. Means we keep the lazy resolution of observers and can destroy/reset the
cache after afterdeploymentvalidation event.


No?

Le dim. 10 oct. 2021 à 18:03, Arne Limburg 
a écrit :

> Hi,
>
> you can fire any Event from extensions and listen to any event in
> extensions with every of the three options.
> The first option would have the disadvantage that an extension, that
> listens to ProcessObserverMethod would not receive the
> ProcessObserverMethod event for non-lifecycle observer methods of other
> extensions, which would not be a problem I guess (also I don’t know what
> the spec says about it).
>
> Imho the second option would be the cleanest. It would basically mean:
> First register every lifecycle event observer of every extension, then
> register every non-lifecycle event of every extension (and fire
> ProcessObserverMethod for every of that observer methods). This would be
> valid, too. But it’s the hardest option to implement with the current code
> base.
>
> The third variant would mean, that ProcessObserverMethod would be thrown
> again, but not every extension would get every ProcessObserverMethod event
> for every non-lifecycle-event of other extensions (which again should be no
> problem). Or we should disable that cache completely during extension
> registration.
>
> Writing that, I will take a deeper look at variant two or three.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Romain Manni-Bucau 
> Datum: Sonntag, 10. Oktober 2021 um 17:39
> An: openwebbeans-dev 
> Betreff: Re: OWB-1393
> Hi
>
> 3 sounds the only valid option since it is valid and used to fire any event
> in extensions and is used to communicate between them from time to time.
>
> Hope it helps.
>
> Le dim. 10 oct. 2021 à 13:57, Arne Limburg 
> a écrit :
>
> > FYI,
> > I now went with solution 1 and pushed it to a branch. If there are no
> > objections, I’ll merge it tomorrow or so.
> >
> > Cheers,
> > Arne
> >
> > OPEN KNOWLEDGE GmbH
> > Poststraße 1, 26122 Oldenburg
> > Mobil: +49 151 - 108 22 942
> > Tel: +49 441 - 4082-154
> > Fax: +49 441 - 4082-111
> > arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> > www.openknowledge.de<<http://www.openknowledge.de%3c>
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> > >
> > Registergericht: Amtsgericht Oldenburg, HRB 4670
> > Geschäftsführer: Lars Röwekamp, Jens Schumann
> >
> > Treffen Sie uns auf kommenden Konferenzen und Workshops:
> > Zu unseren Events<
> >
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> > >
> >
> > Von: Arne Limburg 
> > Datum: Sonntag, 10. Oktober 2021 um 12:34
> > An: dev@openwebbeans.apache.org 
> > Betreff: OWB-1393
> > Hi,
> >
> > I’ve 

AW: OWB-1393

2021-10-10 Thread Arne Limburg
Hi,

you can fire any Event from extensions and listen to any event in extensions 
with every of the three options.
The first option would have the disadvantage that an extension, that listens to 
ProcessObserverMethod would not receive the ProcessObserverMethod event for 
non-lifecycle observer methods of other extensions, which would not be a 
problem I guess (also I don’t know what the spec says about it).

Imho the second option would be the cleanest. It would basically mean:
First register every lifecycle event observer of every extension, then register 
every non-lifecycle event of every extension (and fire ProcessObserverMethod 
for every of that observer methods). This would be valid, too. But it’s the 
hardest option to implement with the current code base.

The third variant would mean, that ProcessObserverMethod would be thrown again, 
but not every extension would get every ProcessObserverMethod event for every 
non-lifecycle-event of other extensions (which again should be no problem). Or 
we should disable that cache completely during extension registration.

Writing that, I will take a deeper look at variant two or three.

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Romain Manni-Bucau 
Datum: Sonntag, 10. Oktober 2021 um 17:39
An: openwebbeans-dev 
Betreff: Re: OWB-1393
Hi

3 sounds the only valid option since it is valid and used to fire any event
in extensions and is used to communicate between them from time to time.

Hope it helps.

Le dim. 10 oct. 2021 à 13:57, Arne Limburg 
a écrit :

> FYI,
> I now went with solution 1 and pushed it to a branch. If there are no
> objections, I’ll merge it tomorrow or so.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<<http://www.openknowledge.de%3c>
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Arne Limburg 
> Datum: Sonntag, 10. Oktober 2021 um 12:34
> An: dev@openwebbeans.apache.org 
> Betreff: OWB-1393
> Hi,
>
> I’ve created OWB-1393 and am going to fix it.
>
> When we find an extension that contains an observer method, that observes
> an event that is no lifecycle event, we currently fire
> ProcessObserverMethod during addExtension(…) (before every Extension is
> registered). That leads to a caching problem. We cache too early (and thus
> too less entries) and don’t invalidate the cache later.
>
> Note: org.apache.cxf.cdi.JAXRSCdiResourceExtension observes a
> non-lifecycle event, so we have that bug currently in meecrowave (where I
> observed it).
>
> That leads me to a few questions:
>
> Is it covered by the spec, that an extension may contain non-lifecycle
> events?
> If not: Should we throw an exception then, which would break CXF and thus
> Meecrowave.

Re: OWB-1393

2021-10-10 Thread Romain Manni-Bucau
Hi

3 sounds the only valid option since it is valid and used to fire any event
in extensions and is used to communicate between them from time to time.

Hope it helps.

Le dim. 10 oct. 2021 à 13:57, Arne Limburg 
a écrit :

> FYI,
> I now went with solution 1 and pushed it to a branch. If there are no
> objections, I’ll merge it tomorrow or so.
>
> Cheers,
> Arne
>
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>
> Von: Arne Limburg 
> Datum: Sonntag, 10. Oktober 2021 um 12:34
> An: dev@openwebbeans.apache.org 
> Betreff: OWB-1393
> Hi,
>
> I’ve created OWB-1393 and am going to fix it.
>
> When we find an extension that contains an observer method, that observes
> an event that is no lifecycle event, we currently fire
> ProcessObserverMethod during addExtension(…) (before every Extension is
> registered). That leads to a caching problem. We cache too early (and thus
> too less entries) and don’t invalidate the cache later.
>
> Note: org.apache.cxf.cdi.JAXRSCdiResourceExtension observes a
> non-lifecycle event, so we have that bug currently in meecrowave (where I
> observed it).
>
> That leads me to a few questions:
>
> Is it covered by the spec, that an extension may contain non-lifecycle
> events?
> If not: Should we throw an exception then, which would break CXF and thus
> Meecrowave.
>
> In any case, how should we handle it?
> 1. Don’t fire ProcessObserverMethod during extension registration at all?
> 2. First register every Lifecycle-Event-Observer during extension
> registration and only then register the non-lifecycle-Observers (which
> fires the ProcessObserverMethod events)?
> 3. Invalidate that cache after extension registration (probably the most
> inperformant way)?
>
> Any opinion?
>
> Cheers,
> Arne
> OPEN KNOWLEDGE GmbH
> Poststraße 1, 26122 Oldenburg
> Mobil: +49 151 - 108 22 942
> Tel: +49 441 - 4082-154
> Fax: +49 441 - 4082-111
> arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
> www.openknowledge.de<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> <http://www.openknowledge.de%3chttps:/
> eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0
> >>
> Registergericht: Amtsgericht Oldenburg, HRB 4670
> Geschäftsführer: Lars Röwekamp, Jens Schumann
>
> Treffen Sie uns auf kommenden Konferenzen und Workshops:
> Zu unseren Events<
> https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0
> >
>


AW: OWB-1393

2021-10-10 Thread Arne Limburg
FYI,
I now went with solution 1 and pushed it to a branch. If there are no 
objections, I’ll merge it tomorrow or so.

Cheers,
Arne

OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>

Von: Arne Limburg 
Datum: Sonntag, 10. Oktober 2021 um 12:34
An: dev@openwebbeans.apache.org 
Betreff: OWB-1393
Hi,

I’ve created OWB-1393 and am going to fix it.

When we find an extension that contains an observer method, that observes an 
event that is no lifecycle event, we currently fire ProcessObserverMethod 
during addExtension(…) (before every Extension is registered). That leads to a 
caching problem. We cache too early (and thus too less entries) and don’t 
invalidate the cache later.

Note: org.apache.cxf.cdi.JAXRSCdiResourceExtension observes a non-lifecycle 
event, so we have that bug currently in meecrowave (where I observed it).

That leads me to a few questions:

Is it covered by the spec, that an extension may contain non-lifecycle events?
If not: Should we throw an exception then, which would break CXF and thus 
Meecrowave.

In any case, how should we handle it?
1. Don’t fire ProcessObserverMethod during extension registration at all?
2. First register every Lifecycle-Event-Observer during extension registration 
and only then register the non-lifecycle-Observers (which fires the 
ProcessObserverMethod events)?
3. Invalidate that cache after extension registration (probably the most 
inperformant way)?

Any opinion?

Cheers,
Arne
OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0<http://www.openknowledge.de%3chttps:/eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>


OWB-1393

2021-10-10 Thread Arne Limburg
Hi,

I’ve created OWB-1393 and am going to fix it.

When we find an extension that contains an observer method, that observes an 
event that is no lifecycle event, we currently fire ProcessObserverMethod 
during addExtension(…) (before every Extension is registered). That leads to a 
caching problem. We cache too early (and thus too less entries) and don’t 
invalidate the cache later.

Note: org.apache.cxf.cdi.JAXRSCdiResourceExtension observes a non-lifecycle 
event, so we have that bug currently in meecrowave (where I observed it).

That leads me to a few questions:

Is it covered by the spec, that an extension may contain non-lifecycle events?
If not: Should we throw an exception then, which would break CXF and thus 
Meecrowave.

In any case, how should we handle it?
1. Don’t fire ProcessObserverMethod during extension registration at all?
2. First register every Lifecycle-Event-Observer during extension registration 
and only then register the non-lifecycle-Observers (which fires the 
ProcessObserverMethod events)?
3. Invalidate that cache after extension registration (probably the most 
inperformant way)?

Any opinion?

Cheers,
Arne
OPEN KNOWLEDGE GmbH
Poststraße 1, 26122 Oldenburg
Mobil: +49 151 - 108 22 942
Tel: +49 441 - 4082-154
Fax: +49 441 - 4082-111
arne.limb...@openknowledge.de<mailto:arne.limb...@openknowledge.de>
www.openknowledge.de<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=9vRVYZVZ%2Feqk%2BvFxU5COofNvgs8U0AxtxRqwVEwqXHA%3D=0>
Registergericht: Amtsgericht Oldenburg, HRB 4670
Geschäftsführer: Lars Röwekamp, Jens Schumann

Treffen Sie uns auf kommenden Konferenzen und Workshops:
Zu unseren 
Events<https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.openknowledge.de%2Fevent%2F=04%7C01%7C%7C3004d8758be44c8678c008d93bcc1e23%7C48837bc476f9481d8a76bd7b60b43dec%7C0%7C0%7C637606570139932909%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000=8tjmukdm1NxhXQMkn4VnESiBI216kXvh%2Fjb7%2FFYI0kE%3D=0>



[jira] [Created] (OWB-1393) OWB stops firing ProcessObserverMethods event, when Extension with non system event observer exists

2021-10-10 Thread Arne Limburg (Jira)
Arne Limburg created OWB-1393:
-

 Summary: OWB stops firing ProcessObserverMethods event, when 
Extension with non system event observer exists
 Key: OWB-1393
 URL: https://issues.apache.org/jira/browse/OWB-1393
 Project: OpenWebBeans
  Issue Type: Bug
Affects Versions: 2.0.23
Reporter: Arne Limburg
Assignee: Arne Limburg


When an extension is in the classpath, that observes an event that is no system 
event (like org.apache.cxf.cdi.JAXRSCdiResourceExtension), every extension that 
is registered after that extension will not receive ProcessObserverMethod 
events any more.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)