You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Gernot Pfingstl <ge...@gmx.at> on 2011/05/20 16:56:50 UTC

CODI @ViewAccessScoped not cleaned up?

Hi,

I'm using Glassfish 3.1 and CODI 0.9.5

I've a bean A annotated with @ViewAccessScoped.

Bean A is used in page1.xhtml. If page1 is called from page1 the state
of the bean is preserved (as expected).

Then I navigate to page2.xhtml (which does not have any reference to
bean A), an then I navigate (from page2) to page3.xhtml (which also
does not have any reference to bean A).
At this point I supposed bean A has bean invalidated/removed - but a
@PreDestroy is never calles

Now I navigate (from page3) to page1.xhtml - and bean A has the
previous values and not an inital state.

Do I misunderstand the @ViewAccessScoped or is there something wrong?

regards,
Gernot

Re: AW: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi mark,

i was talking about a spi of codi. the edge case which causes the issue
isn't really specified. there is just no reason why it shouldn't work (and
originally it worked with weld as well).

i'll file a weld issue.

owb works well :)

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/21 Mark Struberg <st...@yahoo.de>

> there is no SPI in the CDI spec which is not important for all users.
> Extensions are a core mechanism and needs to work.
>
> We _must_ file a Weld issue in any case if we find an error. Maybe it might
> be our fault and they can help to clarify this...
>
> This is just like this funyn guy telling Matze that an 'average developer'
> will not code Extensions, thus -> low prio GF bug.
> This assumption is plain wrong and Glassfish folks already figured this.
> Because if an Extension developer cannot implement his Extension, then a
> 'casual developer' cannot use this extension...
>
> Who has stacktraces, info about this issue? Thomas or Gerhard one of you
> please file a Weld bug - big thanks!
>
> Of course if we find something in OWB which you think it should just work,
> then please file a jira issue against OWB too - txs!
>
> LieGrue,
> strub
>
>
> --- On Sat, 5/21/11, Gerhard Petracek <ge...@gmail.com> wrote:
>
> > From: Gerhard Petracek <ge...@gmail.com>
> > Subject: Re: AW: CODI @ViewAccessScoped not cleaned up?
> > To: "MyFaces Discussion" <us...@myfaces.apache.org>
> > Date: Saturday, May 21, 2011, 10:26 AM
> > hi mark,
> >
> > it would be nice if we don't need workarounds for weld.
> > however, we already have several workarounds. without them
> > codi wouldn't
> > work in combination with weld. the same is true for
> > mojarra. and we can't
> > just ignore both reference implementations for
> > months/years.
> >
> > in this case it's a very special caching bug which came in
> > due to the
> > performance improvements in weld v1.1.1. usually you won't
> > see it - we just
> > have a very special constellation (since we (re-)use a spi
> > which was
> > designed for application developers).
> >
> > for sure we can file a weld issue. however, since it's a
> > quite special
> > constellation, they would give it a very low priority.
> > there are way more
> > weld bugs which are more important.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> >
> > 2011/5/21 Mark Struberg <st...@yahoo.de>
> >
> > > I'm not really conviced that we should implement
> > workarounds for such
> > > clearly broken weld issues.
> > >
> > > Thomas, did you already file a bug report in Weld
> > marking this as blocker?
> > > Really, we should at least link to them in our sources
> > (+jira) and asap get
> > > rid of this workaround in OUR source again. Otherwise
> > we will end up with
> > > unmaintainable CODI sources.
> > >
> > > LieGrue,
> > > strub
> > >
> > > --- On Sat, 5/21/11, Ing.Thomas Kernstock <
> t.kernstock@e-technologies.at>
> > > wrote:
> > >
> > > > From: Ing.Thomas Kernstock <t....@e-technologies.at>
> > > > Subject: AW: CODI @ViewAccessScoped not cleaned
> > up?
> > > > To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> > > > Date: Saturday, May 21, 2011, 1:17 AM
> > > > that's what I expected :-) The
> > > > chances that weld causes the problem where
> > > > rather huge  (as we discussed earlier).
> > > > have a good one
> > > > thomas
> > > >
> > > >
> > > > -----Ursprüngliche Nachricht-----
> > > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > >
> > > > Gesendet: Freitag, 20. Mai 2011 21:08
> > > > An: MyFaces Discussion
> > > > Betreff: Re: CODI @ViewAccessScoped not cleaned
> > up?
> > > >
> > > > hi thomas,
> > > >
> > > > this part of codi hasn't changed since the first
> > release
> > > > whereas weld
> > > > changed a lot.
> > > >
> > > > regards,
> > > > gerhard
> > > >
> > > > http://www.irian.at
> > > >
> > > > Your JSF powerhouse -
> > > > JSF Consulting, Development and
> > > > Courses in English and German
> > > >
> > > > Professional Support for Apache MyFaces
> > > >
> > > >
> > > >
> > > > 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> > > >
> > > > > Hi Gerhard,
> > > > >
> > > > > I Think you are right - this problem exists
> > either
> > > > since Codi 0.9.4 or
> > > > > Glassfish3.1(Weld 1.1.1). This explains why
> > I see
> > > > extra database
> > > > > updates (in my logfiles) of entities that
> > should have
> > > > been destroyed
> > > > > allready. On Glassfish 3.0.1 with CODI 0.9.3
> > this
> > > > worked fine !
> > > > >
> > > > > best regards
> > > > > Thomas
> > > > >
> > > > > ___________________________________
> > > > > -----Ursprüngliche Nachricht-----
> > > > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > > > Gesendet: Freitag, 20. Mai 2011 19:35
> > > > > An: MyFaces Discussion
> > > > > Betreff: Re: CODI @ViewAccessScoped not
> > cleaned up?
> > > > >
> > > > > hi gernot,
> > > > >
> > > > > @PreDestroy will be called after rendering
> > the first
> > > > page which
> > > > > doesn't use the bean.
> > > > > it looks like a weld bug (i see the same
> > with weld
> > > > v1.1.1).
> > > > > i tested it with owb and it works as
> > expected.
> > > > > i'll have a look at it, if there is a
> > possible
> > > > workaround for weld.
> > > > >
> > > > > regards,
> > > > > gerhard
> > > > >
> > > > > http://www.irian.at
> > > > >
> > > > > Your JSF powerhouse -
> > > > > JSF Consulting, Development and
> > > > > Courses in English and German
> > > > >
> > > > > Professional Support for Apache MyFaces
> > > > >
> > > > >
> > > > > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> > > > >
> > > > > > Hi,
> > > > > >
> > > > > > I'm using Glassfish 3.1 and CODI 0.9.5
> > > > > >
> > > > > > I've a bean A annotated with
> > @ViewAccessScoped.
> > > > > >
> > > > > > Bean A is used in page1.xhtml. If page1
> > is called
> > > > from page1 the
> > > > > > state of the bean is preserved (as
> > expected).
> > > > > >
> > > > > > Then I navigate to page2.xhtml (which
> > does not
> > > > have any reference to
> > > > > > bean A), an then I navigate (from
> > page2) to
> > > > page3.xhtml (which also
> > > > > > does not have any reference to bean
> > A).
> > > > > > At this point I supposed bean A has
> > bean
> > > > invalidated/removed - but a
> > > > > > @PreDestroy is never calles
> > > > > >
> > > > > > Now I navigate (from page3) to
> > page1.xhtml - and
> > > > bean A has the
> > > > > > previous values and not an inital
> > state.
> > > > > >
> > > > > > Do I misunderstand the
> > @ViewAccessScoped or is
> > > > there something wrong?
> > > > > >
> > > > > > regards,
> > > > > > Gernot
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> >
>

