Skip to Content
avatar image
Former Member

Creating a datasource

Hi,

I am trying to create a datasource for my application.

I want the isolation level to be TRANSACTION_SERIALIZABLE in the connection. But if I set the connection to TRANSACTION_SERIALIZABLE it gives me a illegalArgument exception. If I set it to default it works any idea why ?

I am using the WAS 6.30 on windows.

thanks a lot

Padmaja Ragavendra

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • Feb 16, 2004 at 12:39 PM

    Hi Padmaja,

    this depends on how you do this and what you are using. If your program uses Open SQL, then this is surely expected to be part of the descriptors, which may collide with your program.

    If you are more specific, I may be able to tell you more.

    Regards,

    Benny

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Benny,

      Here is what I tried.

      Added an alias to the default datasource.

      In my example now am looking up this alias for the default datasource.

      When I see the default datasource's monitor I can see the connections being established.

      This was with the sysDS.isolation property not set to anything.

      Then I set the sysDS.isolation TRANSACTION_SERIALIZABLE.

      Now my example is not working and gives a ResourceException.

      Also in the Enterprise assembly I cannot add the dbpool alias connection as that feature is not available.

      Do you know what the value for the sysDS.isolation should be set to?

      thanks a lot for your help

      Padmaja

  • avatar image
    Former Member
    Feb 23, 2004 at 10:43 AM

    Hi Padmaja,

    why do you need the TX_SERIALIZABLe isolation?

    The right way with the Open SQL datasource is to

    stay at the default isolation level - and it is the lowest one: READ_UNCOMMITED - and to lock database data on the server side using the Enqueue Server.

    Remember, in general, the whole application uses the same isolation level.

    Last but not least: you should not change the settings of the default data source.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Katarzyna,

      I am using bean managed persistence and I could not find documentation on how to use the logical locks from the enqueue server.

      Most of the documents talk about container managed peristence and logical locks.

      I need the isolation level to be Transaction serializable.

      or atleast reapatable read.

      The ejb-j2ee-engine.xml file has isolation levels for container managed beans.

      How do I set these for bean managed beans?

      How do I set the enqueue server isolation level to repeattable read as I understand it does not support transaction serializable

      Thanks a lot for your help.

      Please do let me know if you have more info on enqueue server.

      thanks

      Padmaja

  • avatar image
    Former Member
    Feb 23, 2004 at 03:09 PM

    Hi Padmaja,

    please have a look at the documentation, Development Manual/Java Persistence/Locks.

    Also have a look at the docu about the package

    com.sap.engine.services.applocking

    contained in the Documentation manual 'API reference'

    and let us know if the information is not sufficient.

    Again, you should stay at the default isolation level of open sql and acquire locks.

    With bmp entity beans, the container does not interact between the bean and the database at all. There is no difference if you use BMP entity beans and if you send JDBC/SQLJ directly from the session bean. That's why there is no possibility to set something database related, for example about the isolation level, for BMP entity beans (there is no difference if you use BMP entity beans and if you send JDBC/SQLJ directly from the session bean)

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi

      Sorry was working on a different assignment and now am back on this.

      I am looking at the info you suggested will try that out and see.

      thanks a lot

      Padmaja