Markus Fritz wrote:
> 
> Hi,
> 
> i use the latest (18/04/2000) versions of jonas, jonathan(jeremie) out
> of cvs.
> 
> i have problems getting a client tx propagated to the ejb's.
> 
> here is my code (manually compressed):
> 
>     java.util.Properties p = System.getProperties();
>     p.put( javax.naming.Context.INITIAL_CONTEXT_FACTORY,
> 
> "org.objectweb.jeremie.libs.services.registry.jndi.JRMIInitialContextFactory"
> );
>     p.put( javax.naming.Context.PROVIDER_URL,
>            "jrmi://dali.justis.de:12340" );
>     System.setProperties( p );
>     Context ctx = new InitialContext();
>     UserTransaction utx = (UserTransaction)
>       PortableRemoteObject.narrow( ctx.lookup(
> "java:comp/UserTransaction" ),
>                                    UserTransaction.class );
>     utx.begin();
>     // TestEJB: Entity, beanmanaged persistance, tx mandatory
>     TestEJBHome h = ( TestEJBHome ) ictx.lookup( "testpkg.TestEJB" );
>     // In the next line it gets the
>     // javax.transaction.TransactionRequiredException: Mandatory
> attribute = caller must be in a transaction
>     TestEJB e1 = h.create();
>     e1.doSomething();
>     utx.rollback();
> 
> is it possible that jeremie doesn't propagate tx ?
> 
> I have this problem with other bean methods as well
> (when tx-attrib supported and this method checks
>  org.objectweb.jonas.jtm.Current.getTransaction() ).
> 
> Any comments, tips, ... ?
> 
> thanks in advance,
> 
>         markus
> 
> --
> Dipl.-Ing. (FH) Markus Fritz             [EMAIL PROTECTED]
> Just Innovative Software GmbH * Kranstrasse 8 * 70499 Stuttgart

Hello Markus,
In order to reproduce your problem
I have made the following test with JOnAS2.0 over jeremie:

I have modified the ejb-jar.xml of the examples/src/eb like this:
<container-transaction>
      <method>
        <ejb-name>AccountExpl</ejb-name>
        <method-name>findAllAccounts</method-name>
      </method>
      <trans-attribute>Mandatory</trans-attribute>ps</trans-attribute>
    </container-transaction>
    <container-transaction>
      <method>
        <ejb-name>AccountExpl</ejb-name>
        <method-name>*</method-name>
      </method>
      <trans-attribute>Required</trans-attribute>
    </container-transaction>

and I have run successfully the client : java eb.ClientAccount
AccountExplHome

this test show that the transactional context is well propagated with
Jeremie.

Can you please try this in order to verify that your environment is
correct?

thanks,
regards

-- 
        Philippe

Philippe Coq  Groupe Bulll/BullSoft/OpenMaster  Phone: (33) 04 76 29 78
49
Bull S.A  - 1 rue de Provence - 38432 Echirolles Cedex France
[EMAIL PROTECTED]  http://www-frec.bull.com
Download our EJBServer at http://www.bullsoft.com/ejb

Reply via email to