Disabling Persistence Conversation Feature

View: New views
4 Messages — Rating Filter:   Alert me  

Disabling Persistence Conversation Feature

by Martin de la Rosa :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.

Hi!

 

I’m trying to use MyFaces Orchestra for adding conversation scope to the MBeans of an already developed application.

 

I’m asking if there there exists an elegant way to disable the persistence conversation feature of Orchestra framework? I only need the conversation scopes (access/manual) feature and I don’t want to change the Persistence Mechanism of the application.

 

I tried deleting the part regardless to persistence from spring configuration (application-context.xml) but no success. I encountered exceptions thrown by the Orchestra Conversation Interceptor.

 

Thanks in advance!

 

Martin de la Rosa -.

www.southward-solutions.com.ar

 


Re: [Orchestra] Disabling Persistence Conversation Feature

by Mario Ivankovits :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Hi!

I tried deleting the part regardless to persistence from spring configuration (application-context.xml) but no success. I encountered exceptions thrown by the Orchestra Conversation Interceptor.

Not configuring the persistence related advice (e.g the persistentContextConversationInterceptor) with the scope should be sufficient.

What exceptions do you encounter?

Ciao,
Mario

Re: [Orchestra] Disabling Persistence Conversation Feature

by simon.kitching@chello.at :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Mario Ivankovits schrieb:

> Hi!
>>
>> I tried deleting the part regardless to persistence from spring
>> configuration (application-context.xml) but no success. I encountered
>> exceptions thrown by the Orchestra Conversation Interceptor.
>>
> Not configuring the persistence related advice (e.g the
> persistentContextConversationInterceptor) with the scope should be
> sufficient.
> section.
> What exceptions do you encounter?

For conversations *with* persistence support, you'll have something like
this in the spring config file:

  <entry key="conversation.manual">
    <bean class="org.apache.myfaces.orchestra.conversation.spring.SpringConversationScope">
      <property name="timeout" value="30" />
      <property name="advices">
        <list>
          <ref bean="persistentContextConversationInterceptor"/>
        </list>
      </property>
    </bean>
  </entry>

If you don't need persistence, just leave out the "advices" property. It
is the persistenceContextConversationInterceptor that does all the work
of binding a PersistenceContext to a conversation instance.

And in future, please ask questions on the user list. It's better for
*you* because there are lots of very competent people who subscribe to
the users list but not the dev list. And all developers subscribe to both.

Regards,
Simon


RE: [Orchestra] Disabling Persistence Conversation Feature

by Martin de la Rosa :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks! This solved my problem. It's working great now.

Sorry for writing on this list, I will post my future comments on users
list.

Regards,
Martin de la Rosa-.

-----Original Message-----
From: simon.kitching@... [mailto:simon.kitching@...]
Sent: Martes, 06 de Mayo de 2008 04:42 a.m.
To: MyFaces Development
Subject: Re: [Orchestra] Disabling Persistence Conversation Feature

Mario Ivankovits schrieb:

> Hi!
>>
>> I tried deleting the part regardless to persistence from spring
>> configuration (application-context.xml) but no success. I encountered
>> exceptions thrown by the Orchestra Conversation Interceptor.
>>
> Not configuring the persistence related advice (e.g the
> persistentContextConversationInterceptor) with the scope should be
> sufficient.
> section.
> What exceptions do you encounter?

For conversations *with* persistence support, you'll have something like
this in the spring config file:

  <entry key="conversation.manual">
    <bean
class="org.apache.myfaces.orchestra.conversation.spring.SpringConversationSc
ope">
      <property name="timeout" value="30" />
      <property name="advices">
        <list>
          <ref bean="persistentContextConversationInterceptor"/>
        </list>
      </property>
    </bean>
  </entry>

If you don't need persistence, just leave out the "advices" property. It
is the persistenceContextConversationInterceptor that does all the work
of binding a PersistenceContext to a conversation instance.

And in future, please ask questions on the user list. It's better for
*you* because there are lots of very competent people who subscribe to
the users list but not the dev list. And all developers subscribe to both.

Regards,
Simon