Catch a ejbtimer TimedOutException

Hello,
I am writing a EJB Timer (CMP) and setting timeout-running into weblogic-ejb.xml with:
<transaction-descriptor>
<trans-timeout-seconds>3</trans-timeout-seconds>
</transaction-descriptor>
Ok, the timeout is exected ok, because, at time from 4 seconds i got the following exception:
<22-abr-2010 11H05' CEST> <Error> <EJB> <BEA-011088> <The following error occurred while invoking the ejbTimeout(javax.ejb.Timer) method of EJB 'timedBean(Application: EJB3ServletEAR, EJBComponent: EJB4.jar)'.
javax.ejb.EJBException: Transaction Rolledback.: weblogic.transaction.internal.TimedOutException: Transaction timed out after 3 seconds
<...>
     at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
; nested exception is: weblogic.transaction.internal.TimedOutException: Transaction timed out after 3 seconds
BEA1-002BD50F519FBD76B51F
     at weblogic.ejb.container.internal.EJBRuntimeUtils.throwEJBException(EJBRuntimeUtils.java:147)
<...>
     at weblogic.ejb.container.timer.TimerImpl.timerExpired(TimerImpl.java:403)
     Truncated. see log file for complete stacktrace
>
Very good, but ... how can i catch it ? declarative way to do this? or ... how can i hide it ?
because, this is a "error" message, and it is not ... the running is ok ... thread, your time is out .. and nobody care ...
thank you

Hello,
I am writing a EJB Timer (CMP) and setting timeout-running into weblogic-ejb.xml with:
<transaction-descriptor>
<trans-timeout-seconds>3</trans-timeout-seconds>
</transaction-descriptor>
Ok, the timeout is exected ok, because, at time from 4 seconds i got the following exception:
<22-abr-2010 11H05' CEST> <Error> <EJB> <BEA-011088> <The following error occurred while invoking the ejbTimeout(javax.ejb.Timer) method of EJB 'timedBean(Application: EJB3ServletEAR, EJBComponent: EJB4.jar)'.
javax.ejb.EJBException: Transaction Rolledback.: weblogic.transaction.internal.TimedOutException: Transaction timed out after 3 seconds
<...>
     at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
; nested exception is: weblogic.transaction.internal.TimedOutException: Transaction timed out after 3 seconds
BEA1-002BD50F519FBD76B51F
     at weblogic.ejb.container.internal.EJBRuntimeUtils.throwEJBException(EJBRuntimeUtils.java:147)
<...>
     at weblogic.ejb.container.timer.TimerImpl.timerExpired(TimerImpl.java:403)
     Truncated. see log file for complete stacktrace
>
Very good, but ... how can i catch it ? declarative way to do this? or ... how can i hide it ?
because, this is a "error" message, and it is not ... the running is ok ... thread, your time is out .. and nobody care ...
thank you

