Re: [jira] @PreDestroy, Servlet API,

2007-03-12 Thread djencks
This thread seems to have died down. I've tried to start a new thread on a related proposal I've come up with while thinking about how to integrate MyFaces into geronimo, the subject is Proposal for annotation processing and there's a related jira issue

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Hello Dennis, why we should look at the RI? Can we use this Interface http://tomcat.apache.org/tomcat-6.0-doc/api/org/apache/AnnotationProcessor.html? Why you don't like to import javax.annotation. in the code. If the annotation are missing in the container the annotations in the managed

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
On 3/3/07, Bernd Bohmann [EMAIL PROTECTED] wrote: Hello Dennis, why we should look at the RI? I'd prefer doing things that is compatible with them. This is easier on the users and it makes passing TCK smoother. Can we use this Interface

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Hello Dennis, I think the interface has nothing to do with tomcat. Would the interface meet your requirements? If yes, I would suggest following: Create a AnnotationProcessorFactory which return as default an AnnotationProcessor who is a copy of the tomcat DefaultAnnotationProcessor(the

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Paul McMahan
OK, I think the RI also recently added the META-INF/services technique. But I don't know how reliable this sun blog entry is: http://tinyurl.com/yrrjs2 Best wishes, Paul On 3/2/07, Mathias Brökelmann [EMAIL PROTECTED] wrote: The RI uses two ways to lookup the implementation of the vendor

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
I added a comment http://blogs.sun.com/rlubke/entry/jsf_ri_1_2_and#comment-1172947192023 . Two more ideas. Ryan mentions applications using facelets, jsf 1.2 and servlet 2.4. Unless I'm missing something, there's one reason to use annotation.getName().equals(javax.annotation.PostConstruct)

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Just added an implementation of the annotation handling based on the tomcat implementation. Bernd Dennis Byrne wrote: I added a comment http://blogs.sun.com/rlubke/entry/jsf_ri_1_2_and#comment-1172947192023 . Two more ideas. Ryan mentions applications using facelets, jsf 1.2 and servlet

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
Are you under the impression that our 1.2 branch didn't already handle @PostConstruct and @PreDestroy? Looks like the left hand doesn't know what the right hand is doing here. Dennis Byrne On 3/3/07, Bernd Bohmann [EMAIL PROTECTED] wrote: Just added an implementation of the annotation

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
??? Yes, I know it. Dennis Byrne wrote: Are you under the impression that our 1.2 branch didn't already handle @PostConstruct and @PreDestroy? Looks like the left hand doesn't know what the right hand is doing here. Dennis Byrne On 3/3/07, Bernd Bohmann [EMAIL PROTECTED] wrote: Just added

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
Mathias, me and Paul were discussing the future of this feature. For the most part we were in agreement. I appreciate your input, but it did not gain traction w/ anyone. You then went ahead and committed a bunch of code. IMO, you have not been a good team member today Bernd. Please assign

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Sorry, I ask you if it's ok to add the code. I get no answer then I asume it's ok to add my idea. It's only a different possible implementation. If you don't like it you can remove it. Is anything wrong with the code? Bernd Dennis Byrne wrote: Mathias, me and Paul were discussing the future

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Just revert my commit Dennis Byrne wrote: Mathias, me and Paul were discussing the future of this feature. For the most part we were in agreement. I appreciate your input, but it did not gain traction w/ anyone. You then went ahead and committed a bunch of code. IMO, you have not been a

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Mathias Brökelmann
No code in myfaces (or any other apache project) is owned by someone. That is important for a healthy and moving community. Bernds submission was a little bit fast but sometimes a complex issue is better understand if we can look at the code - no matter if that is the solution we finally have. I

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
I don't hold anything against you. Ultimately I feel like this is a lose-lose situation for MyFaces because where things stand now, you are likely to feel as though your efforts on that branch are not appreciated. They are. Ryan has responded ...

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
On 3/3/07, Mathias Brökelmann [EMAIL PROTECTED] wrote: No code in myfaces (or any other apache project) is owned by someone. That is important for a healthy and moving community. Bernds submission was a little bit fast but sometimes a complex issue is better understand if we can look at the

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Bernd Bohmann
Hello Dennis, should i readd the other possible implementation? :-) But I should write my own TestCases. I think it should be possible to use the PostConstruct and PreDestroy Annotations with tomcat 5.5 and facelets. When a InitialContext is available we should try resource injection, too.

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Remy Maucherat
Bernd Bohmann wrote: The AnnotationProcessor/InjectionProvider are very similar. I don't like to define a new myfaces Interface for this use case. I would prefer the org.apache.AnnotationProcessor because is not tomcat specific and an apache implementation. Until we find a final solution we

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Dennis Byrne
Unfortunately, I don't see a way to do non proprietary annotation/injection processing, since the component that has to do it (JSP or JSF) cannot possibly get the configuration (which could define overrides, etc). Since I suppose you'll want to support all containers, that's a problem. (It would

