[appengine-java] Re: javax.annotation.Resource Spring 3.0.0.Release declarative DI on Google App Engine

2010-02-10 Thread Marcel Overdijk
Larry,

Check out https://jira.springsource.org/browse/SPR-6679 and please
vote.



On Feb 10, 7:11 pm, Larry Cable  wrote:
> Not sure if this  helps or not but you cannot use the Spring
>
> 
>
> markup in your GAE Spring applications ...
>
> This will of course work locally but because the
> CommonAnnotationBeanPostProcessor attempts to 
> loadjavax.annotation.Resource(and fails) then no annotation processing
> will occur ...
>
> there are 2 workarounds to this:
>
> 1) use the init-method="..." attribute of the  element
>
> or ...
>
> 2) directly load the appropriate annotation processing beans like so:
>
>          class="org.springframework.beans.factory.annotation.AutowiredAnnotationBean 
> PostProcessor" /
>
>
>
>          class="org.springframework.context.annotation.ConfigurationClassPostProcess 
> or" /
>
>
>
>          class="org.springframework.beans.factory.annotation.InitDestroyAnnotationBe 
> anPostProcessor">
>                  value="javax.annotation.PostConstruct" />
>                  value="javax.annotation.PreDestroy" />
>         
>
> This avoids the attempt to load the @Resource class ...
>
> On Jan 22, 2:21 am, Vijay Bansal  wrote:
>
>
>
> > This is of some help to those who are trying for CXF-RS apps on 
> > GAEhttp://sinister2010.wordpress.com/2010/01/22/cxf-rs-on-google-app-eng...
>
> > On Jan 14, 12:43 am, "Jason (Google)"  wrote:
>
> > > Hi Ralf. We may be able to add support for this annotation in a 
> > > forthcoming
> > > release. Please star the issue in your post if you want to be notified of
> > > any status changes.
>
> > > - Jason
>
> > > On Sat, Jan 2, 2010 at 3:27 AM, Ralf Sigmund  
> > > wrote:
> > > > Hi,
> > > > i am a newbie to App Engine. So I tried to do some of my Spring
> > > > 3.0.0.RELEASE demo stuff.
>
> > > > When using my favourite JAX-RS Implementation (Apache CXF 2.3.0-
> > > > SNAPSHOT) I ran into the following Problem:
>
> > > > CXF uses @Resource Annotations for Declarative Dependency Injection.
>
> > > > Butjavax.annotation.Resourceis not on the Whitelist.
> > > > Only
>
> > > > javax.annotation.Generated
> > > > javax.annotation.PostConstruct
> > > > javax.annotation.PreDestroy
>
> > > > can be found on
> > > >http://code.google.com/intl/de-DE/appengine/docs/java/jrewhitelist.html
> > > > .
>
> > > > Consequentely I get the StackTrace: java.lang.NoClassDefFoundError:
> > > >javax.annotation.Resourceis a restricted class. Please see the
> > > > Google  App Engine developer's guide for more details.
>
> > > > Well - I did not find a clear explanation what is wrong with @Resource
> > > > and why it is excluded from the Whitelist.
>
> > > > There is also an issue
> > > >http://code.google.com/p/googleappengine/issues/detail?id=2564
> > > > on this topic. But without any comment.
>
> > > > Maybe there is a simple explanation / workaround to this situation and
> > > > some kind soul could respond?
>
> > > > Best Regards
> > > > Ralf
>
> > > > --
>
> > > > You received this message because you are subscribed to the Google 
> > > > Groups
> > > > "Google App Engine for Java" group.
> > > > To post to this group, send email to
> > > > google-appengine-j...@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > google-appengine-java+unsubscr...@googlegroups.com > > >  ­unsubscr...@googlegroups.com>
> > > > .
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/google-appengine-java?hl=en.-Hide quoted 
> > > >text -
>
> > - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] Re: javax.annotation.Resource Spring 3.0.0.Release declarative DI on Google App Engine

2010-02-10 Thread Larry Cable
Not sure if this  helps or not but you cannot use the Spring



markup in your GAE Spring applications ...