Re: AW: CODI @ViewAccessScoped not cleaned up?

Posted by Mark Struberg <st...@yahoo.de>.
there is no SPI in the CDI spec which is not important for all users. Extensions are a core mechanism and needs to work.

We _must_ file a Weld issue in any case if we find an error. Maybe it might be our fault and they can help to clarify this...

This is just like this funyn guy telling Matze that an 'average developer' will not code Extensions, thus -> low prio GF bug. 
This assumption is plain wrong and Glassfish folks already figured this. Because if an Extension developer cannot implement his Extension, then a 'casual developer' cannot use this extension...

Who has stacktraces, info about this issue? Thomas or Gerhard one of you please file a Weld bug - big thanks!

Of course if we find something in OWB which you think it should just work, then please file a jira issue against OWB too - txs!

LieGrue,
strub 


--- On Sat, 5/21/11, Gerhard Petracek <ge...@gmail.com> wrote:

> From: Gerhard Petracek <ge...@gmail.com>
> Subject: Re: AW: CODI @ViewAccessScoped not cleaned up?
> To: "MyFaces Discussion" <us...@myfaces.apache.org>
> Date: Saturday, May 21, 2011, 10:26 AM
> hi mark,
> 
> it would be nice if we don't need workarounds for weld.
> however, we already have several workarounds. without them
> codi wouldn't
> work in combination with weld. the same is true for
> mojarra. and we can't
> just ignore both reference implementations for
> months/years.
> 
> in this case it's a very special caching bug which came in
> due to the
> performance improvements in weld v1.1.1. usually you won't
> see it - we just
> have a very special constellation (since we (re-)use a spi
> which was
> designed for application developers).
> 
> for sure we can file a weld issue. however, since it's a
> quite special
> constellation, they would give it a very low priority.
> there are way more
> weld bugs which are more important.
> 
> regards,
> gerhard
> 
> http://www.irian.at
> 
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
> 
> Professional Support for Apache MyFaces
> 
> 
> 
> 2011/5/21 Mark Struberg <st...@yahoo.de>
> 
> > I'm not really conviced that we should implement
> workarounds for such
> > clearly broken weld issues.
> >
> > Thomas, did you already file a bug report in Weld
> marking this as blocker?
> > Really, we should at least link to them in our sources
> (+jira) and asap get
> > rid of this workaround in OUR source again. Otherwise
> we will end up with
> > unmaintainable CODI sources.
> >
> > LieGrue,
> > strub
> >
> > --- On Sat, 5/21/11, Ing.Thomas Kernstock <t....@e-technologies.at>
> > wrote:
> >
> > > From: Ing.Thomas Kernstock <t....@e-technologies.at>
> > > Subject: AW: CODI @ViewAccessScoped not cleaned
> up?
> > > To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> > > Date: Saturday, May 21, 2011, 1:17 AM
> > > that's what I expected :-) The
> > > chances that weld causes the problem where
> > > rather huge  (as we discussed earlier).
> > > have a good one
> > > thomas
> > >
> > >
> > > -----Ursprüngliche Nachricht-----
> > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > >
> > > Gesendet: Freitag, 20. Mai 2011 21:08
> > > An: MyFaces Discussion
> > > Betreff: Re: CODI @ViewAccessScoped not cleaned
> up?
> > >
> > > hi thomas,
> > >
> > > this part of codi hasn't changed since the first
> release
> > > whereas weld
> > > changed a lot.
> > >
> > > regards,
> > > gerhard
> > >
> > > http://www.irian.at
> > >
> > > Your JSF powerhouse -
> > > JSF Consulting, Development and
> > > Courses in English and German
> > >
> > > Professional Support for Apache MyFaces
> > >
> > >
> > >
> > > 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> > >
> > > > Hi Gerhard,
> > > >
> > > > I Think you are right - this problem exists
> either
> > > since Codi 0.9.4 or
> > > > Glassfish3.1(Weld 1.1.1). This explains why
> I see
> > > extra database
> > > > updates (in my logfiles) of entities that
> should have
> > > been destroyed
> > > > allready. On Glassfish 3.0.1 with CODI 0.9.3
> this
> > > worked fine !
> > > >
> > > > best regards
> > > > Thomas
> > > >
> > > > ___________________________________
> > > > -----Ursprüngliche Nachricht-----
> > > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > > Gesendet: Freitag, 20. Mai 2011 19:35
> > > > An: MyFaces Discussion
> > > > Betreff: Re: CODI @ViewAccessScoped not
> cleaned up?
> > > >
> > > > hi gernot,
> > > >
> > > > @PreDestroy will be called after rendering
> the first
> > > page which
> > > > doesn't use the bean.
> > > > it looks like a weld bug (i see the same
> with weld
> > > v1.1.1).
> > > > i tested it with owb and it works as
> expected.
> > > > i'll have a look at it, if there is a
> possible
> > > workaround for weld.
> > > >
> > > > regards,
> > > > gerhard
> > > >
> > > > http://www.irian.at
> > > >
> > > > Your JSF powerhouse -
> > > > JSF Consulting, Development and
> > > > Courses in English and German
> > > >
> > > > Professional Support for Apache MyFaces
> > > >
> > > >
> > > > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> > > >
> > > > > Hi,
> > > > >
> > > > > I'm using Glassfish 3.1 and CODI 0.9.5
> > > > >
> > > > > I've a bean A annotated with
> @ViewAccessScoped.
> > > > >
> > > > > Bean A is used in page1.xhtml. If page1
> is called
> > > from page1 the
> > > > > state of the bean is preserved (as
> expected).
> > > > >
> > > > > Then I navigate to page2.xhtml (which
> does not
> > > have any reference to
> > > > > bean A), an then I navigate (from
> page2) to
> > > page3.xhtml (which also
> > > > > does not have any reference to bean
> A).
> > > > > At this point I supposed bean A has
> bean
> > > invalidated/removed - but a
> > > > > @PreDestroy is never calles
> > > > >
> > > > > Now I navigate (from page3) to
> page1.xhtml - and
> > > bean A has the
> > > > > previous values and not an inital
> state.
> > > > >
> > > > > Do I misunderstand the
> @ViewAccessScoped or is
> > > there something wrong?
> > > > >
> > > > > regards,
> > > > > Gernot
> > > > >
> > > >
> > > >
> > >
> > >
> >
> 

