Rollback after DB polling

Hi all,
I am using DB adapter to poll records from a table(changing a status flag to processed when the records are read) then write these records to a file, all is running fine but I need to handle rollback if any error occurs ,this means that I want the old status in the status flag instead of the current status(processed).
I already used rollback before and it works fine but I can't seem to rollback after polling, any ideas??

Hi,
To implement rollback scenario in BPEL, you need to use compensate activity and compensation Handler in your process.
Basically in compensate we define the scope which we want to compensate, and in compensation Handler we define the logic i.e in your case we will write the update statement in compensation Handler.
Hope I have answered to your doubt.
Cheers,
Abhi...

Similar Messages

  • Import bug (fatal error): SQL Developer 4.1EA2 drops destination table upon rollback after error

    I created a table in the worksheet and then I tried to import data into is using SQL Developer EA2. After error is raised, I was presented with the error on the screenshot below. (Note: Rightmost button stands for "Cancel") By choosing cancel (i.e. Click cancel to cancel and rollback.) my destination table is dropped to recycle bin. Rollback should not undo any DDL even when the table was created using the import wizard. But purging a table that was not created by the import wizard is a fatal error.
    Steps to reproduce:
    create the destination table from worksheet and check if it was created:
    column table_name format a21
    create table test_imp_rollback_bug(dummy number(2));
    insert into test_imp_rollback_bug values (-1);
    commit;
    select table_name from user_tables where table_name='TEST_IMP_ROLLBACK_BUG';
    --Result:
    TABLE_NAME
    TEST_IMP_ROLLBACK_BUG
    import CSV using the import settings attached, To achieve this, utilize the new Restore state of the SQL Developer's import wizard. Note: you might need to adjust schema of the destination table.
    test_imp_rollback_bug_numbers.csv
    test_imp_rollback_bug-import_settings.sdimp
    Upon "Insert failed for rows  1  through  50 " message presented, click Cancel.
    The table does not exists any more:
    select table_name from user_tables where table_name='TEST_IMP_ROLLBACK_BUG';
    --Result:
    no rows selected
    Edit (jmarton, 2015-04-26):
    Software versions used:
    SQL Developer version: 4.1.0.18.37
    Oracle JDK: 1.8.0_31, 64bit, Linux
    Instant client: linux.x64-12.1.0.2.0
    Database: 12cR1 12.1.0.2.0 64bit, Linux, EE, CDB-install

    select table_name from user_tables where table_name='TEST_IMP_ROLLBACK_BUG'; 
    --Result: 
    no rows selected
    >>Note: you might need to adjust schema of the destination table.
    A rollback won't drop a table. Are you sure the tale isn't there? select from dba_tables or all_tables, assuming you had to change the destination schema as indicated in your test notes.

  • OSB turning off server gives problem in internal transport after FTP polling

    Hi,
    We are using OSB with 2 managed servers. When managed server2 is not available we get the following error during the processing of a remote file using the ftp adapter.
    weblogic.jms.extensions.JMSOrderException: hashed member of jmsResources!dist_wlsb.internal.transport.task.queue.ftp_auto is jmsResources!wlsb.internal.transport.task.queue.ftp_auto_2 which is not available
    We have a proxy which polls for FTP files on location x.
    In the proxy configuration, FTP Transport Configuration we set the managed server ("the managed service to run the poller service polling  the external resourcel") to managed server1.
    It appears that after polling the external resource and a file is discovered, the OSB forwards the request via internal transport to managed server2. However this one is disabled/ not available.
    We only disabled the second node (reflected in the server tab on the WLS), Why is it trying to reach managed server2?
    Thanks,
    Stefan

    Even if you indicated server1 as the 'managed_server' that only means the file is picked up by server1, processing is still offloaded onto the other servers in the cluster.
    If I remember correctly we found a setting change fixed this issue for us - we needed to set sort by arrival to false.

  • Photoshop Elements 10 rollback after install

    I have a paid full version of Photoshop Elements/Premier Elements 10 on DVD. My computer runs Windows XP SP3 with current updates. After almost fully completing the installation, the installer will give an error message and roll back the installation. The error message is "The installation process has encountered an error while installing Shared Technologies". The logfile mentions:
    ERROR: DW050:  - Photoshop Camera Raw for Elements 10: Install failed
    I have read most of the forum posts which mention rollback (also for PSE9) and I have tried most of the recommendations, but nothing seems to help, so I would appreciate some advice.
    The installation log file is here: http://dl.dropbox.com/u/14071986/PSE10%20STI%20Installer%2010.0%2001-04-2012.log.gz

    I did some further testing and was finally successfull! The problem was apparently with Adobe AIR.
    Until now I was focused on the 64-bit Camera Raw error messages, but then I read in older posts that these messages are not necessarily fatal. Then I noted that the Adobe Help installation also gave error messages in the logfile, which specifically mentioned the rollback action:
    The csu inventory was not updated for payload {E3794450-8781-11E0-B632-B1904824019B} AdobeHelp 3.5.0.0, value of local var is -1
    Calling the ROLLBACK custom action code for pre-install for payload {E3794450-8781-11E0-B632-B1904824019B} AdobeHelp 3.5.0.0
    I already noted some time before this installation of PSE10/PRE10 that the help Adobe Community Help in my existing installation of PSE9/PRE9 gave error messages after trying to update itself. In addition Adobe AIR which runs Adobe Community Help did not successfully update itself as well. So I decided to tackle this problem first. I was also not able to uninstall Adobe AIR and Adobe Community Help so I used the online Microsoft Fixit to do this and that worked beautifully for both!
    http://http://support.microsoft.com/mats/Program_Install_and_Uninstall/en-us
    I then re-installed the latest version of Adobe AIR and then the Adobe Community Help function. Now the Help worked and it also updated itself again. At this point I ran the PSE10 installer again and now it ran to completion. Note that the error messages about 64-bit code are still there in the logfile, but they apparently were not fatal.
    Finally, I would like to thank all who responded to my initial posting. Although I did find the solution myself, your suggestions helped me to think clearly and kept me motivated to see this debug session through.

  • Session rollback after killing

    Hello,
    I am working on Oracle 11g r2 rac two node on AIX.
    On production database we found out the one user was holding locks on few tables and we killed that user but
    after killing user also it was exist in that database , it was trying to rollback data and until that user will relaese the lock we are not able to
    run job again.
    Other guys are asking us how much time it will take to rollback the data but we are not awere of that .Finally after 20 minutes that user disappared
    and locks got relaesed.
    I want to know how to check if after killing a database user what user is doing and if it is rolling back that data ..how much time it will take to complete it..
    Any idea...

    You can use Audit as Osama said.
    Also you can use V$TRANSACTION to see the status of the rollback.

  • ROLLBACK after failure

    I am calling the following FMs in the sequence:
    1. BAPI_GOODSMVT_CREATE using movement type 261
    2. BAPI_GOODSMVT_CREATE using movement type 101
    3. COMMIT WORK to generate a handling unit number.
    4. A FM L_TO_CREATE_SINGLE (that unpacks and repacks handling units) uses the handling unit number of step 3.
    My requirement is that if the BDC in the 4th step fails, then steps 1, 2 should be be ROLLBACKed.
    To my understanding if I have a ROLLBACK work after step 4, then the COMMIT work in step 3 prevents the ROLLBACK of steps 1 and 2.
    I cannot remove the COMMIT in step 3 as the HU number is not being generated (which I need in step 4) in case I remove the COMMIT WORK.      
    I tried calling the FM in step 4 in UPDATE TASK, but no luck.
    Please help, how to go about this problem.

    You are using commit work before step 4 because you step 4 is dependent on data provided from previous steps.
    My requirement is that if the BDC in the 4th step fails, then steps 1, 2 should be be ROLLBACKed.
    Commit work is the last state of a transaction flow and you cannot rollback the previous step. The only way I see is to call BAPI_GOODSMVT_CANCEL and reverse the goods movement.
    Please let me know what do you mean by logs exactly. Is it the change documents or something else ?
    Kesav

  • Rollback after commit

    hi
    it possible to rollbak after commit
    is how

    This doesn't make sense. After a commit all changes are persisted into three db, so there is nothing to rollback.
    You can do this, but there is no change.
    Timo

  • Rollback after analyze command

    Hi Everyone,
    My DB version is
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bi
    PL/SQL Release 10.2.0.1.0 - Production
    "CORE    10.2.0.1.0    Production"
    TNS for Linux: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    I've inserted 5 rows in a table, but didn't commit the transaction.
    After that I executed following query to update the plan table.
    analyze table <table_name> compute statistics
    Then I query the plan table for the update, it's updated, but after that I rolled back the transaction
    and was hoping that those 5 records will be deleted from that table as I didn't commit the transaction.
    But that didn't happen. So my question is when I was computed the statistics, previous DML statement
    is committed automatically or what happened? Why ROLLBACK is not working for that table?
    Regards,
    BS2012. 

    I tried this in Oracle 11gr2 version and found similar characteristic.
    CREATE TABLE tmp (nm VARCHAR2 (100));
    Table created.
    INSERT INTO tmp
         VALUES ('A');
    1 row created.
    INSERT INTO tmp
         VALUES ('B');
    1 row created.
    INSERT INTO tmp
         VALUES ('C');
    1 row created.
    INSERT INTO tmp
         VALUES ('D');
    1 row created.
    INSERT INTO tmp
         VALUES ('E');
    1 row created.
    ANALYZE TABLE tmp COMPUTE STATISTICS;
    Table analyzed.
    ROLLBACK;
    Rollback complete.
    SELECT COUNT (*) FROM tmp;
    count(*)
    5
    According to documentation:
    COMPUTE STATISTICS instructs Oracle Database to compute exact statistics about the analyzed object and store them in the data dictionary. When you analyze a table, both table and column statistics are collected.
    So Analyze is basically doing a commit into data dictinary in the same session.
    Probably that is the reason why rollback does not work here.
    Its like simple example:
    I inserted 100 rows in a table without commit;
    Created a new table in same session (DDL implicit commit)
    rollback;
    -- that rollback will not have effect on the 100 rows we committed before.
    I guess Gurus will come up with better examples than what I have elucidated.
    Cheers,
    Manik.

  • WLS 5.1 - Tx marked rollback after 30sec.

              In a JMS QueueReceiver class establishes and begins a UserTransaction after which
              there is a sql call that sometimes take > 30 seconds. As a result the follow message
              is received:
              Mon Jun 10 21:37:26 EDT 2002:<I> <TX> Transaction (TxC 214945161, xid = 1023759385810_1,
              timeout = 30, txState = Marked Rollback, root = null) rolled back after 30 sec.
              Is there any way to adjust this timeout period? Also, where is it originating?
              Thanks,
              Dave
              

    For user tx's you can explicitly set the tx timeout using
              javax.transaction.UserTransaction.setTimeout(int)
              Kumar
              Dave wrote:
              > In a JMS QueueReceiver class establishes and begins a UserTransaction after which
              > there is a sql call that sometimes take > 30 seconds. As a result the follow message
              > is received:
              >
              > Mon Jun 10 21:37:26 EDT 2002:<I> <TX> Transaction (TxC 214945161, xid = 1023759385810_1,
              > timeout = 30, txState = Marked Rollback, root = null) rolled back after 30 sec.
              >
              > Is there any way to adjust this timeout period? Also, where is it originating?
              >
              > Thanks,
              > Dave
              

  • Data Committed instead of Rollback after Deadlock Error in SQL Server 2008 R2 (SP2)

    We're having a strange issue which is occurring only with one Customer having SQL Server 2008 R2 (SP2).
    Basically we have multiple threads uploading data and when an error occurs (like deadlock or any other error). The deadlock victim (process/transaction) is rolledback (from .NET). However the rollback command is not reaching SQL Server as it doesn't show
    in the trace (through SQL Profiler).
    To make things worse, not only the transaction is not being rolled back but the INSERTs executed before the error are being somehow committed, leaving the database in an inconsistent state.
    This is only produced in one environment.
    Any idea what the issue could be?

    All statements are executed with in a Transaction. Under the same scenario this code works perfectly fine for 1000s of customers. Only one customer has this issue.
    You need to capture profiler to check transaction scope.
    Balmukund Lakhani
    Please mark solved if I've answered your question, vote for it as helpful to help other users find a solution quicker
    This posting is provided "AS IS" with no warranties, and confers no rights.
    My Blog |
    Team Blog | @Twitter
    | Facebook
    Author: SQL Server 2012 AlwaysOn -
    Paperback, Kindle

  • FTP Send mail when no file after 8 polling

    I want to send mail when the FTP Adapter tried polling for 8 times and no file is there in the directory. How can we acheive this.
    Thanks
    Sebin

    Hi Thomas,
    want to send mail when the FTP Adapter tried polling for 8 times and no file is there in the directory. How can we acheive this.
    >>i think this is not possible with xi without having any file in directory ......xi needs some data otherwise how u will get the error report which u want to send as a mail ............as per my knowledge there must be some file in directory ....for  xi to send back the responce ....empty directory i think it w'nt work ..........correct me if i am wrong .........guys !
    Regards,
    Azeez khan.

  • Rollback after postchanges() in struts / adf bc / jsp project

    I have a wizard that collects info from the user and binds the data as I move through the wizard. On the final screen I have a dataaction that first posts the data to the database and then calls a procedure on the database(the purpose of posting the data is so that the procedure has visibility of the data collected through the screens). So far so good...
    I then call a payment gateway to validate credit card information. If the gateway returns an error code I rollback the database post/ procedure changes(so I don't end up with a double post!) I then allow the user to change their card information and then go back to the final screen again. The problem I have is because of the rollback the data from the screens is no longer bound. To try and solve this I tried a specific rollback on the database by calling a database procedure that does a rollback.
    I was hoping that this would just rollback the post changes / procedure changes without affecting the middle tier?. It doesn't. I now get an error stating that the entity with row key xxx has been deleted. I don't understand how a rollback performed in a procedure on a database can also remove entries from the entities in the middle tier.
    Has anyone got a solution to my problem ???????

    Does the above not make sense, or does no one have a suggestion?
    Any help would be appreciated.
    Many Thanks.

  • Rollback after a commit

    dear all
    I'm working on OWB tool. I have to execute two mapping to load a table. can i have a solution tu rollback the first mapping commit if the second does not successed?
    thank you

    You cannot roll back something that has already been committed. As BluShadow pointed out the best way to commit is at logical points.
    You can use savepoints to do partial rollbacks, but I haven't had good luck with them. When I have experemented with savepoints they work but make my transactions slower when I have done timings.

  • Unit Tester - How to Rollback After Test Runs?

    Nevermind - I figured out my problem.
    Edited by: user453545 on Jan 29, 2010 1:08 PM

    - just so the answer is here if someone else looks at the thread ...
    Common practice is to put the rollback in the tear down for the test.
    Brian Jeffries
    SQL Developer Team

  • Rollback after installation - Photoshop Elements 8

    Posting this query on behalf of a user
    Hello,
    I was hoping you could help me install my Adobe Photoshop Elements 8.0 on my computer.  I have the software DVD but everytime I try to install it it goes all the way to registering product then starts "ROLLING BACK" and I get a message reading: "please try again, the installation was interrupted."   I have been trying to figure out how to do this but am not very computer savvy.
    I am running Windows Vista, and have currently installed on my computer: PSE 5.0 and Lightroom.
    Please help me, if you can.  Thank you!!
    Myra
    [email protected]

    Install logs might help... --> http://helpx.adobe.com/creative-suite/kb/troubleshoot-installation-install-logs-cs3.html (not sure if they are in the same place, but it's always worth a try). When it rolls back, it can't move the files from a temp location to the final location and usually that means shared components version conflicts, requiring to uninstall every bit of Adobe software and then reinstalling in proper order...
    Mylenium

Maybe you are looking for

  • Deploying Adobe Photoshop CS4 Extended over Network - issue

    Hi all, I'm hoping anyone can help me with this issue that has plagued me for a few weeks! First of all, here's the details I have: * Adobe Photoshop CS4 Extended - downloaded media from Adobe website * Creative Suite Deployment Toolkit - again, down

  • Hide filename ext when saving?

    This might be a simple prefrence setting but I can't seem to make it work. In CS5 and I go to "save for web" like I would when I was on CS4. A lot of times I will click on an exsiting file so that file name will auto fill the new save name and then i

  • Costing by Customer

    Hi, Do we have any provision in SAP for doing COSTING based on customer. Any table info which contain COGS information. Regards, Venkat

  • Can't update (can't find) Nokia N8 update "Video"

    Hi A read about "video" update which enables importing subtitles into the movie. But i can't find that update anywhere, on software update offers me only Ovi maps, Theme. Is there any possib. that i can find that update else where?

  • Renamed Domain - Clients Still "joined" to old domain, can't open Group Policy Management on Server

    Performed a Domain Rename as per the following instructions: http://www.bauer-power.net/2011/05/renaming-windows-domain-with-rendom.html#.U4OZRPmSyTM and then after these issues I have gone through the related technet articles starting here: http://t