You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by cilquirm <aa...@gmail.com> on 2007/02/27 21:04:45 UTC

Re: [S2] Problems using spring plugin and struts 2.0.6

I'm not sure type converters are instantiated via the ObjectFactory
mechanism, but you can just as easily say :

domain.security.PermissionType = presentation.converter.EnumTypeConverter

You will probably need to refactor some code if your EnumTypeConverter
expects to be in a Spring context.



João Vieira da Luz wrote:
> 
> Well we've made progresses. The problem is on registering converters
> on XWorkConverter.
> 
> We are trying to register converters using spring.
> 
> On application-context.xml we have this,
> 
> <bean id="enumTypeConverter"
> class="presentation.converter.EnumTypeConverter" />
> 
> and on xwork-conversion.properties,
> 
> domain.security.PermissionType = enumTypeConverter
> 
> Probably is a problem from our xwork configuration, but we can't
> figure out what is wrong?
> 
> How can I tell xwork that it must use a "SpringClassLoader"?
> 
> Thanks again,
> Joao
> 
> PS: The stacktrace is pretty much what I've send you.
> 
> On 2/27/07, cilquirm <aa...@gmail.com> wrote:
>>
>> Technically, this isn't necessary when you have the
>> struts-spring-plugin.jar
>> in your WEB-INF/lib
>> since it's already specified by the struts-plugin.xml file
>>
>> I think, however, seeing a more complete stack trace for the CNFE would
>> be
>> helpful since I have 2.0.6 with the spring plugin just fine.
>>
>>
>>
>>
>> Paul Saumets | Merge wrote:
>> >
>> > Perhaps obvious question but,
>> >
>> > Do you have
>> >
>> > <constant name="struts.objectFactory" value="spring" />
>> >
>> > set inside your struts.xml?
>> >
>> > -----Original Message-----
>> > From: João Vieira da Luz [mailto:joao.luz@gmail.com]
>> > Sent: Tuesday, February 27, 2007 12:42 PM
>> > To: user@struts.apache.org
>> > Subject: Problems using spring plugin and struts 2.0.6
>> >
>> > We've upgraded to struts 2.0.6 and we can't make spring-plugin work.
>> >
>> > The spring factory isn't being called and we are getting
>> > ClassNotFoundException for the beans that reference spring.
>> >
>> > This is working with struts 2.0.1.
>> >
>> > What changed?
>> >
>> > Thanks a lot,
>> >
>> >        João
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> > For additional commands, e-mail: user-help@struts.apache.org
>> >
>> >
>> >
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> > For additional commands, e-mail: user-help@struts.apache.org
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Problems-using-spring-plugin-and-struts-2.0.6-tf3302939.html#a9188385
>> Sent from the Struts - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
>> For additional commands, e-mail: user-help@struts.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Problems-using-spring-plugin-and-struts-2.0.6-tf3302939.html#a9190615
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: [S2] Problems using spring plugin and struts 2.0.6

Posted by João Vieira da Luz <jo...@gmail.com>.
Ok, that's a solution. We were trying to avoid to do that...

Hope somebody could help us on this.

Thanks again,
João




On 2/27/07, cilquirm <aa...@gmail.com> wrote:
>
> I'm not sure type converters are instantiated via the ObjectFactory
> mechanism, but you can just as easily say :
>
> domain.security.PermissionType = presentation.converter.EnumTypeConverter
>
> You will probably need to refactor some code if your EnumTypeConverter
> expects to be in a Spring context.
>
>
>
> João Vieira da Luz wrote:
> >
> > Well we've made progresses. The problem is on registering converters
> > on XWorkConverter.
> >
> > We are trying to register converters using spring.
> >
> > On application-context.xml we have this,
> >
> > <bean id="enumTypeConverter"
> > class="presentation.converter.EnumTypeConverter" />
> >
> > and on xwork-conversion.properties,
> >
> > domain.security.PermissionType = enumTypeConverter
> >
> > Probably is a problem from our xwork configuration, but we can't
> > figure out what is wrong?
> >
> > How can I tell xwork that it must use a "SpringClassLoader"?
> >
> > Thanks again,
> > Joao
> >
> > PS: The stacktrace is pretty much what I've send you.
> >
> > On 2/27/07, cilquirm <aa...@gmail.com> wrote:
> >>
> >> Technically, this isn't necessary when you have the
> >> struts-spring-plugin.jar
> >> in your WEB-INF/lib
> >> since it's already specified by the struts-plugin.xml file
> >>
> >> I think, however, seeing a more complete stack trace for the CNFE would
> >> be
> >> helpful since I have 2.0.6 with the spring plugin just fine.
> >>
> >>
> >>
> >>
> >> Paul Saumets | Merge wrote:
> >> >
> >> > Perhaps obvious question but,
> >> >
> >> > Do you have
> >> >
> >> > <constant name="struts.objectFactory" value="spring" />
> >> >
> >> > set inside your struts.xml?
> >> >
> >> > -----Original Message-----
> >> > From: João Vieira da Luz [mailto:joao.luz@gmail.com]
> >> > Sent: Tuesday, February 27, 2007 12:42 PM
> >> > To: user@struts.apache.org
> >> > Subject: Problems using spring plugin and struts 2.0.6
> >> >
> >> > We've upgraded to struts 2.0.6 and we can't make spring-plugin work.
> >> >
> >> > The spring factory isn't being called and we are getting
> >> > ClassNotFoundException for the beans that reference spring.
> >> >
> >> > This is working with struts 2.0.1.
> >> >
> >> > What changed?
> >> >
> >> > Thanks a lot,
> >> >
> >> >        João
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> >> > For additional commands, e-mail: user-help@struts.apache.org
> >> >
> >> >
> >> >
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> >> > For additional commands, e-mail: user-help@struts.apache.org
> >> >
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Problems-using-spring-plugin-and-struts-2.0.6-tf3302939.html#a9188385
> >> Sent from the Struts - User mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> >> For additional commands, e-mail: user-help@struts.apache.org
> >>
> >>
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> > For additional commands, e-mail: user-help@struts.apache.org
> >
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Problems-using-spring-plugin-and-struts-2.0.6-tf3302939.html#a9190615
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org