Re: AW: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi mark,

it would be nice if we don't need workarounds for weld.
however, we already have several workarounds. without them codi wouldn't
work in combination with weld. the same is true for mojarra. and we can't
just ignore both reference implementations for months/years.

in this case it's a very special caching bug which came in due to the
performance improvements in weld v1.1.1. usually you won't see it - we just
have a very special constellation (since we (re-)use a spi which was
designed for application developers).

for sure we can file a weld issue. however, since it's a quite special
constellation, they would give it a very low priority. there are way more
weld bugs which are more important.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/21 Mark Struberg <st...@yahoo.de>

> I'm not really conviced that we should implement workarounds for such
> clearly broken weld issues.
>
> Thomas, did you already file a bug report in Weld marking this as blocker?
> Really, we should at least link to them in our sources (+jira) and asap get
> rid of this workaround in OUR source again. Otherwise we will end up with
> unmaintainable CODI sources.
>
> LieGrue,
> strub
>
> --- On Sat, 5/21/11, Ing.Thomas Kernstock <t....@e-technologies.at>
> wrote:
>
> > From: Ing.Thomas Kernstock <t....@e-technologies.at>
> > Subject: AW: CODI @ViewAccessScoped not cleaned up?
> > To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> > Date: Saturday, May 21, 2011, 1:17 AM
> > that's what I expected :-) The
> > chances that weld causes the problem where
> > rather huge  (as we discussed earlier).
> > have a good one
> > thomas
> >
> >
> > -----Ursprüngliche Nachricht-----
> > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> >
> > Gesendet: Freitag, 20. Mai 2011 21:08
> > An: MyFaces Discussion
> > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >
> > hi thomas,
> >
> > this part of codi hasn't changed since the first release
> > whereas weld
> > changed a lot.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> >
> > 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> >
> > > Hi Gerhard,
> > >
> > > I Think you are right - this problem exists either
> > since Codi 0.9.4 or
> > > Glassfish3.1(Weld 1.1.1). This explains why I see
> > extra database
> > > updates (in my logfiles) of entities that should have
> > been destroyed
> > > allready. On Glassfish 3.0.1 with CODI 0.9.3 this
> > worked fine !
> > >
> > > best regards
> > > Thomas
> > >
> > > ___________________________________
> > > -----Ursprüngliche Nachricht-----
> > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > Gesendet: Freitag, 20. Mai 2011 19:35
> > > An: MyFaces Discussion
> > > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> > >
> > > hi gernot,
> > >
> > > @PreDestroy will be called after rendering the first
> > page which
> > > doesn't use the bean.
> > > it looks like a weld bug (i see the same with weld
> > v1.1.1).
> > > i tested it with owb and it works as expected.
> > > i'll have a look at it, if there is a possible
> > workaround for weld.
> > >
> > > regards,
> > > gerhard
> > >
> > > http://www.irian.at
> > >
> > > Your JSF powerhouse -
> > > JSF Consulting, Development and
> > > Courses in English and German
> > >
> > > Professional Support for Apache MyFaces
> > >
> > >
> > > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> > >
> > > > Hi,
> > > >
> > > > I'm using Glassfish 3.1 and CODI 0.9.5
> > > >
> > > > I've a bean A annotated with @ViewAccessScoped.
> > > >
> > > > Bean A is used in page1.xhtml. If page1 is called
> > from page1 the
> > > > state of the bean is preserved (as expected).
> > > >
> > > > Then I navigate to page2.xhtml (which does not
> > have any reference to
> > > > bean A), an then I navigate (from page2) to
> > page3.xhtml (which also
> > > > does not have any reference to bean A).
> > > > At this point I supposed bean A has bean
> > invalidated/removed - but a
> > > > @PreDestroy is never calles
> > > >
> > > > Now I navigate (from page3) to page1.xhtml - and
> > bean A has the
> > > > previous values and not an inital state.
> > > >
> > > > Do I misunderstand the @ViewAccessScoped or is
> > there something wrong?
> > > >
> > > > regards,
> > > > Gernot
> > > >
> > >
> > >
> >
> >
>

AW: AW: CODI @ViewAccessScoped not cleaned up?

Posted by "Ing.Thomas Kernstock" <t....@e-technologies.at>.
Danke sehr vielmals :-)
lg
Thomas
-----Ursprüngliche Nachricht-----
Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com] 
Gesendet: Samstag, 21. Mai 2011 20:07
An: MyFaces Discussion
Betreff: Re: AW: CODI @ViewAccessScoped not cleaned up?

hi @ all,

as mentioned before:
workaround is committed and issue is reported.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/21 Ing.Thomas Kernstock <t....@e-technologies.at>