This will of course work locally but because the
CommonAnnotationBeanPostProcessor attempts to load
javax.annotation.Resource (and fails) then no annotation processing
will occur ...

there are 2 workarounds to this:

1) use the init-method="..." attribute of the  element

or ...

2) directly load the appropriate annotation processing beans like so:











This avoids the attempt to load the @Resource class ...



On Jan 22, 2:21 am, Vijay Bansal  wrote:
> This is of some help to those who are trying for CXF-RS apps on 
> GAEhttp://sinister2010.wordpress.com/2010/01/22/cxf-rs-on-google-app-eng...
>
> On Jan 14, 12:43 am, "Jason (Google)"  wrote:
>
>
>
> > Hi Ralf. We may be able to add support for this annotation in a forthcoming
> > release. Please star the issue in your post if you want to be notified of
> > any status changes.
>
> > - Jason
>
> > On Sat, Jan 2, 2010 at 3:27 AM, Ralf Sigmund  wrote:
> > > Hi,
> > > i am a newbie to App Engine. So I tried to do some of my Spring
> > > 3.0.0.RELEASE demo stuff.
>
> > > When using my favourite JAX-RS Implementation (Apache CXF 2.3.0-
> > > SNAPSHOT) I ran into the following Problem:
>
> > > CXF uses @Resource Annotations for Declarative Dependency Injection.
>
> > > But javax.annotation.Resource is not on the Whitelist.
> > > Only
>
> > > javax.annotation.Generated
> > > javax.annotation.PostConstruct
> > > javax.annotation.PreDestroy
>
> > > can be found on
> > >http://code.google.com/intl/de-DE/appengine/docs/java/jrewhitelist.html
> > > .
>
> > > Consequentely I get the StackTrace: java.lang.NoClassDefFoundError:
> > > javax.annotation.Resource is a restricted class. Please see the
> > > Google  App Engine developer's guide for more details.
>
> > > Well - I did not find a clear explanation what is wrong with @Resource
> > > and why it is excluded from the Whitelist.
>
> > > There is also an issue
> > >http://code.google.com/p/googleappengine/issues/detail?id=2564
> > > on this topic. But without any comment.
>
> > > Maybe there is a simple explanation / workaround to this situation and
> > > some kind soul could respond?
>
> > > Best Regards
> > > Ralf
>
> > > --
>
> > > You received this message because you are subscribed to the Google Groups
> > > "Google App Engine for Java" group.
> > > To post to this group, send email to
> > > google-appengine-j...@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > google-appengine-java+unsubscr...@googlegroups.com
> > > .
> > > For more options, visit this group at
> > >http://groups.google.com/group/google-appengine-java?hl=en.- Hide quoted 
> > >text -
>
> - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] Re: javax.annotation.Resource Spring 3.0.0.Release declarative DI on Google App Engine

2010-01-22 Thread Vijay Bansal
This is of some help to those who are trying for CXF-RS apps on GAE
http://sinister2010.wordpress.com/2010/01/22/cxf-rs-on-google-app-engine-exposed3/

On Jan 14, 12:43 am, "Jason (Google)"  wrote:
> Hi Ralf. We may be able to add support for this annotation in a forthcoming
> release. Please star the issue in your post if you want to be notified of
> any status changes.
>
> - Jason
>
> On Sat, Jan 2, 2010 at 3:27 AM, Ralf Sigmund  wrote:
> > Hi,
> > i am a newbie to App Engine. So I tried to do some of my Spring
> > 3.0.0.RELEASE demo stuff.
>
> > When using my favourite JAX-RS Implementation (Apache CXF 2.3.0-
> > SNAPSHOT) I ran into the following Problem:
>
> > CXF uses @Resource Annotations for Declarative Dependency Injection.
>
> > But javax.annotation.Resource is not on the Whitelist.
> > Only
>
> > javax.annotation.Generated
> > javax.annotation.PostConstruct
> > javax.annotation.PreDestroy
>
> > can be found on
> >http://code.google.com/intl/de-DE/appengine/docs/java/jrewhitelist.html
> > .
>
> > Consequentely I get the StackTrace: java.lang.NoClassDefFoundError:
> > javax.annotation.Resource is a restricted class. Please see the
> > Google  App Engine developer's guide for more details.
>
> > Well - I did not find a clear explanation what is wrong with @Resource
> > and why it is excluded from the Whitelist.
>
> > There is also an issue
> >http://code.google.com/p/googleappengine/issues/detail?id=2564
> > on this topic. But without any comment.
>
> > Maybe there is a simple explanation / workaround to this situation and
> > some kind soul could respond?
>
> > Best Regards
> > Ralf
>
> > --
>
> > You received this message because you are subscribed to the Google Groups
> > "Google App Engine for Java" group.
> > To post to this group, send email to
> > google-appengine-j...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-appengine-java+unsubscr...@googlegroups.com
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/google-appengine-java?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.



