[jira] Created: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Mark Struberg (JIRA)
OWB picks up @SessionScoped contextual instances from expired sessions -- Key: OWB-351 URL: https://issues.apache.org/jira/browse/OWB-351 Project: OpenWebBeans Issue Type:

ContextsService for standalone applications

2010-04-12 Thread Mario Ivankovits
Hi! I am developing a standalone Swing Application and trying to make use of CDI (using openwebbeans). Also for being more fit when discussing Orchestra related things :-) Naturally a Swing Application consists of multiple threads. At least the main thread and the so called Event

AW: svn commit: r933198 - in /openwebbeans/trunk/webbeans-impl/src/test/java/org/apache/webbeans/newtests/contexts/session: common/AppScopedBean.java common/PersonalDataBean.java tests/SessionContextT

2010-04-12 Thread Mark Struberg
Hi! I now added a really simple test which shows the problems with OWB-351. Please be aware that this will currently break the build! But since this is a blocker, we should get rid of those problems really soon. Thus, the more pain the more quickly we will fix it ;) If you like to build OWB,

EE-Integration Question: How does one do CDI injection on Java EE component classes ?

2010-04-12 Thread Rohit Kelapure
Team, OpenWebBeans provides the ResourceInjectionService API for injection of Java EE injectable resources into CDI managed beans. This works well and we have integrated the ResourceInjectionService API in our EE container. We need guidance on how OWB handles CDI managed bean injection into

Re: EE-Integration Question: How does one do CDI injection on Java EE component classes ?

2010-04-12 Thread Gurkan Erdogdu
Hello Rohit; Could you look at the OWBInjector utility class? This is responsible for injecting into EE components instances. When EE container destroys EE component, you will also destroy creational contexts via OWBInjector. OWBInjector injector = new OWBInjector(); injector.inject(instance,

Re: ContextsService for standalone applications

2010-04-12 Thread Gurkan Erdogdu
Hello; That is great news, creating a maven module with webbeans-se. In the mean time, could you look at org.apache.webbeans.boot.Bootstrap class. Also there is a Java Swing sample, maybe you could want to look at it, it is located in the samples/standalone-sample. Thanks; --Gurkan

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Gurkan Erdogdu (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12855985#action_12855985 ] Gurkan Erdogdu commented on OWB-351: In session destruction, we destroy context and

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Mark Struberg (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12855987#action_12855987 ] Mark Struberg commented on OWB-351: --- In fact the Context is really destroyed, but our proxy

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Gurkan Erdogdu (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12855994#action_12855994 ] Gurkan Erdogdu commented on OWB-351: This is problem because of not clearing

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Gurkan Erdogdu (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12856000#action_12856000 ] Gurkan Erdogdu commented on OWB-351: I have update, now test is working OWB picks up

[jira] Resolved: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Mark Struberg (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Mark Struberg resolved OWB-351. --- Resolution: Fixed OWB picks up @SessionScoped contextual instances from expired sessions

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Mark Struberg (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12856075#action_12856075 ] Mark Struberg commented on OWB-351: --- There is currently a discussion ongoing if cyclic

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Gurkan Erdogdu (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12856083#action_12856083 ] Gurkan Erdogdu commented on OWB-351: Commits on interceptor handlers eat the client

[jira] Commented: (OWB-351) OWB picks up @SessionScoped contextual instances from expired sessions

2010-04-12 Thread Mark Struberg (JIRA)
[ https://issues.apache.org/jira/browse/OWB-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12856094#action_12856094 ] Mark Struberg commented on OWB-351: --- this got removed intentionally because it is usually

AW: svn commit: r933348 - in /openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept: ApplicationScopedBeanIntereptorHandler.java DependentScopedBeanInterceptorHandler.java Inter

2010-04-12 Thread Mark Struberg
Sorry, I think we need to rollback the rollback, since this re-introduces really heavy concurrency problems. @SessionScoped public class User [ public String getEmail().. } @ApplicationScoped class MailService { private @Inject User usr; public void sendMail(String content) {

AW: svn commit: r933376 - in /openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans: container/InjectionResolver.java context/AbstractContext.java context/creational/CreationalContextImpl

2010-04-12 Thread Mark Struberg
I'm not sure if the incompleteInstance needs to be volatile, since the creation should only get called from one thread. In fact, we must make sure that the Context for must allow creating a bean at a time by calling Contextual#create(). At least for @ApplicationScoped, @Singleton,

Re: svn commit: r933348 - in /openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept: ApplicationScopedBeanIntereptorHandler.java DependentScopedBeanInterceptorHandler.java Int

2010-04-12 Thread Mark Struberg
This makes no difference, really. The problem is that we store a CreationalContext as a member in NormalScopedBeanInterceptorHandler. And subsequent function calls rely on it. But if in the meantime _another_ thread overwrites this NormalScopedBeanInterceptorHandler.creationalContext (by using

Re: svn commit: r933348 - in /openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/intercept: ApplicationScopedBeanIntereptorHandler.java DependentScopedBeanInterceptorHandler.java Int

2010-04-12 Thread Gurkan Erdogdu
Please attach a small web application code that shows your issue. Without it, it is very hard to visualize your siutation. As a side note, serialization issues always a problem in Java Web Applications. You have to manage this via synchoronization blocks or third party other libs, for example