> hi mark,
>
> I didn't file a bug report yet, because till gernot's email I thought 
> that I did some faulty refactoring in my code that caused the updates 
> !
>
> I really would appreciate a workaround for this (and other bugs) - 
> although it's not the best way to implement software but in the moment 
> the only chance for my project.
>
> regards
> Thomas
>
> -----Ursprüngliche Nachricht-----
> Von: Mark Struberg [mailto:struberg@yahoo.de]
> Gesendet: Samstag, 21. Mai 2011 12:01
> An: MyFaces Discussion
> Betreff: Re: AW: CODI @ViewAccessScoped not cleaned up?
>
> I'm not really conviced that we should implement workarounds for such 
> clearly broken weld issues.
>
> Thomas, did you already file a bug report in Weld marking this as blocker?
> Really, we should at least link to them in our sources (+jira) and 
> asap get rid of this workaround in OUR source again. Otherwise we will 
> end up with unmaintainable CODI sources.
>
> LieGrue,
> strub
>
> --- On Sat, 5/21/11, Ing.Thomas Kernstock 
> <t....@e-technologies.at>
> wrote:
>
> > From: Ing.Thomas Kernstock <t....@e-technologies.at>
> > Subject: AW: CODI @ViewAccessScoped not cleaned up?
> > To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> > Date: Saturday, May 21, 2011, 1:17 AM that's what I expected :-) The 
> > chances that weld causes the problem where rather huge  (as we 
> > discussed earlier).
> > have a good one
> > thomas
> >
> >
> > -----Ursprüngliche Nachricht-----
> > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> >
> > Gesendet: Freitag, 20. Mai 2011 21:08
> > An: MyFaces Discussion
> > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >
> > hi thomas,
> >
> > this part of codi hasn't changed since the first release whereas 
> > weld changed a lot.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> >
> > 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> >
> > > Hi Gerhard,
> > >
> > > I Think you are right - this problem exists either
> > since Codi 0.9.4 or
> > > Glassfish3.1(Weld 1.1.1). This explains why I see
> > extra database
> > > updates (in my logfiles) of entities that should have
> > been destroyed
> > > allready. On Glassfish 3.0.1 with CODI 0.9.3 this
> > worked fine !
> > >
> > > best regards
> > > Thomas
> > >
> > > ___________________________________
> > > -----Ursprüngliche Nachricht-----
> > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > Gesendet: Freitag, 20. Mai 2011 19:35
> > > An: MyFaces Discussion
> > > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> > >
> > > hi gernot,
> > >
> > > @PreDestroy will be called after rendering the first
> > page which
> > > doesn't use the bean.
> > > it looks like a weld bug (i see the same with weld
> > v1.1.1).
> > > i tested it with owb and it works as expected.
> > > i'll have a look at it, if there is a possible
> > workaround for weld.
> > >
> > > regards,
> > > gerhard
> > >
> > > http://www.irian.at
> > >
> > > Your JSF powerhouse -
> > > JSF Consulting, Development and
> > > Courses in English and German
> > >
> > > Professional Support for Apache MyFaces
> > >
> > >
> > > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> > >
> > > > Hi,
> > > >
> > > > I'm using Glassfish 3.1 and CODI 0.9.5
> > > >
> > > > I've a bean A annotated with @ViewAccessScoped.
> > > >
> > > > Bean A is used in page1.xhtml. If page1 is called
> > from page1 the
> > > > state of the bean is preserved (as expected).
> > > >
> > > > Then I navigate to page2.xhtml (which does not
> > have any reference to
> > > > bean A), an then I navigate (from page2) to
> > page3.xhtml (which also
> > > > does not have any reference to bean A).
> > > > At this point I supposed bean A has bean
> > invalidated/removed - but a
> > > > @PreDestroy is never calles
> > > >
> > > > Now I navigate (from page3) to page1.xhtml - and
> > bean A has the
> > > > previous values and not an inital state.
> > > >
> > > > Do I misunderstand the @ViewAccessScoped or is
> > there something wrong?
> > > >
> > > > regards,
> > > > Gernot
> > > >
> > >
> > >
> >
> >
>
>
>


Re: AW: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi @ all,

as mentioned before:
workaround is committed and issue is reported.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/21 Ing.Thomas Kernstock <t....@e-technologies.at>

> hi mark,
>
> I didn't file a bug report yet, because till gernot's email I thought that
> I
> did some faulty refactoring in my code that caused the updates !
>
> I really would appreciate a workaround for this (and other bugs) - although
> it's not the best way to implement software but in the moment the only
> chance for my project.
>
> regards
> Thomas
>
> -----Ursprüngliche Nachricht-----
> Von: Mark Struberg [mailto:struberg@yahoo.de]
> Gesendet: Samstag, 21. Mai 2011 12:01
> An: MyFaces Discussion
> Betreff: Re: AW: CODI @ViewAccessScoped not cleaned up?
>
> I'm not really conviced that we should implement workarounds for such
> clearly broken weld issues.
>
> Thomas, did you already file a bug report in Weld marking this as blocker?
> Really, we should at least link to them in our sources (+jira) and asap get
> rid of this workaround in OUR source again. Otherwise we will end up with
> unmaintainable CODI sources.
>
> LieGrue,
> strub
>
> --- On Sat, 5/21/11, Ing.Thomas Kernstock <t....@e-technologies.at>
> wrote:
>
> > From: Ing.Thomas Kernstock <t....@e-technologies.at>
> > Subject: AW: CODI @ViewAccessScoped not cleaned up?
> > To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> > Date: Saturday, May 21, 2011, 1:17 AM
> > that's what I expected :-) The
> > chances that weld causes the problem where rather huge  (as we
> > discussed earlier).
> > have a good one
> > thomas
> >
> >
> > -----Ursprüngliche Nachricht-----
> > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> >
> > Gesendet: Freitag, 20. Mai 2011 21:08
> > An: MyFaces Discussion
> > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >
> > hi thomas,
> >
> > this part of codi hasn't changed since the first release whereas weld
> > changed a lot.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> >
> > 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> >
> > > Hi Gerhard,
> > >
> > > I Think you are right - this problem exists either
> > since Codi 0.9.4 or
> > > Glassfish3.1(Weld 1.1.1). This explains why I see
> > extra database
> > > updates (in my logfiles) of entities that should have
> > been destroyed
> > > allready. On Glassfish 3.0.1 with CODI 0.9.3 this
> > worked fine !
> > >
> > > best regards
> > > Thomas
> > >
> > > ___________________________________
> > > -----Ursprüngliche Nachricht-----
> > > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > > Gesendet: Freitag, 20. Mai 2011 19:35
> > > An: MyFaces Discussion
> > > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> > >
> > > hi gernot,
> > >
> > > @PreDestroy will be called after rendering the first
> > page which
> > > doesn't use the bean.
> > > it looks like a weld bug (i see the same with weld
> > v1.1.1).
> > > i tested it with owb and it works as expected.
> > > i'll have a look at it, if there is a possible
> > workaround for weld.
> > >
> > > regards,
> > > gerhard
> > >
> > > http://www.irian.at
> > >
> > > Your JSF powerhouse -
> > > JSF Consulting, Development and
> > > Courses in English and German
> > >
> > > Professional Support for Apache MyFaces
> > >
> > >
> > > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> > >
> > > > Hi,
> > > >
> > > > I'm using Glassfish 3.1 and CODI 0.9.5
> > > >
> > > > I've a bean A annotated with @ViewAccessScoped.
> > > >
> > > > Bean A is used in page1.xhtml. If page1 is called
> > from page1 the
> > > > state of the bean is preserved (as expected).
> > > >
> > > > Then I navigate to page2.xhtml (which does not
> > have any reference to
> > > > bean A), an then I navigate (from page2) to
> > page3.xhtml (which also
> > > > does not have any reference to bean A).
> > > > At this point I supposed bean A has bean
> > invalidated/removed - but a
> > > > @PreDestroy is never calles
> > > >
> > > > Now I navigate (from page3) to page1.xhtml - and
> > bean A has the
> > > > previous values and not an inital state.
> > > >
> > > > Do I misunderstand the @ViewAccessScoped or is
> > there something wrong?
> > > >
> > > > regards,
> > > > Gernot
> > > >
> > >
> > >
> >
> >
>
>
>