Re: @PreDestroy, Servlet API,

2007-03-03 Thread Jacob Hookom
There were a few of us that wanted to push back on the WebTier EG around annotation support over the fact that there wasn't a clear API provided-- yet oddly enough, everyone is ending up with basically the same API :-) My hope is that the WebBeans JSR can bring some solidarity around this

Re: @PreDestroy, Servlet API,

2007-03-02 Thread Dennis Byrne
Similar to what Mathias mentioned? http://issues.apache.org/jira/browse/MYFACES-1246#action_12475337 It's not much work (on our side) but it sounds pretty vendor specific. Again, I don't have a better solution. Mathias writes which is implemented by j2ee containers. I wonder if each container

Re: @PreDestroy, Servlet API,

2007-03-02 Thread Mathias Brökelmann
The RI uses two ways to lookup the implementation of the vendor specific implementation of the InjectionProvider. They first try to use a web context init param and if that is not configured they simply use a system property. Both keyed by the class name of the InjectionProvider interface.

Re: @PreDestroy, Servlet API,

2007-03-02 Thread Dennis Byrne
Are any of these class names or context params start w/ javax.faces ? If so, we can move the conversation back into the issue tracker and I'll close the @PostConstruct issue once Paul says it's good to go. I don't see the point of the system property though. Dennis Byrne On 3/2/07, Mathias

Re: @PreDestroy, Servlet API,

2007-03-02 Thread Mathias Brökelmann
The RI looks for com.sun.faces.spi.InjectionProvider for a class name which implements this interface. It would have been very nice if this is part of the spec. But that is not the case so we need to find a way to support any kind of j2ee container. IMO injecting j2ee resources without knowing

Re: @PreDestroy, Servlet API,

2007-03-02 Thread Dennis Byrne
As much as I agree w/ you about how better things would be if this were in the spec, and as much as I hate to bow down here, I am actually OK with using com.sun.faces.spi.InjectionProvider as the parameter in MyFaces as well ... for the sake of users. If anyone has a problem w/ it, we can go

Re: @PreDestroy, Servlet API,

2007-03-01 Thread Paul McMahan
OK, I think your interpretation of the spec makes sense and there's one particular aspect we should discuss a little further. The container doesn't know which classes are managed beans so it wouldn't know when to intercept the instantiation process to perform injection. What would you all think

Re: @PreDestroy, Servlet API,

2007-02-26 Thread Paul McMahan
Sorry if I'm behind on this discussion but what are the current thoughts on how dependency injection will be implemented for managed beans? The reason I'm curious is because PreDestroy and PostConstruct annotations are used to deal with injected resources, so from a timing perspective it would

Re: @PreDestroy, Servlet API,

2007-02-26 Thread Dennis Byrne
I ended up going with Servlet/Request/Context attribute listeners for @PreDestroy. This did not involve importing javax.annotation.PreDestroy, so people w/out application servers don't have to worry about ClassDefNotFoundErrors. This also keeps us compatible with the reference implementation in

Re: @PreDestroy, Servlet API,

2007-02-26 Thread Paul McMahan
Actually by dependency injection I'm specifically referring to the portion of the JSF spec that discusses injecting resources where certain annotations are found in a managed bean. So, while scanning for the @PreConstruct and @PostDestroy annotations MyFaces would also scan for @EJB, @Resource,

Re: @PreDestroy, Servlet API,

2007-02-26 Thread Dennis Byrne
I know the specs can be vague sometimes, but I don't interpret the first paragraph of section 5.4 as meaning the JSF implementation is responsible for @EJB, @Resources, etc. The JSF spec specifically mentions the container to inject references. If Geronimo can intercept the instantiation of