Why does TopLink roll back transactions without displaying any error?

I am trying to do bulk inserts via a stored procedure that takes in a VARRAY of varchars (complete insert statements). Becuase of integrity constraint, the stored procedure can only be executed after the parent record has been inserted via registerObject. I have created a new class that implements the SessionEventListener and put the logic to call the stored procedure under prepareUnitOfWork. I then put the listener in the event manager. The whole transaction would go through, but in the end TopLink would rollback the transaction for no apparent reason. I do not see any exceptions or errors, and from the database side my DBA has created a test_log table that will track the statements I passed in, and they all look fine. Has anyone encountered similar problems before?

This is the current setting for Session.xml
<logging-options>
<log-debug>true</log-debug>
<log-exceptions>true</log-exceptions>
<log-exception-stacktrace>true</log-exception-stacktrace>
<print-thread>true</print-thread>
<print-session>true</print-session>
<print-connection>true</print-connection>
<print-date>true</print-date>
</logging-options>

Similar Messages

  • Statement in Transaction Does Not Roll Back

    I have a group of MySQL statements in a method of a Java application.
    I include an SQL error in the last statement to test the rollback of the transaction.
    All the statements roll back, EXCEPT for the one detailed below.
    The MySQL table:
         CREATE TABLE Counter (
              number INT( 4 ) NOT NULL DEFAULT 0,
              account_id VARCHAR( 12 ) NOT NULL PRIMARY KEY
         ) ENGINE = InnoDB;I have run the staement as a PreparedStatement and a Statement:
    PreparedStatement:
         String updateCounterStr =
              " UPDATE Counter " +
                   " SET number = number + 1 " +
                   " WHERE account_id = ? "
         updateCounter = con.prepareStatement ( updateCounterStr );
              updateCounter.setString( 1, accountID );
              int uc = updateCounter.executeUpdate();     Statement:               
         Statement updateCounterStatement = con.createStatement();
              int updatecounter = updateCounterStatement.executeUpdate(
                   "UPDATE Counter SET number = number + 1 " +
                   "WHERE account_id = \'" + accountID + "\'"
              con.setAutoCommit( true );     //     ------------------------------------ Transaction ENDS
              updateCounterStatement.close();
    //               updateCounter.close();
              ... several more
              con.close();
         } catch(SQLException ex) {
              System.err.println("SQLException: " + ex.getMessage());
              if (con != null) {
                   try {
                        System.err.print("Transaction is being ");
                        System.err.println("rolled back");
                        con.rollback();     //     < ------------------------------------ con.rollback() HERE
                   } catch(SQLException excep) {
                        System.err.print("SQLException: ");
                        System.err.println(excep.getMessage());
    }     //     ---------------------------------------- END the methodIn both cases Counter is incremented, but does NOT roll back.
    The other statements in the transaction do roll back,
    I am using:
    mysql Ver 14.12 Distrib 5.0.18, for apple-darwin8.2.0 (powerpc) using readline 5.0
    on Mac OS X 10.4.x
    I would greatly appreciate a solution to this problem.
    Many thanks in advance

    I think autocommit is true by default. Also, it looks like your'e setting it to true, and then executing more SQL.
    Explicitly set it to false, and DON'T set it back to trueif there's any chance you're going to want to rollback after that.

  • RuntimeException in OnMessage() does not roll back

              Hello All, I have a transacted queue, the consumer is a java application. I configured
              an error queue for that queue. If I rollback manually in OnMessage(), the rolled
              back messages go into the error queue. However, if I have a RuntimeException,
              the last message (which has caused the exception) remains in the main queue pending
              and does not go into the error queue. I thought a RuntimeException causes a rollback().
              I use WLS 8.1. Any idea?
              Zoltan
              

    Hi Zoltan,
              A runtime causes a rollback in an MDB, per the J2EE
              spec, but a runtime exception does NOT cause a rollback
              on a regular async client. The JMS specification is ambiguous
              on the latter - thus the difference.
              Instead, the message is
              redelivered once, and then, if it fails again,
              the message is no longer delivered
              and is implicitly committed on the next call
              to session.commit(). In your
              case, I highly recommend explicitly forcing the rollback.
              Tom
              Zoltan Pinter wrote:
              > Hello All, I have a transacted queue, the consumer is a java application. I configured
              > an error queue for that queue. If I rollback manually in OnMessage(), the rolled
              > back messages go into the error queue. However, if I have a RuntimeException,
              > the last message (which has caused the exception) remains in the main queue pending
              > and does not go into the error queue. I thought a RuntimeException causes a rollback().
              > I use WLS 8.1. Any idea?
              >
              > Zoltan
              

  • Why does camera roll take up all my storage data and how do i get it free for space

    why does camera roll take up all my storage data and how do i get it free for space

    You might be able to re-enable it via this page : http://appleid.apple.com, then 'reset your password'
    You might then need to log out of your account on any iOS devices that you have  by tapping on your id in Settings > iTunes & App Store (Settings > Store on iOS 5 and below) and then log back in so as to 'refresh' the account on them
    If that doesn't fix it then you might need to contact iTunes Support : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page

  • Why does apple disable my account without reason?

    Why does apple disable my account without reason?

    Then, USA is not a country which has freedom.
    There is no such thing in the world as absolute freedom. That's anarchy. All civilized societies have rules to govern our actions. Like it or not, a current rule is that no company based in the U.S. is allowed to sell any type of technology to Iran.
    Here is a text version of the U.S. Government's sanction. Note this particular paragraph:
    • EXPORTS TO IRAN - In general, unless licensed by OFAC, goods, technology, or
    services may not be exported, reexported, sold or supplied, directly or
    indirectly, from the United States or by a U.S. person, wherever located, to
    Iran or the Government of Iran. The ban on providing services includes any
    brokering function from the United States or by U.S. persons, wherever located.
    For example, a U.S. person, wherever located, or any person acting within the
    United States, may not broker offshore transactions that benefit Iran or the
    Government of Iran, including sales of foreign goods or arranging for
    third-country financing or guarantees.
    The U.S. can't do anything about you buying an Android if you want one. The maker of that product is located in Taiwan.

  • Why does Mail go back online when I've set it to offline and put computer to sleep (Power Nap NOT enabled)

    Why does Mail go back online when I've set it to offline and put computer to sleep (Power Nap NOT enabled)

    for me this issue is only new powerbook w retina display on 10.8. do not have issue on Lion, imac, ibook or old powerbook 17.

  • Why does Safari 5.1.7 not display pdf files anymore?

    Why does Safari 5.1.7 not display pdf files anymore? Please fix!

    I have this problem too except I see the pdf but it does not print.

  • Why does camera roll show last photo taken even though it was trashed ?

    Why does camera roll show last photo taken even though it was sent to trash ?

    http://support.apple.com/kb/HT4486

  • Why does safari suddenly zoom in without me touching anything?

    why does safari suddenly zoom in without me touching anything?

    Have you checked, if any accessibility settings have been enabled? Switch control, sticky keys?
    Have a look at the System Preferences > Accessibility.

  • HT5262 why does my icloud back up take several hours

    why does my icloud back up take several hours>

    you could always try turning the phone off and starting the backup over again. If it's still happening, it's possible that it's related to the network you're in

  • Why cant i complete iTunes transactions without receiving error messages etc.?

    Why cant i complete iTunes transactions without receiving error messages etc.?

    We are fellow users here on these forums, we won't know unless you tell us what the error messages etc are.
    If you are getting a message to contact iTunes Support then you can do so via this link and ask them why the message is appearing (we won't know why) : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Purchases, Billing & Redemption
    If it's a different error message ... ?

  • Why does my facetime say "The server encountered an error prossessing registration"? it happens everytime i try to verify my email

    why does my facetime say "The server encountered an error prossessing registration"? it happens everytime i try to verify my email.

    While we all have MacBooks in this forum not all of us use FaceTime. There's a FaceTime Support Community where everybody uses FaceTime. You should also post this question there to increase your chances of getting an answer. https://discussions.apple.com/community/mac_app_store/facetime_for_mac

  • Report Builder get shut down... without generating any Error Message

    Hi Every One,
    I am generating the reports in Report Builder 10.1.2.0.2. And the report is based on the view, when I want to generate the PDF, the report builder get shut down without generating any error message. But I can run the report to see live Preview (Paper Design ).
    What can be reason that its not generating PDF file format.
    Thanks in Advance for your time.

    Hi Saumen,
    I don't think so that .. I have memory problem or some other issue on the hardware side .. bcos I used the same report builder on same machine against the same instance.. to generate the 70K pages PDF file ... but nothing happened ...And this report is fetching only 10 records. during the execution of the report, Report Builder get close. without generating any message. without keeping any processor busy.
    I am feeling that report builder try to write in the PDF file format .. but unable to write.. may b some thing is wrong on the privileges side of the VIEW. But I have Select Priv on the view.
    When I try to trace the report, I got the message in the trace file that " Report Aborted on user request"
    Thanks,
    Mohsin

  • Installation of weblogic 6.1 suuenly aborts without giving any error

    Hi
    i am trying to install weblogic server 6.1 in the following configured machine:-500 Mhz
    256 MB RAM 40 GB harddisk with WIN NT workstation as the operating system.The installation aborts without giving any error ?? please help..it extracts 100% and then aborts installation without any error
    rishi

    Hi.
    Pls search the archives of this newsgroup. This has been reported several times and a few solutions have been found and posted here.
    Thanks,
    Michael
    rishi wrote:
    Hi
    i am trying to install weblogic server 6.1 in the following configured machine:-500 Mhz
    256 MB RAM 40 GB harddisk with WIN NT workstation as the operating system.The installation aborts without giving any error ?? please help..it extracts 100% and then aborts installation without any error
    rishi--
    Michael Young
    Developer Relations Engineer
    BEA Support

  • HT1386 Why does my new iphone sync without transferring calendar item from iphone to computer?

    Why does my new Iphone 4S sync without transferring calendar entry from phone to desktop using outlook?

    Do you have Sync Calendars with Outlook selected under the Info tab for your iPhone sync preferences with iTunes?
    http://support.apple.com/kb/HT1692
    http://support.apple.com/kb/TS2776

Maybe you are looking for

  • Problem in importing SAP Exchange profile (BASIS settings) - Urgent

    Hi, I am currently facing problem in importing SAP Exchange profiles manually. When i enter into http://<J2EE_host>:<J2EE_port>/exchangeProfile with username as PISUPER, the page is getting loaded but <b>1.</b>it shows a error message stating, Name o

  • Bit Shifting Help

    Hi, I'm not too familiar with bit shifting. If anyone can help with this problem, it would be great! We have words that are 32 bits. So, basically, the lower 8 bits should have value �1� and the upper 24 bits should have value �X�. For our example, l

  • Boot Camp and Vista SP1

    Hi. I have a Macbook Pro running Leopard and Vista. Is it safe to install Vista SP1 in Boot Camp 2.0? I haven't heard of too many issues, but just making sure it wasn't going to break anything. Thanks.

  • HP LP3065 - problems selecting input

    Dear people, Quite some time ago I purchased the LP3065 monitor, it has always worked perfectly well. Until recently II had only one PV with DVI output. No matter which of the inputs on the monitor I connected the cable to, it worked perfectly well.

  • SOA Design issues and other politics

    Hi all, I have a requirement for live data feed from external system. I am using SOA11g and JDeveloper 11g. There are two designs, one proposed and other I have in mind to achieve this. 1) The external system sends XML data in a push model to the exp