AW: AW: CODI @ViewAccessScoped not cleaned up?

Posted by "Ing.Thomas Kernstock" <t....@e-technologies.at>.
hi mark,

I didn't file a bug report yet, because till gernot's email I thought that I
did some faulty refactoring in my code that caused the updates ! 

I really would appreciate a workaround for this (and other bugs) - although
it's not the best way to implement software but in the moment the only
chance for my project. 

regards
Thomas  

-----Ursprüngliche Nachricht-----
Von: Mark Struberg [mailto:struberg@yahoo.de] 
Gesendet: Samstag, 21. Mai 2011 12:01
An: MyFaces Discussion
Betreff: Re: AW: CODI @ViewAccessScoped not cleaned up?

I'm not really conviced that we should implement workarounds for such
clearly broken weld issues. 

Thomas, did you already file a bug report in Weld marking this as blocker?
Really, we should at least link to them in our sources (+jira) and asap get
rid of this workaround in OUR source again. Otherwise we will end up with
unmaintainable CODI sources.

LieGrue,
strub
 
--- On Sat, 5/21/11, Ing.Thomas Kernstock <t....@e-technologies.at>
wrote:

> From: Ing.Thomas Kernstock <t....@e-technologies.at>
> Subject: AW: CODI @ViewAccessScoped not cleaned up?
> To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> Date: Saturday, May 21, 2011, 1:17 AM
> that's what I expected :-) The
> chances that weld causes the problem where rather huge  (as we 
> discussed earlier).
> have a good one
> thomas
> 
> 
> -----Ursprüngliche Nachricht-----
> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> 
> Gesendet: Freitag, 20. Mai 2011 21:08
> An: MyFaces Discussion
> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> 
> hi thomas,
> 
> this part of codi hasn't changed since the first release whereas weld 
> changed a lot.
> 
> regards,
> gerhard
> 
> http://www.irian.at
> 
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
> 
> Professional Support for Apache MyFaces
> 
> 
> 
> 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> 
> > Hi Gerhard,
> >
> > I Think you are right - this problem exists either
> since Codi 0.9.4 or
> > Glassfish3.1(Weld 1.1.1). This explains why I see
> extra database
> > updates (in my logfiles) of entities that should have
> been destroyed
> > allready. On Glassfish 3.0.1 with CODI 0.9.3 this
> worked fine !
> >
> > best regards
> > Thomas
> >
> > ___________________________________
> > -----Ursprüngliche Nachricht-----
> > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > Gesendet: Freitag, 20. Mai 2011 19:35
> > An: MyFaces Discussion
> > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >
> > hi gernot,
> >
> > @PreDestroy will be called after rendering the first
> page which
> > doesn't use the bean.
> > it looks like a weld bug (i see the same with weld
> v1.1.1).
> > i tested it with owb and it works as expected.
> > i'll have a look at it, if there is a possible
> workaround for weld.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> >
> > > Hi,
> > >
> > > I'm using Glassfish 3.1 and CODI 0.9.5
> > >
> > > I've a bean A annotated with @ViewAccessScoped.
> > >
> > > Bean A is used in page1.xhtml. If page1 is called
> from page1 the
> > > state of the bean is preserved (as expected).
> > >
> > > Then I navigate to page2.xhtml (which does not
> have any reference to
> > > bean A), an then I navigate (from page2) to
> page3.xhtml (which also
> > > does not have any reference to bean A).
> > > At this point I supposed bean A has bean
> invalidated/removed - but a
> > > @PreDestroy is never calles
> > >
> > > Now I navigate (from page3) to page1.xhtml - and
> bean A has the
> > > previous values and not an inital state.
> > >
> > > Do I misunderstand the @ViewAccessScoped or is
> there something wrong?
> > >
> > > regards,
> > > Gernot
> > >
> >
> >
> 
> 



Re: AW: CODI @ViewAccessScoped not cleaned up?

Posted by Mark Struberg <st...@yahoo.de>.
I'm not really conviced that we should implement workarounds for such clearly broken weld issues. 

Thomas, did you already file a bug report in Weld marking this as blocker? Really, we should at least link to them in our sources (+jira) and asap get rid of this workaround in OUR source again. Otherwise we will end up with unmaintainable CODI sources.

LieGrue,
strub
 
--- On Sat, 5/21/11, Ing.Thomas Kernstock <t....@e-technologies.at> wrote:

> From: Ing.Thomas Kernstock <t....@e-technologies.at>
> Subject: AW: CODI @ViewAccessScoped not cleaned up?
> To: "'MyFaces Discussion'" <us...@myfaces.apache.org>
> Date: Saturday, May 21, 2011, 1:17 AM
> that's what I expected :-) The
> chances that weld causes the problem where
> rather huge  (as we discussed earlier).
> have a good one
> thomas
> 
> 
> -----Ursprüngliche Nachricht-----
> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> 
> Gesendet: Freitag, 20. Mai 2011 21:08
> An: MyFaces Discussion
> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> 
> hi thomas,
> 
> this part of codi hasn't changed since the first release
> whereas weld
> changed a lot.
> 
> regards,
> gerhard
> 
> http://www.irian.at
> 
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
> 
> Professional Support for Apache MyFaces
> 
> 
> 
> 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> 
> > Hi Gerhard,
> >
> > I Think you are right - this problem exists either
> since Codi 0.9.4 or 
> > Glassfish3.1(Weld 1.1.1). This explains why I see
> extra database 
> > updates (in my logfiles) of entities that should have
> been destroyed 
> > allready. On Glassfish 3.0.1 with CODI 0.9.3 this
> worked fine !
> >
> > best regards
> > Thomas
> >
> > ___________________________________
> > -----Ursprüngliche Nachricht-----
> > Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> > Gesendet: Freitag, 20. Mai 2011 19:35
> > An: MyFaces Discussion
> > Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >
> > hi gernot,
> >
> > @PreDestroy will be called after rendering the first
> page which 
> > doesn't use the bean.
> > it looks like a weld bug (i see the same with weld
> v1.1.1).
> > i tested it with owb and it works as expected.
> > i'll have a look at it, if there is a possible
> workaround for weld.
> >
> > regards,
> > gerhard
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> > 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> >
> > > Hi,
> > >
> > > I'm using Glassfish 3.1 and CODI 0.9.5
> > >
> > > I've a bean A annotated with @ViewAccessScoped.
> > >
> > > Bean A is used in page1.xhtml. If page1 is called
> from page1 the 
> > > state of the bean is preserved (as expected).
> > >
> > > Then I navigate to page2.xhtml (which does not
> have any reference to 
> > > bean A), an then I navigate (from page2) to
> page3.xhtml (which also 
> > > does not have any reference to bean A).
> > > At this point I supposed bean A has bean
> invalidated/removed - but a 
> > > @PreDestroy is never calles
> > >
> > > Now I navigate (from page3) to page1.xhtml - and
> bean A has the 
> > > previous values and not an inital state.
> > >
> > > Do I misunderstand the @ViewAccessScoped or is
> there something wrong?
> > >
> > > regards,
> > > Gernot
> > >
> >
> >
> 
> 

AW: CODI @ViewAccessScoped not cleaned up?

Posted by "Ing.Thomas Kernstock" <t....@e-technologies.at>.
that's what I expected :-) The chances that weld causes the problem where
rather huge  (as we discussed earlier).
have a good one
thomas


-----Ursprüngliche Nachricht-----
Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com] 
Gesendet: Freitag, 20. Mai 2011 21:08
An: MyFaces Discussion
Betreff: Re: CODI @ViewAccessScoped not cleaned up?

hi thomas,

this part of codi hasn't changed since the first release whereas weld
changed a lot.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>

> Hi Gerhard,
>
> I Think you are right - this problem exists either since Codi 0.9.4 or 
> Glassfish3.1(Weld 1.1.1). This explains why I see extra database 
> updates (in my logfiles) of entities that should have been destroyed 
> allready. On Glassfish 3.0.1 with CODI 0.9.3 this worked fine !
>
> best regards
> Thomas
>
> ___________________________________
> -----Ursprüngliche Nachricht-----
> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> Gesendet: Freitag, 20. Mai 2011 19:35
> An: MyFaces Discussion
> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
>
> hi gernot,
>
> @PreDestroy will be called after rendering the first page which 
> doesn't use the bean.
> it looks like a weld bug (i see the same with weld v1.1.1).
> i tested it with owb and it works as expected.
> i'll have a look at it, if there is a possible workaround for weld.
>
> regards,
> gerhard
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
>
> > Hi,
> >
> > I'm using Glassfish 3.1 and CODI 0.9.5
> >
> > I've a bean A annotated with @ViewAccessScoped.
> >
> > Bean A is used in page1.xhtml. If page1 is called from page1 the 
> > state of the bean is preserved (as expected).
> >
> > Then I navigate to page2.xhtml (which does not have any reference to 
> > bean A), an then I navigate (from page2) to page3.xhtml (which also 
> > does not have any reference to bean A).
> > At this point I supposed bean A has bean invalidated/removed - but a 
> > @PreDestroy is never calles
> >
> > Now I navigate (from page3) to page1.xhtml - and bean A has the 
> > previous values and not an inital state.
> >
> > Do I misunderstand the @ViewAccessScoped or is there something wrong?
> >
> > regards,
> > Gernot
> >
>
>


Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi gernot,

in the maven snapshot repository [1] btw. [2].

regards,
gerhard

[1] https://repository.apache.org/content/repositories/snapshots/
[2]
https://repository.apache.org/content/repositories/snapshots/org/apache/myfaces/extensions/cdi/

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


2011/5/27 Gernot <ge...@nurfuerspam.de>

> hi,
>
> thanks for the fix - but where can I find the nightly builds?
>
> regards, gernot
>
> 2011/5/20 Gerhard Petracek <ge...@gmail.com>:
> > hi,
> >
> > i found a workaround [1]. you can build the latest version of codi
> manually
> > or you wait for the nightly build.
> >
> > regards,
> > gerhard
> >
> > [1] https://issues.apache.org/jira/browse/EXTCDI-191
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
> >
> >
> > 2011/5/20 Gerhard Petracek <ge...@gmail.com>
> >
> >> hi thomas,
> >>
> >> this part of codi hasn't changed since the first release whereas weld
> >> changed a lot.
> >>
> >> regards,
> >> gerhard
> >>
> >> http://www.irian.at
> >>
> >> Your JSF powerhouse -
> >> JSF Consulting, Development and
> >> Courses in English and German
> >>
> >> Professional Support for Apache MyFaces
> >>
> >>
> >>
> >> 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
> >>
> >> Hi Gerhard,
> >>>
> >>> I Think you are right - this problem exists either since Codi 0.9.4 or
> >>> Glassfish3.1(Weld 1.1.1). This explains why I see extra database
> updates
> >>> (in
> >>> my logfiles) of entities that should have been destroyed allready. On
> >>> Glassfish 3.0.1 with CODI 0.9.3 this worked fine !
> >>>
> >>> best regards
> >>> Thomas
> >>>
> >>> ___________________________________
> >>> -----Ursprüngliche Nachricht-----
> >>> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> >>> Gesendet: Freitag, 20. Mai 2011 19:35
> >>> An: MyFaces Discussion
> >>> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
> >>>
> >>> hi gernot,
> >>>
> >>> @PreDestroy will be called after rendering the first page which doesn't
> >>> use
> >>> the bean.
> >>> it looks like a weld bug (i see the same with weld v1.1.1).
> >>> i tested it with owb and it works as expected.
> >>> i'll have a look at it, if there is a possible workaround for weld.
> >>>
> >>> regards,
> >>> gerhard
> >>>
> >>> http://www.irian.at
> >>>
> >>> Your JSF powerhouse -
> >>> JSF Consulting, Development and
> >>> Courses in English and German
> >>>
> >>> Professional Support for Apache MyFaces
> >>>
> >>>
> >>> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
> >>>
> >>> > Hi,
> >>> >
> >>> > I'm using Glassfish 3.1 and CODI 0.9.5
> >>> >
> >>> > I've a bean A annotated with @ViewAccessScoped.
> >>> >
> >>> > Bean A is used in page1.xhtml. If page1 is called from page1 the
> state
> >>> > of the bean is preserved (as expected).
> >>> >
> >>> > Then I navigate to page2.xhtml (which does not have any reference to
> >>> > bean A), an then I navigate (from page2) to page3.xhtml (which also
> >>> > does not have any reference to bean A).
> >>> > At this point I supposed bean A has bean invalidated/removed - but a
> >>> > @PreDestroy is never calles
> >>> >
> >>> > Now I navigate (from page3) to page1.xhtml - and bean A has the
> >>> > previous values and not an inital state.
> >>> >
> >>> > Do I misunderstand the @ViewAccessScoped or is there something wrong?
> >>> >
> >>> > regards,
> >>> > Gernot
> >>> >
> >>>
> >>>
> >>
> >
>

Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gernot <ge...@nurfuerspam.de>.
hi,