Similar Messages

  • Handling a Weblogic TimedOutException

    Hi all,
    I am working on a very large Swing application that uses mostly stateless session EJB's with Weblogic 8.1. My problem is this: there are some places in the app where queries are timing out. I know that the relevant property is trans-timeout-seconds in weblogic-ejb-jar.xml and that is not the issue. The users are requesting however that when a query times out, they see an info message telling them to narrow their search parameters instead of an error with "10 pages of Java gibberish". I have a class that is a query processor class that handles most of the query calls to the session EJB's. How can I determine in that class that the timeout exception occurred and respond accordingly? The base cause of my exception looks like this when I get a timeout:
    java.sql.SQLException: The transaction is no longer active - status: 'Marked rollback. [Reason=weblogic.transaction.internal.TimedOutException: Transaction timed out after ...
    How can I catch the unadorned TimedOutException with a someObject.getReason() call or some such? The only way that I can think of to do it is to parse the string to find the "...TimedOutException...", but there's got to be a better way.
    Thanks in advance.

    I have exactly this same issue,and as of yet, have not been able to find a distinguishing characteristic of a WebLogic weblogic.transaction.internal.TimedOutException when it is wrapped by an SQLException.
    To restate the issue, when a transaction times out in a DAO, a generic SQLException is thrown from the JDBC layer, and within it is a message stating:
    <code>The transaction is no longer active - status: 'Marked rollback. [Reason=weblogic.transaction.internal.TimedOutException: Transaction timed out after 63 seconds </code>
    Although we'd like to handle these time out exceptions differently, they look exactly like normal SQLExceptions!  There doesn't seem to be any way to programatically tell which is which.
    SQLState = null
    Error Code = 0
    Next Exception = null
    Instance = java.sql.SQLException                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Handling JTA timeouts within WLS client application

              Hello
              I have a Java program which is a JMS client to WLS 7.0. I use JTA(javax.transaction.UserTransaction)
              to handle txns. I am not sure which is the best way to handle JTA timeouts.
              I found that I could catch the javax.transaction.RollbackException when I try
              to do a UserTransaction.commit(). But I am not allowed to catch weblogic.transaction.TimedOutException().
              My code looks something like this....
              UserTransaction utx;
              utx.begin();
              doSomeJMS()
              doSomeSQL()
              utx.commit();
              I would like to know what is the suggested way of catching JTA timeouts within
              my application so that I can retry the transaction.
              Thanks
              Ramdas
              

              Steve,
              Thanks for the code. It is exactly what I was looking for.
              Ramdas
              "Stephen Felts" <[email protected]> wrote:
              >The attached code works - you will get back "GOT A TIMEOUT".
              >
              >
              >
              >
              >"Ramdas Hegde" <[email protected]> wrote in message news:3f130b34$[email protected]..
              >>
              >> Hello
              >>
              >> I have a Java program which is a JMS client to WLS 7.0. I use JTA(javax.transaction.UserTransaction)
              >> to handle txns. I am not sure which is the best way to handle JTA timeouts.
              >> I found that I could catch the javax.transaction.RollbackException
              >when I try
              >> to do a UserTransaction.commit(). But I am not allowed to catch weblogic.transaction.TimedOutException().
              >>
              >> My code looks something like this....
              >>
              >> UserTransaction utx;
              >> utx.begin();
              >>
              >> ...
              >> doSomeJMS()
              >> doSomeSQL()
              >>
              >> utx.commit();
              >>
              >> I would like to know what is the suggested way of catching JTA timeouts
              >within
              >> my application so that I can retry the transaction.
              >>
              >> Thanks
              >>
              >> Ramdas
              >
              >
              

  • Catching TimedOutException from within JWS

    I have a web service method within a JWS file that may take long amount of time to process. Occasionally, this method will cause a TimedOutException.
    I've tried creating methods for all of the callback events outlined in the "Context.Callback" interface, but none of them seem to get triggered when this particular exception occurs. I would like to be able to catch any TimedOutExceptions that are thrown and handle the errors gracefully. Is there a way to do this?
    Thanks,
    David

    Hi Setya,
    I am very sorry ..that i didnt look at the weblogic version which u were using. Actually The Resource Injection and EJB injection are defined by Servlet Specification 2.5 Onwards...WebLogic Server 10.0 implements the Servlet 2.5 specification. These features are available Only After "WebLogic 10.0" Onwards.
    So in WebLogic 9.x you cannot Inject resources.
    Thanks
    Jay SenSharma

  • Not harmfull TimedOutException?

    I have TimedOutException exception which seems does not affect
    functionality of the program. I suppose that it is not so harmless.
    Any help is appreciated. Below are details.
    Client application runs on the same machine as application server, but
    in different JVM. We use WLS 6.0sp2 on AIX and Oracle database. Client
    application runs a thread that from time to time does the following
    (actually very often in some cases).
    Handle objectHandle = ...;
    UserTransaction trans = PortableRemoteObject.narrow(
    context.lookup("javax.transaction.UserTransaction"),
    UserTransaction.class);
    boolean failed = true;
    for (int attemptNo = 0;
    failed && attemptNo < MAX_ATTEMPTS;
    attemptNo++) {
    long starttime = System.currentTimeMillis();
    try {
    trans.begin();
    trans.setTransactionTimeout(TRANS_TIMEOUT );
    MyBean ejbBean = (MyBean)handle.getEJBObject();
    ejbBean.someMethod(someParameters);
    trans.commit();
    failed = false;
    } catch(Exception ex) {
    ex.printStackTrace();
    } finally {
    if (failed) {
    trans.rollback();
    System.out.println("ejbBean.someMethod(someParameters)"+
    ", attempt " + attemptNo,
    ", during
    "+(System.currentTimeMillis()-starttime),
    ", success "+(!failed));
    MAX_ATTEMPTS defines number of possible failed attempts (5). The first
    successfull execution stops the loop. TRANS_TIMEOUT is 300.
    From the output I can see, that all my transactions were commited with
    success during 0-12 seconds.
    ejbBean.someMethod(someParameters), attempt 0, during 3745, success
    true
    But in WLS log some time later I am getting a lot of timed-out
    exceptions (example is at the end of the email).
    MyBean is CMP entity bean. Transactions are required for all methods.
    From config.xml
    <JDBCConnectionPool
    CapacityIncrement="1"
    InitialCapacity="4"
    LoginDelaySeconds="1"
    MaxCapacity="10"
    Name="XXXDBPool"
    ShrinkPeriodMinutes="15"
    ShrinkingEnabled="true"
    Targets="myserver,mycluster"
    DriverName="oracle.jdbc.driver.OracleDriver"
    URL="jdbc:oracle:thin:@host:1521:XXXXX"
    Properties="user=USER;password=PASSWORD;">
    </JDBCConnectionPool>
    <JDBCTxDataSource
    EnableTwoPhaseCommit="true"
    JNDIName="XXXPool"
    Name="XXXPool"
    PoolName="XXXDBPool"
    Targets="myserver,mycluster">
    </JDBCTxDataSource>
    Example of weblogic exception.
    ####<Dec 3, 2002 1:53:24 PM EST> <Error> <JTA> <toque> <myserver>
    <ExecuteThread: '26' for queue: 'default'> <GLMInternal> <> <000000>
    <Transaction = transaction=(IdHash=722042928,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Rolled
    back. [Reason = weblogic.transaction.internal.TimedOutException:
    Transaction timed out after 119seconds
    tx = transaction=(IdHash=145359334,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Active,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=119,seconds
    left=60,weblogic.jdbc.jts.Connection,SCInfo[myserver]=(state=active),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001}))
    Start server side stack trace:
    weblogic.transaction.internal.TimedOutException: Transaction timed out
    after 119seconds
    tx = transaction=(IdHash=145359334,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Active,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=119,seconds
    left=60,weblogic.jdbc.jts.Connection,SCInfo[myserver]=(state=active),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    SituationScanBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001}))
    at weblogic.transaction.internal.TransactionImpl.wakeUp(TransactionImpl.java:1009)
    at weblogic.transaction.internal.TransactionManagerImpl.processTimedOutTransactions(TransactionManagerImpl.java:810)
    at weblogic.transaction.internal.TransactionManagerImpl.wakeUp(TransactionManagerImpl.java:791)
    at weblogic.transaction.internal.TransactionManagerImpl$1.run(TransactionManagerImpl.java:757)
    at java.lang.Thread.run(Thread.java:498)
    End server side stack trace
    ],numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds since
    begin=60,seconds left=60,ServerResourceInfo[weblogic.jdbc.jts.Connection]=(state=rolledback,assigned=myserver),SCInfo[myserver]=(state=rolledback),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001})) completed heuristically:
    Possible heuristic hazard situation with resource
    'weblogic.jdbc.jts.Connection
    Error = javax.transaction.xa.XAException: No connection associated
    with xid = 308:1681115cdcd0e7d3>
    Thanks,
    Viktor Lioutyi

    First off, is your operation idempotent? If not, how do you know that
    attemptNo > 1 is safe to do? (ie how do you know that a previous
    transaction didn't already commit.)
    It looks like the transaction times out and there is a possible
    heuristic problem on one of the resources. You might post in the
    transaction newsgroup for more information.
    Also, I doubt you want the "EnableTwoPhaseCommit" set to true. This
    flag is mis-named. It really means "fake XA participation for a non-XA
    resource." When it is not set, a non-XA resource will not be allowed to
    participate in a XA/2PC transaction.
    -- Rob
    Viktor Lioutyi wrote:
    I have TimedOutException exception which seems does not affect
    functionality of the program. I suppose that it is not so harmless.
    Any help is appreciated. Below are details.
    Client application runs on the same machine as application server, but
    in different JVM. We use WLS 6.0sp2 on AIX and Oracle database. Client
    application runs a thread that from time to time does the following
    (actually very often in some cases).
    Handle objectHandle = ...;
    UserTransaction trans = PortableRemoteObject.narrow(
    context.lookup("javax.transaction.UserTransaction"),
    UserTransaction.class);
    boolean failed = true;
    for (int attemptNo = 0;
    failed && attemptNo < MAX_ATTEMPTS;
    attemptNo++) {
    long starttime = System.currentTimeMillis();
    try {
    trans.begin();
    trans.setTransactionTimeout(TRANS_TIMEOUT );
    MyBean ejbBean = (MyBean)handle.getEJBObject();
    ejbBean.someMethod(someParameters);
    trans.commit();
    failed = false;
    } catch(Exception ex) {
    ex.printStackTrace();
    } finally {
    if (failed) {
    trans.rollback();
    System.out.println("ejbBean.someMethod(someParameters)"+
    ", attempt " + attemptNo,
    ", during
    "+(System.currentTimeMillis()-starttime),
    ", success "+(!failed));
    MAX_ATTEMPTS defines number of possible failed attempts (5). The first
    successfull execution stops the loop. TRANS_TIMEOUT is 300.
    From the output I can see, that all my transactions were commited with
    success during 0-12 seconds.
    ejbBean.someMethod(someParameters), attempt 0, during 3745, success
    true
    But in WLS log some time later I am getting a lot of timed-out
    exceptions (example is at the end of the email).
    MyBean is CMP entity bean. Transactions are required for all methods.
    From config.xml
    <JDBCConnectionPool
    CapacityIncrement="1"
    InitialCapacity="4"
    LoginDelaySeconds="1"
    MaxCapacity="10"
    Name="XXXDBPool"
    ShrinkPeriodMinutes="15"
    ShrinkingEnabled="true"
    Targets="myserver,mycluster"
    DriverName="oracle.jdbc.driver.OracleDriver"
    URL="jdbc:oracle:thin:@host:1521:XXXXX"
    Properties="user=USER;password=PASSWORD;">
    </JDBCConnectionPool>
    <JDBCTxDataSource
    EnableTwoPhaseCommit="true"
    JNDIName="XXXPool"
    Name="XXXPool"
    PoolName="XXXDBPool"
    Targets="myserver,mycluster">
    </JDBCTxDataSource>
    Example of weblogic exception.
    ####<Dec 3, 2002 1:53:24 PM EST> <Error> <JTA> <toque> <myserver>
    <ExecuteThread: '26' for queue: 'default'> <GLMInternal> <> <000000>
    <Transaction = transaction=(IdHash=722042928,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Rolled
    back. [Reason = weblogic.transaction.internal.TimedOutException:
    Transaction timed out after 119seconds
    tx = transaction=(IdHash=145359334,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Active,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=119,seconds
    left=60,weblogic.jdbc.jts.Connection,SCInfo[myserver]=(state=active),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001}))
    Start server side stack trace:
    weblogic.transaction.internal.TimedOutException: Transaction timed out
    after 119seconds
    tx = transaction=(IdHash=145359334,Name = [EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],Xid=308:1681115cdcd0e7d3,Status=Active,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=119,seconds
    left=60,weblogic.jdbc.jts.Connection,SCInfo[myserver]=(state=active),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    SituationScanBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001}))
    at weblogic.transaction.internal.TransactionImpl.wakeUp(TransactionImpl.java:1009)
    at weblogic.transaction.internal.TransactionManagerImpl.processTimedOutTransactions(TransactionManagerImpl.java:810)
    at weblogic.transaction.internal.TransactionManagerImpl.wakeUp(TransactionManagerImpl.java:791)
    at weblogic.transaction.internal.TransactionManagerImpl$1.run(TransactionManagerImpl.java:757)
    at java.lang.Thread.run(Thread.java:498)
    End server side stack trace
    ],numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds since
    begin=60,seconds left=60,ServerResourceInfo[weblogic.jdbc.jts.Connection]=(state=rolledback,assigned=myserver),SCInfo[myserver]=(state=rolledback),properties=({ISOLATION
    LEVEL=2, weblogic.transaction.name=[EJB
    MyBean_WebLogic_CMP_RDBMS.someMethod()],
    weblogic.jdbc=t3://10.77.3.10:8001})) completed heuristically:
    Possible heuristic hazard situation with resource
    'weblogic.jdbc.jts.Connection
    Error = javax.transaction.xa.XAException: No connection associated
    with xid = 308:1681115cdcd0e7d3>
    Thanks,
    Viktor Lioutyi

  • Can't catch the exception when transaction rollback ,BPEL/SOA 11G,updated!

    Hi Guys ,
    I have two insert/update invoke actions through dbadpter in my BPEL process .
    When I set the GetActiveUnitOfWork property of those two db adapters to true ,it successfully makes the global transaction work . any of them failed will cause the other rollback.
    But the CatchAll brunch can't catch the exception in that case,
    I can only see exception message from the system output :
    02/11/2009 11:36:46 AM oracle.toplink.transaction.AbstractSynchronizationListener beforeCompletion
    WARNING:
    Local Exception Stack:
    Exception [TOPLINK-4002] (Oracle TopLink - 11g Release 1 (11.1.1.1.0) (Build 090527)): oracle.toplink.exceptions.DatabaseException
    Internal Exception: java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (Table1_PK) violated
    from BPEL console , you can't even see the error , the process finished with no exception.
    When I set GetActiveUnitOfWork to false, CatchAll brunch is able to catch the exception , but global rollback is not working .
    I try all the other method like set the transaction property of BPEL to required , using checkpoint() in java embedding . it looks like only way is set GetActiveUnitOfWork to true, but can't catch exception.
    Here are some updated:
    Here is my process
    Main Sequence
    Invoke (dbadapter update)
    Invoke (dbadapter insert)
    Global CatchAll
    Invoke(jmsAdapter sendjms)
    if I disable the CatchAll branch , when insert failed , the insert will rollback as well, even GetActiveUnitOfWork set to false.
    enable CatchAll branch , even doing nothing in this branch , the update won't rollback when insert failed. it looks like when catch the exception , bpel seems not rollback , I try to add throw rollback in catchall branch, no any effect.
    any clue ?
    Kevin
    Edited by: kyi on Nov 5, 2009 10:10 AM

    Hi All,
    We are also facing a similar kind of issue.
    We have a simple BPEL which will makes use of JAva embedding to call an end point to check its availibility.
    The Java code for cheking the enpoint connectivity is below
    try{      
    boolean endpointAvailable = false;
    long start = System.currentTimeMillis();
    int endpointTestURL_port = 8445 ;
    int endpointTestURL_timeout = 500;
    String endpointTestURL_queryString = "" ;
    String endpointTestURL_protocol = (String)getVariableData ("endpointProtocol");
    addAuditTrailEntry("endpointTestURL_protocol: " + endpointTestURL_protocol);
    String endpointTestURL_host = (String)getVariableData ("endpointHost");
    addAuditTrailEntry("endpointTestURL_hostl: " + endpointTestURL_host);
    URL endpoint = new URL(endpointTestURL_protocol, endpointTestURL_host, 8445, endpointTestURL_queryString);
    addAuditTrailEntry("endpoint object is created" );
    String endpointTestURL = endpoint.toExternalForm();
    addAuditTrailEntry("Checking availability of endpoint at URL: " + endpointTestURL);
    // Configure connection
    HttpURLConnection connection = (HttpURLConnection)endpoint.openConnection();
    connection.setRequestMethod("GET");
    addAuditTrailEntry("The Method is Get");
    connection.setConnectTimeout(5000);
    addAuditTrailEntry("Timeout is 500 ms");
    // Open connection
    connection.connect();
    addAuditTrailEntry("Open Connection");
    String responseMessage = connection.getResponseMessage();
    addAuditTrailEntry("Recieved availability response from endpoint as: " + responseMessage);
    // Close connection
    connection.disconnect();
    endpointAvailable = true;
    if (endpointAvailable)
    setVariableData("crmIsAvailable", "true");
    else
    setVariableData("crmIsAvailable", "false");
    catch(Exception e)
    System.out.println ("Error in checking endpoint availability " + e) ;
    addAuditTrailEntry("error message is : " +e);         
    When we run the above as a seperate java program it runs fine i.e goes to the catch block and catches the exception.
    But when we run it within the java embedding in BPEL(11G) it gives us the follwoing error.
    The reason was The execution of this instance "490001" for process "default/GMDSSalesLeadsBackMediationInterface!1.0*soa_e1a6362f-c148-417c-819c-9327017ebfa4" is supposed to be in an active jta transaction, the current transaction status is "ROLLEDBACK" .
    Consult the system administrator regarding this error.
         at com.oracle.bpel.client.util.TransactionUtils.throwExceptionIfTxnNotActive(TransactionUtils.java:119)
         at com.collaxa.cube.engine.CubeEngine.store(CubeEngine.java:4055)
         at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:4372)
         at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:4281)
         at com.collaxa.cube.engine.CubeEngine._createAndInvoke(CubeEngine.java:713)
         at com.collaxa.cube.engine.CubeEngine.createAndInvoke(CubeEngine.java:545)
         at com.collaxa.cube.engine.delivery.DeliveryService.handleInvoke(DeliveryService.java:654)
         at com.collaxa.cube.engine.ejb.impl.CubeDeliveryBean.handleInvoke(CubeDeliveryBean.java:355)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
         at com.bea.core.repackaged.springframework.jee.intercept.MethodInvocationInvocationContext.proceed(MethodInvocationInvocationContext.java:104)
         at oracle.security.jps.ee.ejb.JpsAbsInterceptor$1.run(JpsAbsInterceptor.java:88)
         at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
         at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:414)
         at oracle.security.jps.wls.JpsWeblogicEjbInterceptor.runJaasMode(JpsWeblogicEjbInterceptor.java:61)
         at oracle.security.jps.ee.ejb.JpsAbsInterceptor.intercept(JpsAbsInterceptor.java:106)
         at oracle.security.jps.ee.ejb.JpsInterceptor.intercept(JpsInterceptor.java:106)
         at sun.reflect.GeneratedMethodAccessor960.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
         at com.bea.core.repackaged.springframework.jee.intercept.JeeInterceptorInterceptor.invoke(JeeInterceptorInterceptor.java:69)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
         at weblogic.ejb.container.injection.EnvironmentInte
    we also get
    BEA1-108EA2A88DAF381957FF
    weblogic.transaction.internal.TimedOutException: Transaction timed out after 301 seconds
    BEA1-108EA2A88DAF381957FF
         at weblogic.transaction.internal.ServerTransactionImpl.wakeUp(ServerTransactionImpl.java:1733)
         at weblogic.transaction.internal.ServerTransactionManagerImpl.processTimedOutTransactions(ServerTransactionManagerImpl.java:1578)
         at weblogic.transaction.internal.TransactionManagerImpl.wakeUp(TransactionManagerImpl.java:1900)
         at weblogic.transaction.internal.ServerTransactionManagerImpl.wakeUp(ServerTransactionManagerImpl.java:1488)
         at weblogic.transaction.internal.WLSTimer.timerExpired(WLSTimer.java:35)
         at weblogic.timers.internal.TimerImpl.run(TimerImpl.java:273)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    javax.ejb.EJBException: Transaction Rolledback.: weblogic.transaction.internal.TimedOutException: Transaction timed out after 301 seconds
    BEA1-108EA2A88DAF381957FF
    We tried the following
    Increase the JTA timeout in the EM console to a larger value like 600 secs.
    The BPEL instance is not getting created.
    Any help would be appreciated
    Thanks
    Lalit

  • Photoshope Elements when selecting an action, the paint brush tool doesn't work and system keeps freezing, then catching up every 30-45 seconds

    I have been having this problem with elements ever since the last OS upgrade, but it wasn't all the time and it wasn't very bad. Now, I have upgraded my macbook again, and I cannot even edit a photo!! I open the photo, choose an action, say "smooth skin", then choose the paint brush, I start to "paint" over their face and it won't paint a line, I have to keep clicking it, click - it paints, move brush, click again - it paints. Plus, every time I choose a tool or an action, it freezes for about 10 seconds, then catches up to what I am doing, 30 seconds later, it freezes again. HELP!! I have 8 sessions to finish editing by this weekend!! I just want to cry!!

    Try deleting the prefs and the saved application state:
    A Reminder for Mac Folks upgrading to Yosemite | Barbara's Sort-of-Tech Blog

  • Help to catch the output of a Transaction

    Hi,
    I have this issue and need help, I have a program lets say "ZPROGRAM", this programs calls a RFC "ZFUNC" this function must be able to send the parameters to execute a SAP standard transaction for example MB51, the function must send the plant number, storage location, and material number, then this RFC must catch the output of the report into an internal table so that i can work with the output in "ZPROGRAM", in other words what I see on screen as result of MB51 I need it in an internal table so that I can manupulate the data.
    I hope someone could tell me how to accomplish this.
    Thanks in advice.

    Hi,
       Pls try
        DATA list_tab TYPE TABLE OF abaplist.
        DATA vlist  LIKE  table of LISTZEILE WITH HEADER LINE.
        submit RM07DOCS
          with XXX
          EXPORTING LIST TO MEMORY
          and return .
          CALL FUNCTION 'LIST_FROM_MEMORY'
            TABLES
              listobject = list_tab
            EXCEPTIONS
              not_found  = 1
              OTHERS     = 2.
       CALL FUNCTION 'LIST_TO_ASCI'
          EXPORTING
            list_index         = -1
          TABLES
            listasci           = vlist
            listobject         =list_tab
          EXCEPTIONS
            empty_list         = 1
            list_index_invalid = 2
            OTHERS             = 3.
    Regards,
    Pole
    Edited by: Pole li on Jul 17, 2008 3:57 AM

  • How to catch error message inside a variable?

    Hi,
    I'm trying to catch the error message inside a variable using this this command below:-
    <%=odiRef.getPrevStepLog("MESSAGE")%>
    Could you please tell me what is the right approach to capture the error message inside a variable.
    Thanks
    Anindya

    Hi Bhabani,
    I have done this and select an oracle schema.But the variables only captures the (null).Please look into this.You must have one step prior to this refresh variable. Then only it can get the status as given below.
    Returns the one-letter code indicating the status with which the previous step terminated. The state R (Running) is never returned.
    D: Done (success)
    E: Error
    Q: Queued
    W: Waiting
    M: Warning
    If you want the complete error details then you will face issues in case of multi line message. For this best option would be jython variable.Could please provide me some idea how to use this jython variable.I will update you on this soon
    Thanks
    Anindya

  • How to catch exception into a String variable ?

    I have a code
    catch(Exception e)
                e.printStackTrace();
                logger.error("\n Exception in method Process"+e.getMessage());
            }when i open log i find
    Exception in method Process null.
    But i get a long error message in the server console !! I think thats coming from e.printStackTrace().
    can i get the error message from e.printStackTrace() into a String variable ?
    I want the first line of that big stacktrace in a String variable.
    How ?

    A trick is to issue e.printStackTrace() against a memory-based output object.
    void      printStackTrace(PrintStream s)
             // Prints this throwable and its backtrace to the specified print stream.
    void      printStackTrace(PrintWriter s)
    //          Prints this throwable and its backtrace to the specified print writer.Edited by: BIJ001 on Oct 5, 2007 8:54 AM

  • Facing problem while going to  catch return result from web-services.

    Hi everybody,
    I am new to BPEL. I am facing problem while going to catch the attributes of resultsets returning from web-services(QAS). As far as my knowledge, two types of results it should return - XML entities and another is attributes which is coming as the part of XML entitites. I am able to catch the XML entities, but can't catch the attributes under it. Even, I am not able to see whether web-services returning something within that field.
    When, I tried to catch the attribute and store to a temporary varilable using the following code:
    *<assign name="AssignQASDoGetAddress1">*
    *<copy>*
    *<from variable="InvokeQAS_DoSearch_OutputVariable"*
    part="body"
    query="/ns6:QASearchResult/ns6:QAPicklist/ns6:PicklistEntry/@PostcodeRecoded"/>
    *<to variable="temp"/>*
    *</copy>*
    *</assign>*
    but, I am facing the following selectionFailure errors after running it:
    *"{http://schemasxmlsoap.org/ws/2003/03/business-process/}selectionFailure" has been thrown.*
    -<selectionFailure xmlns="http://schemasxmlsoap.org/ws/2003/03/business-process/">
    -<part name="summary">
    *<summary>*
    empty variable/expression result.
    xpath variable/expression expression "bpws:getVariableData('InvokeQAS_DoSearch_OutputVariable', 'body', '/ns6:QASearchResult/ns6:QAPicklist/ns6:PicklistEntry/@PostcodeRecoded')" is empty at line 269, when attempting reading/copying it.
    Please make sure the variable/expression result "bpws:getVariableData('InvokeQAS_DoSearch_OutputVariable', 'body', '/ns6:QASearchResult/ns6:QAPicklist/ns6:PicklistEntry/@PostcodeRecoded')"is not empty.
    *</summary>*
    *</part>*
    *</selectionFailure>*
    Getting this error it seems to me that web-service is returning nothing, but, it returns something as it has been catched using a method called isPostcodeRecoded() Java Code in Oracle ADF. This method has been used as it should return boolean whereas for catching the xml entities using java code we used the method like getPostcode(), getMoniker().
    For your information, we are using Jdeveloper as the development tool for building the BPEL process.
    Am I doing any syntax error. Please consider it as urgent and provide me asolution.
    Thanks in advance.
    Chandrachur.

    Thanks Dave and Marc, for your suggestions. Actually what I found is QAS web-service is returning nothing as attributes when the attributes are set to the default value. For example, following is the part of the wsdl of the result which QAS webservice returns.
    <xs:element name="QASearchResult">
    - <xs:complexType>
    - <xs:sequence>
    <xs:element name="QAPicklist" type="qas:QAPicklistType" minOccurs="0" />
    <xs:element name="QAAddress" type="qas:QAAddressType" minOccurs="0" />
    </xs:sequence>
    <xs:attribute name="VerifyLevel" type="qas:VerifyLevelType" default="None" />
    </xs:complexType>
    </xs:element>
    <xs:complexType name="QAPicklistType">
    - <xs:sequence>
    <xs:element name="FullPicklistMoniker" type="xs:string" />
    <xs:element name="PicklistEntry" type="qas:PicklistEntryType" minOccurs="0" maxOccurs="unbounded" />
    <xs:element name="Prompt" type="xs:string" />
    <xs:element name="Total" type="xs:nonNegativeInteger" />
    </xs:sequence>
    <xs:attribute name="AutoFormatSafe" type="xs:boolean" default="false" />
    <xs:attribute name="AutoFormatPastClose" type="xs:boolean" default="false" />
    <xs:attribute name="AutoStepinSafe" type="xs:boolean" default="false" />
    <xs:attribute name="AutoStepinPastClose" type="xs:boolean" default="false" />
    <xs:attribute name="LargePotential" type="xs:boolean" default="false" />
    <xs:attribute name="MaxMatches" type="xs:boolean" default="false" />
    <xs:attribute name="MoreOtherMatches" type="xs:boolean" default="false" />
    <xs:attribute name="OverThreshold" type="xs:boolean" default="false" />
    <xs:attribute name="Timeout" type="xs:boolean" default="false" />
    </xs:complexType>
    <xs:complexType name="PicklistEntryType">
    - <xs:sequence>
    <xs:element name="Moniker" type="xs:string" />
    <xs:element name="PartialAddress" type="xs:string" />
    <xs:element name="Picklist" type="xs:string" />
    <xs:element name="Postcode" type="xs:string" />
    <xs:element name="Score" type="xs:nonNegativeInteger" />
    </xs:sequence>
    <xs:attribute name="FullAddress" type="xs:boolean" default="false" />
    <xs:attribute name="Multiples" type="xs:boolean" default="false" />
    <xs:attribute name="CanStep" type="xs:boolean" default="false" />
    <xs:attribute name="AliasMatch" type="xs:boolean" default="false" />
    <xs:attribute name="PostcodeRecoded" type="xs:boolean" default="false" />
    <xs:attribute name="CrossBorderMatch" type="xs:boolean" default="false" />
    <xs:attribute name="DummyPOBox" type="xs:boolean" default="false" />
    <xs:attribute name="Name" type="xs:boolean" default="false" />
    <xs:attribute name="Information" type="xs:boolean" default="false" />
    <xs:attribute name="WarnInformation" type="xs:boolean" default="false" />
    <xs:attribute name="IncompleteAddr" type="xs:boolean" default="false" />
    <xs:attribute name="UnresolvableRange" type="xs:boolean" default="false" />
    <xs:attribute name="PhantomPrimaryPoint" type="xs:boolean" default="false" />
    </xs:complexType>
    here the attributes like FullAddress, PostcodeRecodedare , etc. are not being return by the web-service when it is getting the default value false. But, if it gets true then , it is being displayed at the BPEL console.
    Do you have any idea how can I catch the attributes and its value even when it gets the default value which is already set. Previously, it was returning(it was not being displayed at the console).
    Thanks once again for your valuable suggestions...!!!
    Chandrachur.

  • Catch datetime exception and custom error message in SSRS

    I currently working on create report by using SSRS. I have 2 parameters: [Start date] and [End date] to filter data from database and show it on report. I want to validate 2 datetime parameter as describe above. Please tell me a solution to do this.
    For example:
    When user type the text like: 4/15/2014mmm => System validation thrown a message: [The From Date not correct type]
    But in my case, I want to receive a custom error message by myself.(Look like: [Date Invalid!])

    Hi Brain,
    According to your description, you have a report with two parameters for user to input. Now you want to validate these two parameters and display custom error message when the date is invalid. Right?
    In Reporting Service, it doesn’t provide any interference for us to modify the system error message (the text in grey color). That means we can’t modify the system message when error occurs. However we can create a textbox in this report, use custom code
    and expression to display the custom error message. But this all based on the report is successfully running. So if error occurs during report processing, all the custom code and expression will not work. In this scenario, we find a workaround for you. We
    use custom code to judge if the date is valid, if the users type an invalid date, we return a default value to make sure this report can successfully run. Then we use expression to control the visibility of tablix in this report and create a textbox to show
    the custom error message. Your case has been tested in our local environment. Here are steps and screenshots for your reference:
    Go to Report Properties. Put the code below into custom code:
    Public Shared a As Integer=0
    Public Shared Function IsDate(d1 As String,d2 As String) as Integer
            Try
               FormatDateTime(d1)
               FormatDateTime(d2)
            Catch ex As Exception
                       a=1
            End Try
    return a
    End Function
    Create two parameters. One is StartDate, the other is EndDate. Set the data type of these two parameters Text.
    Create a filter for StartDate, put the expression below into Value:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,CDate(IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,Parameters!StartDate.Value,"1/1/2012")),CDate("1/1/2012"))
    Create a filter for EndDate, put the expression below into Value:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,CDate(IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,Parameters!EndDate.Value,"1/1/2013")),CDate("1/1/2013"))
    Ps: In step3 and step4, the date(“1/1/2012”, “1/1/2013”) in the expression are the default we set to make sure the report can successfully process. You can set any date existing in your dataset.
    Use the expression below to set the visibility of the tablix:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,false,true)
    Create a textbox, put the expression below into it:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,"","Date invalid")
    Save and preview. It looks like below:
    Reference:
    SSRS Calendar and Date Restriction
    Errors and Events Reference (Reporting Services)
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou
      

  • How to catch up Exception message?

    i have a question while using try{ ... }catch{ ... } clauses. for when update, delete, databse, there might be error occurred. all to often i do not deal with the message, only if to check log when serious problem i have to find it out; but i hope to learn how if i am able to display message of my own while erro occurrs. for instance, when falling into SQLException, originaly i might just utilize
    }catch(SQLException e){
    e.printStackTrace();
    is it possible for me to catch up message inside the printStackTrace that may happen while errors appearing? (or only down to catch{} clause be the last deadline that i am able to use? because i hope i am able to capture error code like ora-1234 and tranlate it into messages that user, who doesn't know too much about pc, can understand easily while reporting bug; and not just saying "we have problem here!")
    that is, if 'A' situation popping out, i hope to direct it to error page with special message shown. so does the same error page with different message specified while 'B' situation found out!
    any suggestions would be appreciated~
    thanks in advice,

    printStackTrace isn't obligatory. It's basically what you do with an exception when you don't have anything more specific to do with it.
    You can certainly catch a specific exception at any level, including inside another try {} block.
    Even having caught an exception you can decide that you don't want to handle it at this point in the code, and throw it again.
    You might do:
    try {
         try {
           ... statment which migh cause a particular database exception
            } catch(SQLException e) {
            if(e.getMessage().startsWith("ORA-1232")) {
              .. do somthing usefull
             } else
            throw e;   // the particular SQL exception was unexpected so go on and crash
       catch(Exception e) {
         e.printStackTrace();   // unexpected program failure

  • How to catch SAP application errors in BPM.

    Hi,
    I have a IDOC to Soap Sync Scenario where I send the message to a Webservice. I have used a BPM since we need to catch the resposne of this message and map it to a RFC. For ex if I get a success resposne I need to map success if not than I need to catch the error and map it to the RFC. Now here in some cases like if the target system (webservice) is down than XI raises a sap application error:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Inbound Message
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIAdapterFramework</SAP:Category>
      <SAP:Code area="MESSAGE">GENERAL</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: Connection refused (errno:239)</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack />
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    Normally XI stops the process in these cases and does not proceed to the next step but I need to catch this message and map the content in the AdditionalText to the target RFC. Can anyone let me know how to catch this SAP Application Error in BPM and map it to the RFC.
    Thanks,
    Bhargav

    Hi Gaurav,
    As I have mentioned I need to catch the application error in the BPM. If you see the discussion that is mentioned after the blog you have mentioned it is stated that the fault messages or the application error cannot be caught in BPM.
    In the blog that you stated we can catch the fault message and map it to a message structure but only to that extent after that it would stop the BPM process at that step but would not proceed further as shown in the screenshot given in the blog it would fail as "application error restart not possible".
    I need to proceed further and capture this error to an RFC Structure and call a proxy.
    Here after the error it does not proceed to the next step.
    Thanks,
    Bhargav

  • How do we catch errors in Servlets?

    Hello, i 'm using Servlets and JDBC.
    i'm having a form.html where the user inserts data in the input fields.
    It's a registration page.
    I would like to check for possible user errors.
    For example if the user has not typed anything in a required field like field "password", so the field is null.
    I would like to inform the user that this field is null and he/she shall type in it again.
    (I'm talking generally not only for a registration page but to any page that requires correct data)
    *1.* Shall i use Javascript?
    *2.* Shall i direct the user to an error page where the page describes the error, what the user has to do in order to correct it and direct him back to the previous page?
    *3.* Shall i only use if/else?
    I would appreciate if sm could give me some advice on this matter or post me some links related to catch errors in servlets.
    Thanks, in advance!
    Edited by: g_p_java on Jul 11, 2009 12:15 PM

    Here is a possible approach to this issue:
    * use javascript to validate all textfields on the form client-side every time the user clicks the submit button. If it fails, put a message in red next to the problem textfield describing what the problem is. Dont allow submit if there are validation issues.
    * More than one validation may apply to a given textfield. For instance, the field cant be empty is checked before its checked for an invalid date.
    * Check to see if its an invalid date format first (example: mm/dd/yyyy), then check to see if its an invalid date (non leap year for example).
    * recheck all validation back on the server (necessary if user disabled javascript or a hacker bypasses your client side validation). Redraw the page and populate it, but put messages next to the problem fields as you did for javascript.
    * The invalid date format and invalid date should pass if given an empty value since the its the empty value validation (if it applicable for that field) that is repsonsible for that test.
    *since you will be applying this validation over and over again for all your JSP pages for this project and future projects, it may be a good idea to create reusable code for it. You may also research google for good approaches.
    Your javascript code should be from a single javascript file that is included into each JSP page so it can be reused.
    @see http://www.xs4all.nl/~sbpoley/webmatters/formval.html
    * All textfields should be validated throughly so your database never gets bad data (data is king).
    * common things to check for:
    invalid date format, invalid date, empty textfield, invalid email address, invalid telephone number format, invalid zip code, etc, etc, etc

Maybe you are looking for