[appengine-java] Re: javax.annotation.Resource Spring 3.0.0.Release declarative DI on Google App Engine

2010-01-12 Thread Marcel Overdijk
Just read your post carefully now and notices that some parts of
JSR-250 are supported.

I'm wondering now the same why @Resource is not supported. Maybe GAE
team can shed some light on this.


Cheers,
Marcel

On 2 jan, 12:27, Ralf Sigmund  wrote:
> Hi,
> i am a newbie to App Engine. So I tried to do some of my Spring
> 3.0.0.RELEASE demo stuff.
>
> When using my favourite JAX-RS Implementation (Apache CXF 2.3.0-
> SNAPSHOT) I ran into the following Problem:
>
> CXF uses @Resource Annotations for Declarative Dependency Injection.
>
> But javax.annotation.Resource is not on the Whitelist.
> Only
>
> javax.annotation.Generated
> javax.annotation.PostConstruct
> javax.annotation.PreDestroy
>
> can be found 
> onhttp://code.google.com/intl/de-DE/appengine/docs/java/jrewhitelist.html
> .
>
> Consequentely I get the StackTrace: java.lang.NoClassDefFoundError:
> javax.annotation.Resource is a restricted class. Please see the
> Google  App Engine developer's guide for more details.
>
> Well - I did not find a clear explanation what is wrong with @Resource
> and why it is excluded from the Whitelist.
>
> There is also an 
> issuehttp://code.google.com/p/googleappengine/issues/detail?id=2564
> on this topic. But without any comment.
>
> Maybe there is a simple explanation / workaround to this situation and
> some kind soul could respond?
>
> Best Regards
> Ralf
-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.




[appengine-java] Re: javax.annotation.Resource Spring 3.0.0.Release declarative DI on Google App Engine

2010-01-12 Thread Marcel Overdijk
Encountering the same...
Would be cool if GAE would support JSR-250 which it obviously does
not.

On 2 jan, 12:27, Ralf Sigmund  wrote:
> Hi,
> i am a newbie to App Engine. So I tried to do some of my Spring
> 3.0.0.RELEASE demo stuff.
>
> When using my favourite JAX-RS Implementation (Apache CXF 2.3.0-
> SNAPSHOT) I ran into the following Problem:
>
> CXF uses @ResourceAnnotations for Declarative Dependency Injection.
>
> But javax.annotation.Resourceis not on the Whitelist.
> Only
>
> javax.annotation.Generated
> javax.annotation.PostConstruct
> javax.annotation.PreDestroy
>
> can be found 
> onhttp://code.google.com/intl/de-DE/appengine/docs/java/jrewhitelist.html
> .
>
> Consequentely I get the StackTrace: java.lang.NoClassDefFoundError:
> javax.annotation.Resourceis a restricted class. Please see the
> Google  App Engine developer's guide for more details.
>
> Well - I did not find a clear explanation what is wrong with @Resource
> and why it is excluded from the Whitelist.
>
> There is also an 
> issuehttp://code.google.com/p/googleappengine/issues/detail?id=2564
> on this topic. But without any comment.
>
> Maybe there is a simple explanation / workaround to this situation and
> some kind soul could respond?
>
> Best Regards
> Ralf
-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.