thanks for the fix - but where can I find the nightly builds?

regards, gernot

2011/5/20 Gerhard Petracek <ge...@gmail.com>:
> hi,
>
> i found a workaround [1]. you can build the latest version of codi manually
> or you wait for the nightly build.
>
> regards,
> gerhard
>
> [1] https://issues.apache.org/jira/browse/EXTCDI-191
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
>
> 2011/5/20 Gerhard Petracek <ge...@gmail.com>
>
>> hi thomas,
>>
>> this part of codi hasn't changed since the first release whereas weld
>> changed a lot.
>>
>> regards,
>> gerhard
>>
>> http://www.irian.at
>>
>> Your JSF powerhouse -
>> JSF Consulting, Development and
>> Courses in English and German
>>
>> Professional Support for Apache MyFaces
>>
>>
>>
>> 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
>>
>> Hi Gerhard,
>>>
>>> I Think you are right - this problem exists either since Codi 0.9.4 or
>>> Glassfish3.1(Weld 1.1.1). This explains why I see extra database updates
>>> (in
>>> my logfiles) of entities that should have been destroyed allready. On
>>> Glassfish 3.0.1 with CODI 0.9.3 this worked fine !
>>>
>>> best regards
>>> Thomas
>>>
>>> ___________________________________
>>> -----Ursprüngliche Nachricht-----
>>> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
>>> Gesendet: Freitag, 20. Mai 2011 19:35
>>> An: MyFaces Discussion
>>> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
>>>
>>> hi gernot,
>>>
>>> @PreDestroy will be called after rendering the first page which doesn't
>>> use
>>> the bean.
>>> it looks like a weld bug (i see the same with weld v1.1.1).
>>> i tested it with owb and it works as expected.
>>> i'll have a look at it, if there is a possible workaround for weld.
>>>
>>> regards,
>>> gerhard
>>>
>>> http://www.irian.at
>>>
>>> Your JSF powerhouse -
>>> JSF Consulting, Development and
>>> Courses in English and German
>>>
>>> Professional Support for Apache MyFaces
>>>
>>>
>>> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
>>>
>>> > Hi,
>>> >
>>> > I'm using Glassfish 3.1 and CODI 0.9.5
>>> >
>>> > I've a bean A annotated with @ViewAccessScoped.
>>> >
>>> > Bean A is used in page1.xhtml. If page1 is called from page1 the state
>>> > of the bean is preserved (as expected).
>>> >
>>> > Then I navigate to page2.xhtml (which does not have any reference to
>>> > bean A), an then I navigate (from page2) to page3.xhtml (which also
>>> > does not have any reference to bean A).
>>> > At this point I supposed bean A has bean invalidated/removed - but a
>>> > @PreDestroy is never calles
>>> >
>>> > Now I navigate (from page3) to page1.xhtml - and bean A has the
>>> > previous values and not an inital state.
>>> >
>>> > Do I misunderstand the @ViewAccessScoped or is there something wrong?
>>> >
>>> > regards,
>>> > Gernot
>>> >
>>>
>>>
>>
>

Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi,

i found a workaround [1]. you can build the latest version of codi manually
or you wait for the nightly build.

regards,
gerhard

[1] https://issues.apache.org/jira/browse/EXTCDI-191

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/20 Gerhard Petracek <ge...@gmail.com>

> hi thomas,
>
> this part of codi hasn't changed since the first release whereas weld
> changed a lot.
>
> regards,
> gerhard
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
>
> 2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>
>
> Hi Gerhard,
>>
>> I Think you are right - this problem exists either since Codi 0.9.4 or
>> Glassfish3.1(Weld 1.1.1). This explains why I see extra database updates
>> (in
>> my logfiles) of entities that should have been destroyed allready. On
>> Glassfish 3.0.1 with CODI 0.9.3 this worked fine !
>>
>> best regards
>> Thomas
>>
>> ___________________________________
>> -----Ursprüngliche Nachricht-----
>> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
>> Gesendet: Freitag, 20. Mai 2011 19:35
>> An: MyFaces Discussion
>> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
>>
>> hi gernot,
>>
>> @PreDestroy will be called after rendering the first page which doesn't
>> use
>> the bean.
>> it looks like a weld bug (i see the same with weld v1.1.1).
>> i tested it with owb and it works as expected.
>> i'll have a look at it, if there is a possible workaround for weld.
>>
>> regards,
>> gerhard
>>
>> http://www.irian.at
>>
>> Your JSF powerhouse -
>> JSF Consulting, Development and
>> Courses in English and German
>>
>> Professional Support for Apache MyFaces
>>
>>
>> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
>>
>> > Hi,
>> >
>> > I'm using Glassfish 3.1 and CODI 0.9.5
>> >
>> > I've a bean A annotated with @ViewAccessScoped.
>> >
>> > Bean A is used in page1.xhtml. If page1 is called from page1 the state
>> > of the bean is preserved (as expected).
>> >
>> > Then I navigate to page2.xhtml (which does not have any reference to
>> > bean A), an then I navigate (from page2) to page3.xhtml (which also
>> > does not have any reference to bean A).
>> > At this point I supposed bean A has bean invalidated/removed - but a
>> > @PreDestroy is never calles
>> >
>> > Now I navigate (from page3) to page1.xhtml - and bean A has the
>> > previous values and not an inital state.
>> >
>> > Do I misunderstand the @ViewAccessScoped or is there something wrong?
>> >
>> > regards,
>> > Gernot
>> >
>>
>>
>

Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi thomas,

this part of codi hasn't changed since the first release whereas weld
changed a lot.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces



2011/5/20 Ing.Thomas Kernstock <t....@e-technologies.at>

> Hi Gerhard,
>
> I Think you are right - this problem exists either since Codi 0.9.4 or
> Glassfish3.1(Weld 1.1.1). This explains why I see extra database updates
> (in
> my logfiles) of entities that should have been destroyed allready. On
> Glassfish 3.0.1 with CODI 0.9.3 this worked fine !
>
> best regards
> Thomas
>
> ___________________________________
> -----Ursprüngliche Nachricht-----
> Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com]
> Gesendet: Freitag, 20. Mai 2011 19:35
> An: MyFaces Discussion
> Betreff: Re: CODI @ViewAccessScoped not cleaned up?
>
> hi gernot,
>
> @PreDestroy will be called after rendering the first page which doesn't use
> the bean.
> it looks like a weld bug (i see the same with weld v1.1.1).
> i tested it with owb and it works as expected.
> i'll have a look at it, if there is a possible workaround for weld.
>
> regards,
> gerhard
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
>
> > Hi,
> >
> > I'm using Glassfish 3.1 and CODI 0.9.5
> >
> > I've a bean A annotated with @ViewAccessScoped.
> >
> > Bean A is used in page1.xhtml. If page1 is called from page1 the state
> > of the bean is preserved (as expected).
> >
> > Then I navigate to page2.xhtml (which does not have any reference to
> > bean A), an then I navigate (from page2) to page3.xhtml (which also
> > does not have any reference to bean A).
> > At this point I supposed bean A has bean invalidated/removed - but a
> > @PreDestroy is never calles
> >
> > Now I navigate (from page3) to page1.xhtml - and bean A has the
> > previous values and not an inital state.
> >
> > Do I misunderstand the @ViewAccessScoped or is there something wrong?
> >
> > regards,
> > Gernot
> >
>
>

AW: CODI @ViewAccessScoped not cleaned up?

Posted by "Ing.Thomas Kernstock" <t....@e-technologies.at>.
Hi Gerhard, 

I Think you are right - this problem exists either since Codi 0.9.4 or
Glassfish3.1(Weld 1.1.1). This explains why I see extra database updates (in
my logfiles) of entities that should have been destroyed allready. On
Glassfish 3.0.1 with CODI 0.9.3 this worked fine !

best regards
Thomas

___________________________________
-----Ursprüngliche Nachricht-----
Von: Gerhard Petracek [mailto:gerhard.petracek@gmail.com] 
Gesendet: Freitag, 20. Mai 2011 19:35
An: MyFaces Discussion
Betreff: Re: CODI @ViewAccessScoped not cleaned up?

hi gernot,

@PreDestroy will be called after rendering the first page which doesn't use
the bean.
it looks like a weld bug (i see the same with weld v1.1.1).
i tested it with owb and it works as expected.
i'll have a look at it, if there is a possible workaround for weld.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


2011/5/20 Gernot Pfingstl <ge...@gmx.at>

> Hi,
>
> I'm using Glassfish 3.1 and CODI 0.9.5
>
> I've a bean A annotated with @ViewAccessScoped.
>
> Bean A is used in page1.xhtml. If page1 is called from page1 the state 
> of the bean is preserved (as expected).
>
> Then I navigate to page2.xhtml (which does not have any reference to 
> bean A), an then I navigate (from page2) to page3.xhtml (which also 
> does not have any reference to bean A).
> At this point I supposed bean A has bean invalidated/removed - but a 
> @PreDestroy is never calles
>
> Now I navigate (from page3) to page1.xhtml - and bean A has the 
> previous values and not an inital state.
>
> Do I misunderstand the @ViewAccessScoped or is there something wrong?
>
> regards,
> Gernot
>


Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi gernot,

the bean-manager of weld doesn't find beans for qualifiers which were
created by weld itself.
there is a special logic for detecting the type of the conversation and if
no special conversation type is found, the normal codi-conversation scope
gets used.
due to the weld bug, the detection fails and you get a normal
conversation-scoped bean.
the original test with glassfish v3.0 worked. it looks like a
new bean-manager bug of weld.
i'll test a workaround for weld.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


2011/5/20 Gerhard Petracek <ge...@gmail.com>

> hi gernot,
>
> @PreDestroy will be called after rendering the first page which doesn't use
> the bean.
> it looks like a weld bug (i see the same with weld v1.1.1).
> i tested it with owb and it works as expected.
> i'll have a look at it, if there is a possible workaround for weld.
>
> regards,
> gerhard
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>
>
>
> 2011/5/20 Gernot Pfingstl <ge...@gmx.at>
>
>> Hi,
>>
>> I'm using Glassfish 3.1 and CODI 0.9.5
>>
>> I've a bean A annotated with @ViewAccessScoped.
>>
>> Bean A is used in page1.xhtml. If page1 is called from page1 the state
>> of the bean is preserved (as expected).
>>
>> Then I navigate to page2.xhtml (which does not have any reference to
>> bean A), an then I navigate (from page2) to page3.xhtml (which also
>> does not have any reference to bean A).
>> At this point I supposed bean A has bean invalidated/removed - but a
>> @PreDestroy is never calles
>>
>> Now I navigate (from page3) to page1.xhtml - and bean A has the
>> previous values and not an inital state.
>>
>> Do I misunderstand the @ViewAccessScoped or is there something wrong?
>>
>> regards,
>> Gernot
>>
>
>

Re: CODI @ViewAccessScoped not cleaned up?

Posted by Gerhard Petracek <ge...@gmail.com>.
hi gernot,

@PreDestroy will be called after rendering the first page which doesn't use
the bean.
it looks like a weld bug (i see the same with weld v1.1.1).
i tested it with owb and it works as expected.
i'll have a look at it, if there is a possible workaround for weld.

regards,
gerhard

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


2011/5/20 Gernot Pfingstl <ge...@gmx.at>

> Hi,
>
> I'm using Glassfish 3.1 and CODI 0.9.5
>
> I've a bean A annotated with @ViewAccessScoped.
>
> Bean A is used in page1.xhtml. If page1 is called from page1 the state
> of the bean is preserved (as expected).
>
> Then I navigate to page2.xhtml (which does not have any reference to
> bean A), an then I navigate (from page2) to page3.xhtml (which also
> does not have any reference to bean A).
> At this point I supposed bean A has bean invalidated/removed - but a
> @PreDestroy is never calles
>
> Now I navigate (from page3) to page1.xhtml - and bean A has the
> previous values and not an inital state.
>
> Do I misunderstand the @ViewAccessScoped or is there something wrong?
>
> regards,
> Gernot
>