ABAP OO - Exceptions & Events

Hello all:
Two questions specific to ABAP OO world:
1. Is anyone using "RAISE EXCEPTION TYPE exception-class" to raise business process errors (e.g. a customer is not found, or a sales order number is invalid, which originally was referred using ABAP Message Class (transaciton SE91)), Or are you keeping the 'RAISE EXCEPTION TYPE exception-class' limited only to raise and handle global level errors like (CAST_ERROR, TYPE_CONVERSION_ERROR, etc)?
2. Class Method M1 of class C1 raises event E1.
   Class Method M2 of class C2 handles the event E1.
   In method M1, is it possible to check - immediately
   after the statement that raises event E1 - whether the
   execution of M2 was successful? If yes, can you please
   briefly describe how we can achieve that.
Thanks!

In my personal opinion all errors that make the further regular processing within a certain context impossible, should raise an exception.
The problem with the message statement is, that if a function throws out dialog messages at the user, you can't use it as an API anymore, because if errors occur, the caller of your function cannot intercept the message anymore.
Of course on may use "message raising" but the use is a bit awkward and the especially if the caller decides propagate the error messages of the funtion that was called, it has to use these sy-msgid and all these Variables.
An Exception can also have an error text associated to it and in 640 an exception class may have an old-fashioned message class associated with it.
As error handling with try/catch has advantages (you may treat similar errors of a whole related block in one piece of code, error messages will be handed on to the caller, the compiler will check, if the error is taken care of), in my opinion all application-level errors should use exception classes. An exception class should be created for each type of error that can occur.
Exception classes can also be derived from each other, thus forming a hierarchy of errors. The caller may then even decide, if all errors of a certain "family" are treated equally, or if more specific checks are done, based on the specific type of exception.
For bringing up error messages to the user, you can get the exception's text and output it via message, if the error has really been propagated to a level of the application that is clearly dialogue-related.
This model is in my opinion much superior to the earlier error handling model.
Hope that helps.
Yours
Christian

Similar Messages

  • ABAP proxy exception to SOAP fault and vice versa not getting mapped

    Hi there,
    I have these scenario's: ABAP proxy to SOAP (AXIS framework) and the other way around, synchronous, using AAE.
    When declaring the Synchronous Service interfaces we also defined error message types in order to pass system and application exceptions back to the service consumers.
    The behavior we are observing is as follows;
    When an exception is generated on the ABAP proxy, the error message type is correct generated and filled with the corresponding values in the ABAP proxy runtime. However, when the response arrives at the service consumer, it only contains a SOAP fault filled with some kind of generic PI mapping exception information.
    1. Why is the original ABAP proxy exception not mapped/passed into the SOAP response?
    2. What can we do in order to change that situation?
    3. Does it has to do with the use of the AAE - Advanced Adapter Engine or the AXIS framework?
    PS: We have performed a test of the Operation Mapping - OM using the ABAP exception as input and it did work correctly, so the error structure seems to be Ok.
    Many thanks for your replies.
    Edited by: Roberto Viana on Jul 26, 2010 8:30 PM

    Problem was caused by some differences in namespaces between source and target.

  • Add-on 9000005 failed with exception; Event Type: 1

    Hi Experts,
    I am woking on a project which uses DI API and creates AP Invoice by reading an excel file.
    I used all the invoice in one sap transaction.
    I read excel line by line and create one AP Invoice per line. It works when excel is having less then 500 records. But if there are more then 500 records or more then 600 records, it give following error to me
    Add-on 9000005 failed with exception; Event Type: 1
    Can anyone help me in it?
    Thanks!!
    Ritu

    Hi,
    I'm sure there is a limit to the number of rows you can add to an Invoice but I think it's probably limited on memory rather than a fixed limit on the number of rows.  This might be an out of memory error that's causing the exception.  Have you tried putting a try/catch around your code to see what the exact details are of the exception?  Also, if you are filling in any text fields on the invoice (remarks), they are limited to 30K.
    David

  • Sequence of ABAP code and events.

    Hello,
      Please tell me the proper sequence of writing ABAP code.
    (Event execution sequence and code writing sequence.)
    - which event should follow which event?
    - which code should be written where?
    - Sequence of Includes (e.g. TOP, PBO, PAI, Subroutine,etc.)
    Regards,
    Sharayu.

    Sequence of Includes:
    TOp Include  (All data declarations/Selection screen declared here)
    Form Include ( All subroutines are placed inside it)
    For a Screen
    PBO
    PAI
    Load of program:When the program is executed
    INITIALIZATION: Fill the default values into the fields or we can assign values to the fields in this event. It triggers first.
    AT SELECTION-SCREEN: It is commonly used for validations like ON-REQUEST ( for search help) , OUTPUT ( modify screens ).
    TOP-OF-PAGE: Header of the report or any data to print on top of the page in list.
    END-OF-PAGE: Footer details like page no: / total no: of pages.
    START-OF-SELECTION: For processing ur code selects, loops, FM'S and all.
    END-OF-SELECTION: Output formating. It is not required to write normally but in some special conditions like to print after the START-OF-SELECTION event.

  • Add-on 9000035 failed with exception; Event Type: 32

    In loadscreen function i have  load the XML form but it shows the error like
    "Add-on 9000035 failed with exception; Event Type: 32"
    But  i will connect to some other db means its working .
    Share your ideas for what is the problem to load the screen in particular DB
    Thanks,
    Helen. S

    Hi,
    You may check this: Add-on 9000002 failed with exception; Event Type: 32
    Thanks,
    Gordon

  • Addon 9000000X failed with exception; Event type X

    Hi SDK experts,
    We had a problem with occurrence intermittent, something that we identified with relation on wait of response of event.
    The problem is:
    My addon need to submit XML files to some webservices. In some cases this files will be send on batches, what causes the response time to events on addon is to much large.
    In this cases, when the response time is much large, the B1 overthrow the addon.
    In compiled mode the message is not shown. This evidence was achieved on debug time.
    The error message is "Addon 90000002 failed with exception; Event type 6"
    The paleative solution was implement a thread to release the event. But threads on addons can be a problem.
    What the opinions?
    We need a solutions. Our addon is a market product for process accounting and fiscal.
    regards.
    Daniel Weissmann

    Hi,
    You may check this thread first:
    Addon Crashes
    Thanks,
    Gordon

  • An exception event is caught by the trace command, but not by java command

    I am having a strange exception in the output of the trace command. The exception is only happening if I instantiate a new object in test class (I have included the code below).
    This is the exception is the output of trace:
    ThreadName: ====== main ======
    methodEntryEvent: main -- simplestTest location:simplestTest:13
    | Exception event found: instance of java.lang.ClassNotFoundException(id=39) catch: java.lang.ClassLoader:303 exception details: class com.sun.tools.jdi.ObjectReferenceImpl
    | Exception event found: instance of java.lang.ClassNotFoundException(id=40) catch: java.lang.ClassLoader:303 exception details: class com.sun.tools.jdi.ObjectReferenceImpl
    | Exception event found: instance of java.lang.ClassNotFoundException(id=40) catch: java.lang.ClassLoader:303 exception details: class com.sun.tools.jdi.ObjectReferenceImpl
    | methodEntryEvent: <init> -- Tutti location:Tutti:22
    | | methodExitEvent: <init> -- Tutti
    | methodEntryEvent: <init> -- Tutti location:Tutti:22
    | | methodExitEvent: <init> -- Tutti
    | methodExitEvent: main -- simplestTest
    Death of ThreadName:====== main end ======
    -- The application exited --
    This is the very simple test class:
    public class simplestTest {
        public static void main(String[] args) {
            int x = 10;
            System.out.println("hello test");
            Tutti tuttike;
            tuttike = new Tutti();
            Tutti tuttike2;
            tuttike2 = new Tutti();
    class Tutti {   
    }If I do not have any instantiations, I do not have the exception in the trace output. Also, if I run the above test application normally (with the java command), I do not have these exceptions.
    Anybody have an idea?

    Indeed, in jdb I do not get these exceptions. I was also about to say that running the trace tool from the command line (not from within Netbeans as before) yielded a slightly more detailed result:
    -- VM Started --
    ThreadName: ====== main ======
    methodEntryEvent: main  --  simplestTest location:simplestTest:13
    | Exception event found: instance of java.lang.ClassNotFoundException(id=39) cat
    ch: java.lang.ClassLoader.loadClass(java.lang.String, boolean)+39 exception deta
    ils: class com.sun.tools.jdi.ObjectReferenceImpl
    | Exception event found: instance of java.lang.ClassNotFoundException(id=40) cat
    ch: java.lang.ClassLoader.loadClass(java.lang.String, boolean)+39 exception deta
    ils: class com.sun.tools.jdi.ObjectReferenceImpl
    | Exception event found: instance of java.lang.ClassNotFoundException(id=40) cat
    ch: java.lang.ClassLoader.loadClass(java.lang.String, boolean)+39 exception deta
    ils: class com.sun.tools.jdi.ObjectReferenceImpl
    | methodEntryEvent: <init>  --  Tutti location:Tutti:22
    | | methodExitEvent: <init>  --  Tutti
    | methodEntryEvent: <init>  --  Tutti location:Tutti:22
    | | methodExitEvent: <init>  --  Tutti
    | methodExitEvent: main  --  simplestTest
    Death of ThreadName:====== main end ======
    -- The application exited --But I now understand this is completely normal behavior. What a strange way to signal class loading... In my own, much more elaborate debugging application, I have now signaled through JDI not to report these exceptions anymore.
    A question, is there a reason for this behavior?

  • Exception event subprocess handling

    We have a question around an exception event subprocess. In reading Oracle Fusion Middleware Modeling and Implementation Guide for Oracle Business Process Management 11g Release 1 (11.1.1.5.0) it indicates in section 19.5.6 that we can catch all system exceptions. Earlier in that section 19.4.1 point 4, second bullet point, it states “(w)hen the instance completes the exception handling flow, the process ends.” Our question is does the instance just end in the exception subprocess or does it route back to the task that threw the exception?
    We would like to have events throw an exception into the exception subprocess and after the subprocess ends route back to the task that threw the exception. In 10g this was the case and we are checking to see if that is true in 11g or how we need to handle this scenario.

    I do not understand your response. I have an event subprocess that catches all system and business errors. Then in that process I have a (Start Catch Error)->(user activity) ->??? What do I put as my end event? If I put a message end it is asking for the start message, which I don't have. What I want is when the admin had fixed the error, and they click accept/ok and submit, I want the instance to go back to where the error happened. For example, I have a sales quote process like this: (start)->(user activity)->(service activity)->(user activity)->(end). And for sake of this example my service activity does a database lookup, but the database is down so a system error is generated. So in this case my event subprocess catches the error and the admin fixes the error and submits. How do I get the instance to go back to my service activity. And yes in this simple case a i would have used a boundary event but for the sake of this example assume I have say 50 service activities and I don't want to put a boundary even on each one.
    Thoughts/suggestions?

  • Add-On [X] failed with exception; Event Type:16

    Hi,
      I'm currently trying to create a SAP B1 Add-On using C# (Framework 3.5/VS 2008).  I've done several VB.Net Add-Ons in the past but this is the first one I try to create one in C#.
      Using the SDK code examples, I've managed to create an Add-On that correctly connects to UI and DI (I can create a sub-menu, set event filters and add some usertables and userfields).  My sub-menu opens an XML based form in SAP B1.  The first time I click on the sub-menu, my form is correctly shown.  But immediately after, I get the following error in the message bar at the bottom :
      Add-On [X] failed with exception; Event Type:16, in which [X] is a number (like 90003), incrementing each time I stop the Add-On in Visual Studio and restart it.
      After this message occurs, I cannot display another instance of the window using the sub-menu.  In fact, it seems that all Add-On activity (button click, event trapping) is disabled or ineffective.  The Add-On still is running in the process tree, but no response.  Only the "X" is working on the created form to close it.
      I've run some tests on the code and I realized that this is happening on XML based forms (using the LoadBatchActions command to load the form) and the FormCreationParams class to create a simple form.  If I put the form creation line code in comments, my Add-On still runs (I can trap events on the sub-menu click) ; I can click multiple times on the menu without a problem  But as soon as I create a form, it stops responding.
    It also seems that as soon as I click on another menu to open a system form, the same error occurs. If I comment the form creation line code, again I can click as often as I want without getting this error message
      Can anyone help me on this one ?  I can post some code depending of what you may need to check this.
      Thanks !

    Sorry, I've just found the problem ; it was caused by an unhanded exception !
    Thanks !

  • Get exception event properties for add them in an error e-mail

    Hello,
    I made a process with Workbench ES that uses a GeneratePDFService service (CreatePDF operation) which convert TIFF files into PDF files.
    I've used an exception event to handle each exception that can be caught : SystemException, ConversionException, InvalidParameterException and FileFormatNotSupportedException.
    I have configured each exception event as following :
    - No filter
    - Callback - Process Data Map :
    /process_data/@exceptionName = /Exception/FaultName
    /process_data/@exceptionSource = /Exception/FaultSource
    /process_data/@exceptionMessage = /Exception/FaultMessage
    Where exceptionName, exceptionSource and exceptionMessage are process string variables (not input, output or required variables).
    I have linked an EmailService service (Send With Document operation) on Exception events output and have used these variables in my body e-mail content as following :
    Exception : {$ /process_data/@exceptionName $}
    Exception source : {$ /process_data/@exceptionSource $}
    Exception message : {$ /process_data/@exceptionMessage $}
    So the problem is that there is blank instead of my variable value in my e-mail !
    Can somebody help me to solve this issue? Thanks

    Hi all,
    I am trying to do the same thing, and my process works when I have set the variables as input.
    However I would like to have more info on which process that exception comes from, the stack trace and so on.
    How can I obtain these values?
    Sincerely
    Kim

  • Abap XSLT Exception block messages in SMQ2

    Hello Community,
    I have a XSLT ABAP transformation calling some ABAP objects and it's working well. I just need to handle some applications exceptions.
    I wrote an ABAP Class that raise an exception in this way:
    RAISE EXCEPTION TYPE cx_mapping_fault
            EXPORTING
              error_text = l_error.
    The problem is that the message appears canceled in SMQ2 and I need to show the error status in the Integration Engine
    I have tried with the <xsl:message>:
    <xsl:message terminate="yes">Error</xsl:message>
    But it didn't work. Exception isn't thrown in the Integration Engine. The message status is processed successfully.
    Your help would be appreciated.
    Regards,
    Yuván>

    Hello VJ,
    Thanks for your answer. I'm not using BPM in this scenario. I don't understand why messages that throw some exception in XSLT ABAP lock SMQ2. Because this doesn't happen when I use an ABAP-CLASS or message mapping as mapping programs. The lock is just using XSLT ABAP.
    Is this normal...?....is there anyway to avoid the lock and change the status to error in the integration engine..?
    Regards.
    Yuvan,

  • ABAP OO Exception Class based processing

    Hi there,
    Note: In going forward with SAP WAS 6.20, one can handle exceptions using exception-class based handling using RAISE EXCEPTION TYPE abc and then CATCHing it in TRY/ ENDTRY block. Standard method like GET_TEXT can be used to get the text of the exception raised.
    Question: If I know the EXCEPTION CLASS and Exception ID of my exception class, is it possible to get the exception text directly from the repository without creating the exception class object?
    E.g. Exception class is CX_MY_SECRET_ID
    and Exception IDs for this class are
    ID_NOT_FOUND,
    ID_EXPIRED,
    ID_IS_FOR_SPECIAL_ACCESS
    E.g. last two exception IDs are my warning conditions, and if such conditions are encountered, all I want to do is collect the warning messages. Whereas first exception ID condition (i.e. ID_NOT_FOUND) is an error for me, in which I have pass the exception back to the calling program. E.g. the source code is like this:
    PERFORM.......
    If ID is not found
       RAISE EXCEPTION TYPE ZCX_MY_SECRET_ID
               EXPORTING TEXT_ID = 'ID_NOT_FOUND'.
    else if ID has expired
       ...... then do I have to first raise the exception like raised above and CATCH it before I can get its text? or can I get the exception text directly without raising the exception first (as I know i have to retrieve the text of ZCX_MY_SECRET_ID exception class for Exception ID ID_EXPIRED)?
    In other words, if a certain condition is warning for my program, can I get the condition for that exception (from exception class based on exception class name and exception ID), or do I have to RAISE it first explicitely and then CATCH it immediately and execute GET_TEXT to get its text?
    Thanks very much!

    Hello Chetan,
    in basic the raise exception type xxx creates an exception object and aborts normal execution continuing in the enclosing try block.
    The Abap runtime contains some optimizations regarding the try block has an 'into xxx' clause. But as long you use the same exception you cant take benefit from this.
    As far I understand your problem you have two different kind of severities. So I would use 2 differnt exception classes (maybe derived from a common parent type, or one from the other).
    So both the code which throws the exception and the one which catches it are aware of the different semantic.
    Kind Regards
    Klaus

  • A failure occured while importing Java SSO ticket certificate in ABAP stack Exception : FOREIGN_ENQUEUE_LOCK

    Dear All,
    We have completed the fresh installation of Soman7.1.
    Now , We are doing the "Configuration of the Solman" and we are in the Step "Basic configuration ".
    SID:        SMI
    Hostname: Solmantrg
    Solman version: 7.1
    The SSO Setup is failing with below error.
    Message :
    A failure occured while connecting to ABAP stack on solmantrg.thetimes.co.in sys=01 client=001 user=null. Details : 'user' missing
    Details of the Log
    Found SID for SSO ACL entry : SMI
    Found login.ticket_client for SSO ACL entry : 000
    The Read entry permission on TicketKeystore/SAPLogonTicketKeypair-cert was given to sap.com/tc~webadministrator~solmandiag/servlet_jsp/smd/root/WEB-INF/lib/SetupLib.jar
    The TicketKeystore/SAPLogonTicketKeypair-cert was succesfully read (619 bytes)
    ABAP SSO ticket certificate of SMI was imported in ABAP PSE of solmantrg.thetimes.co.in (client 001)
    The ABAP SSO ticket certificate was successfully imported in ABAP System PSE, and the ACL updated accordingly (SID=SMI LoginTicketClient=001)
    A failure occured while importing Java SSO ticket certificate in ABAP stack
    !! Exception : FOREIGN_ENQUEUE_LOCK(Abap cause=SOLMAN_ADMINE_TABLEE)
    The ABAP instance profile contains the parameter : login/accept_sso2_ticket=1
    The SSO ticket Certificate <CN=SMI> has been successfully imported into Java Keystore
    The com.sap.security.core.server.jaas.EvaluateTicketLoginModule already contained the entry : trustedsys=SMI, 001 trustediss=CN=SMI trusteddn=CN=SMI
    The Authentication template for component sap.com/SQLTrace*OpenSQLMonitors was already set to ticket
    The Authentication template for component sap.com/SQLTrace*SQLTrace was already set to ticket
    The Authentication template for component sap.com/tc~monitoring~systeminfo*monitoring was already set to ticket
    The Authentication template for component sap.com/tc~monitoring~systeminfo*sap_monitoring was already set to ticket
    The Authentication template for component sap.com/com.sap.security.core.admin*useradmin was already set to ticket
    The Authentication template for component sap.com/tc~webadministrator~solmandiag*smd was already set to ticket
    The Authentication template for component sap.com/tc~smd~e2etraceupload*E2EClientTraceUploadW was already set to ticket
    The com.sap.security.core.server.jaas.EvaluateAssertionTicketLoginModule already contained the entry : trustedsys=SMI, 001 trustediss=CN=SMI trusteddn=CN=SMI
    The Authentication template for component sap.com/tc~smd~EemAdminGateway*EemAdmin_Config1 has been set to evaluate_assertion_ticket
    The Login Module BasicPasswordLoginModule was added to the security component sap.com/tc~smd~EemAdminGateway*EemAdmin_Config1
    A failure occured while connecting to ABAP stack on solmantrg.thetimes.co.in sys=01 client=001 user=null
    !! Exception : 'user' missing
    The ABAP instance profile contains the parameter : login/create_sso2_ticket=2
      Exception
    com.sap.mw.jco.JCO$AbapException: (126) FOREIGN_ENQUEUE_LOCK: FOREIGN_ENQUEUE_LOCK
    at com.sap.mw.jco.MiddlewareJRfc$Client.execute(MiddlewareJRfc.java:1512)
    at com.sap.mw.jco.JCO$Client.execute(JCO.java:3937)
    at com.sap.mw.jco.JCO$Client.execute(JCO.java:3570)
    at com.sap.sup.admin.setup.AbapSysRfcAdapter.addTrustedIssuer(AbapSysRfcAdapter.java:276)
    at com.sap.sup.admin.setup.AbapSysRfcAdapter.addTrustedIssuer(AbapSysRfcAdapter.java:249)
    at com.sap.sup.admin.setup.ManagingServices.setupDualStackSSO(ManagingServices.java:752)
    at com.sap.sup.admin.setup.SetupStep.runExec(SetupStep.java:564)
    at com.sap.sup.admin.setup.SetupStep.execute(SetupStep.java:445)
    at com.sap.smd.agent.plugins.remotesetup.SapInstance.setup(SapInstance.java:674)
    at com.sap.sup.admin.setup.ws.SetupWrapper._diagSetup(SetupWrapper.java:279)
    at com.sap.sup.admin.setup.ws.SetupWrapper.diagSetup(SetupWrapper.java:21)
    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:331)
    at com.sap.engine.services.webservices.runtime.JavaClassImplementationContainer.invokeMethod(JavaClassImplementationContainer.java:76)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:174)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:81)
    at com.sap.engine.services.webservices.runtime.servlet.ServletDispatcherImpl.doPost(ServletDispatcherImpl.java:90)
    at SoapServlet.doPost(SoapServlet.java:51)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1060)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
    at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
    at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
    at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
    at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
    at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)
    at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)
    ========================
    com.sap.mw.jco.JCO$Exception: (101) RFC_ERROR_PROGRAM: 'user' missing
    at com.sap.mw.jco.MiddlewareJRfc.generateJCoException(MiddlewareJRfc.java:518)
    at com.sap.mw.jco.MiddlewareJRfc$Client.connect(MiddlewareJRfc.java:1087)
    at com.sap.mw.jco.JCO$Client.connect(JCO.java:3310)
    at com.sap.sup.admin.setup.CommonServices.getJcoClient(CommonServices.java:773)
    at com.sap.sup.admin.setup.CommonServices.getJcoClient(CommonServices.java:722)
    at com.sap.sup.admin.setup.SolManRfcAdapter.getJ2eeSsoSettings(SolManRfcAdapter.java:649)
    at com.sap.sup.admin.setup.ManagingServices.updateSSOfromURLrepository(ManagingServices.java:790)
    at com.sap.sup.admin.setup.ManagingServices.setupDualStackSSO(ManagingServices.java:773)
    at com.sap.sup.admin.setup.SetupStep.runExec(SetupStep.java:564)
    at com.sap.sup.admin.setup.SetupStep.execute(SetupStep.java:445)
    at com.sap.smd.agent.plugins.remotesetup.SapInstance.setup(SapInstance.java:674)
    at com.sap.sup.admin.setup.ws.SetupWrapper._diagSetup(SetupWrapper.java:279)
    at com.sap.sup.admin.setup.ws.SetupWrapper.diagSetup(SetupWrapper.java:21)
    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:331)
    at com.sap.engine.services.webservices.runtime.JavaClassImplementationContainer.invokeMethod(JavaClassImplementationContainer.java:76)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:174)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:81)
    at com.sap.engine.services.webservices.runtime.servlet.ServletDispatcherImpl.doPost(ServletDispatcherImpl.java:90)
    at SoapServlet.doPost(SoapServlet.java:51)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1060)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
    at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
    at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
    at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
    at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
    at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)
    at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)
    In strustsso2, cerficate date is valid only.
    kindly help us to fix this SSO_Setup issue
    Thanks and Regards,
    Gayathri.K

    Hi ,
    Thanks for the above reply.
    I have executed the Step 2.3 AND 2.4 and i started the SSO Setup again. Still i am getting below error
    Message
    A failure occured while importing Java SSO ticket certificate in ABAP stack
    Details Of the Log
    Found SID for SSO ACL entry : SMI
    Found login.ticket_client for SSO ACL entry : 000
    The Read entry permission on TicketKeystore/SAPLogonTicketKeypair-cert was given to sap.com/tc~webadministrator~solmandiag/servlet_jsp/smd/root/WEB-INF/lib/SetupLib.jar
    The TicketKeystore/SAPLogonTicketKeypair-cert was succesfully read (619 bytes)
    ABAP SSO ticket certificate of SMI was imported in ABAP PSE of solmantrg (client 001)
    The ABAP SSO ticket certificate was successfully imported in ABAP System PSE, and the ACL updated accordingly (SID=SMI LoginTicketClient=001)
    A failure occured while importing Java SSO ticket certificate in ABAP stack
    !! Exception : FOREIGN_ENQUEUE_LOCK(Abap cause=SOLMAN_ADMINE_TABLEE)
    The ABAP instance profile contains the parameter : login/accept_sso2_ticket=1
    The SSO ticket Certificate <CN=SMI> has been successfully imported into Java Keystore
    The com.sap.security.core.server.jaas.EvaluateTicketLoginModule already contained the entry : trustedsys=SMI, 001 trustediss=CN=SMI trusteddn=CN=SMI
    The Authentication template for component sap.com/SQLTrace*OpenSQLMonitors was already set to ticket
    The Authentication template for component sap.com/SQLTrace*SQLTrace was already set to ticket
    The Authentication template for component sap.com/tc~monitoring~systeminfo*monitoring was already set to ticket
    The Authentication template for component sap.com/tc~monitoring~systeminfo*sap_monitoring was already set to ticket
    The Authentication template for component sap.com/com.sap.security.core.admin*useradmin was already set to ticket
    The Authentication template for component sap.com/tc~webadministrator~solmandiag*smd was already set to ticket
    The Authentication template for component sap.com/tc~smd~e2etraceupload*E2EClientTraceUploadW was already set to ticket
    The com.sap.security.core.server.jaas.EvaluateAssertionTicketLoginModule already contained the entry : trustedsys=SMI, 001 trustediss=CN=SMI trusteddn=CN=SMI
    The Authentication template for component sap.com/tc~smd~EemAdminGateway*EemAdmin_Config1 has been set to evaluate_assertion_ticket
    The Login Module BasicPasswordLoginModule was added to the security component sap.com/tc~smd~EemAdminGateway*EemAdmin_Config1
    The ABAP instance profile contains the parameter : login/create_sso2_ticket=2
    Exception
    com.sap.mw.jco.JCO$AbapException: (126) FOREIGN_ENQUEUE_LOCK: FOREIGN_ENQUEUE_LOCK
    at com.sap.mw.jco.MiddlewareJRfc$Client.execute(MiddlewareJRfc.java:1512)
    at com.sap.mw.jco.JCO$Client.execute(JCO.java:3937)
    at com.sap.mw.jco.JCO$Client.execute(JCO.java:3570)
    at com.sap.sup.admin.setup.AbapSysRfcAdapter.addTrustedIssuer(AbapSysRfcAdapter.java:276)
    at com.sap.sup.admin.setup.AbapSysRfcAdapter.addTrustedIssuer(AbapSysRfcAdapter.java:249)
    at com.sap.sup.admin.setup.ManagingServices.setupDualStackSSO(ManagingServices.java:752)
    at com.sap.sup.admin.setup.SetupStep.runExec(SetupStep.java:564)
    at com.sap.sup.admin.setup.SetupStep.execute(SetupStep.java:445)
    at com.sap.smd.agent.plugins.remotesetup.SapInstance.setup(SapInstance.java:674)
    at com.sap.sup.admin.setup.ws.SetupWrapper._diagSetup(SetupWrapper.java:279)
    at com.sap.sup.admin.setup.ws.SetupWrapper.diagSetup(SetupWrapper.java:21)
    at sun.reflect.GeneratedMethodAccessor2202.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:331)
    at com.sap.engine.services.webservices.runtime.JavaClassImplementationContainer.invokeMethod(JavaClassImplementationContainer.java:76)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:174)
    at com.sap.engine.services.webservices.runtime.RuntimeProcessor.process(RuntimeProcessor.java:81)
    at com.sap.engine.services.webservices.runtime.servlet.ServletDispatcherImpl.doPost(ServletDispatcherImpl.java:90)
    at SoapServlet.doPost(SoapServlet.java:51)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
    at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1060)
    at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
    at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
    at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
    at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
    at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
    at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)
    at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)
    Also , i have checked the note # 1008474   Diagnostics Setup Wizard uses wrong ABAP client.
    As mentioned in above note, i have checked in visual admin all settings are maintained correctly.
    RFC destination WEBADMIN & SOLMANDIAG is also working fine.
    please tel why i am getting Foreign Enquelock
    Regards,
    Gayathri.K

  • ABAP Proxy Exception

    Hello everybody i have this error in my sxmb_moni of xi for a abap proxy server receiver:
      <?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>XIProxy</SAP:Category>
      <SAP:Code area="ABAP">DYNAMIC_CALL_FAILURE</SAP:Code>
      <SAP:P1>UNCAUGHT_EXCEPTION</SAP:P1>
      <SAP:P2>ZFUS_CL_MI_FMGOB_CAT_FONDOS_C1</SAP:P2>
      <SAP:P3>EXECUTE_SYNCHRONOUS</SAP:P3>
      <SAP:P4 />
      <SAP:AdditionalText>Unable to execute the dynamic application call (kernel error ID UNCAUGHT_EXCEPTION, class ZFUS_CL_MI_FMGOB_CAT_FONDOS_C1, method EXECUTE_SYNCHRONOUS)</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack />
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    any suggestions?
    Regards,
    Julio Cesar

    Hi
    Below is the full details of above links
    For link 4196517?
    Q) Hi All,
    I have got a requirement to raise an exception from existing ABAP Proxy depending on condition. XI consultant created a fault messge type and attached to the inbound interface message type. I have regenerated the ABAP proxy but I cant find any thing in excpetion tab to raise exception.
    Please let me know the solution for this.
    Answers : 1) Go to Sproxy .
    Select the message interface for which you generated the proxy.
    Click on the Structure tab. Do you see any Exception Class generated for fault message ?
    2) Just follow all the steps defined in the below Blog and you will find the solution.
    /people/shabarish.vijayakumar/blog/2006/11/02/fault-message-types--a-demo-part-1
    3) I can't find any exception class there in 'Structure' tab. what might be the problem.
    4) In SProxy ..under the Message Interface you will see Fault Message Type.
    Click on Fault Message Type and check if you can see the fault message type created by xi consultant.
    Also ask your xi team to login to IR and re-activate the interface.
    5) I can't find any fault message type under Fault Message Type. I will ask my XI consultant to reactivate the interface.
    Is this the only problem for this or is htere any other reason for not finding this fault message type in SPROXY.
    6) Ideally the fault message type should be visible unless he has defined Software Dependencies and using MT from some other SC.
    Even if the fault message type is not visible everything could be all right.
    Ask him to check if he selected the fault message type while activating the interface.
    Do update us when you get a reply from ur xi team.
    7) I have checked with XI admin, he said that he created fault message types in Development Xi but R/3 Development refers to Production XI system in exchange profiles. He asked me to change it to XI development in exhange profile settings. So I am searching info on how to set exchange profiles.
    8) The following link will guide you ..
    http://help.sap.com/saphelp_nw04s/helpdata/en/c9/7a1041ebf0f06fe10000000a1550b0/frameset.htm
    I dont think we need to do any changes in Exchange Profile for proxy communication.
    Changing the RFC Destinations (in your R/3 system)- LCRSAPRFC & SAPSLDAPI should solve your problem.
    II) For Link :4147406?
    Q) Hi All,
    We have an ABAP Proxy implemented for posting goods movement and it is calling BAPI function module to post good movement. We have got a requirement that if BAPI returns any error, this error message send back to SAP XI.
    data call proxy
    Legacy -
    > XI -
    > SAP R/3(call bapi)
    <----
    error message
    Please let me know how to send the message back to XI.
    Answers: 1) Refer the following
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy - ABAP Proxy to File
    /people/prateek.shah/blog/2005/06/14/file-to-r3-via-abap-proxy - File to ABAP Proxy
    2) you can utilize the fault messages for such an usage -
    Ref:
    Fault messages -
    /people/shabarish.vijayakumar/blog/2006/11/02/fault-message-types--a-demo-part-1
    Handling Web Service SOAP Fault Responses in SAP NetWeaver XI -
    /people/jin.shin/blog/2007/05/21/handling-web-service-soap-fault-responses-in-sap-netweaver-xi
    3) You have to do Fault message implementation in this case...
    A no. of exception will be there.For any error proxy will catch the exception and will write it in the fault message...so....from r/3 response will go to Xi as Fault message response in case any error/exception occours......
    have look here...
    Fault message implementation.
    /people/shabarish.vijayakumar/blog/2006/11/02/fault-message-types--a-demo-part-1
    4) Please go through it is very useful.
    /people/krishna.moorthyp/blog/2005/12/23/monitoring-for-processed-xml-messages-in-abap-proxy --Monitoring for Processed XML messages in ABAP Proxy
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy --ABAP Proxies in XI(Client Proxy)
    /people/sap.user72/blog/2005/12/29/service-enable-your-sap-application-component --- Service Enable Your SAP Application Component
    5) the file adapter can work only asynchronous, so you cant have a response. You should build two asynchronous messages. File -> proxy inbound and after the bapi call an outbound proxy is called which is sending a second messge to the file adapter.
    6) you can define a synchronous scenario which will include request/response messages.
    send the response back to XI.
    the file adapter supports BE QoS.
    http://help.sap.com/saphelp_nw04s/helpdata/en/0d/5ab43b274a960de10000000a114084/frameset.htm
    7)I have an interface Z_stock_move(message interface(inbound)) and class z_STOCK_MOVE in that. I have clicked exception tab but not able to add exception there as its not enabled for change.
    Please let me know how to add the exception to an existing abap proxy.so that i can raise an exception when bapi call to goods movenment returns errors.
    Might be useful to U.

  • Abap Proxy exception Handling

    Hi guys,
    I've implemented the following scenario:
    BPM Process where I've got a async receive (from a file receiver), a sync send (to an ABAP PROXY) and a send async (to a file sender).
    The scenario is working great, I've catched 'Communication exceptions', and the proxy contemplates the necessary exception throwers too, but I'm now trying to Handle one specific exception. Imagine you force a dump, with a divide by zero in the proxy code...the proxy will dump and the XI gets a mapping exception (like is supposed to).
    The exception is:
    <SAP:Code area="MAPPING">EXCEPTION_DURING_EXECUTE</SAP:Code>
    <SAP:P2>com.sap.aii.utilxi.misc.api.BaseRuntimeException</SAP:P2>
    <SAP:P3>RuntimeException in Message-Mapping transformatio~</SAP:P3>
    The thing is, I want to catch this exception on the mapping and handle it, so the bpm process sends the handle response with the file sender.
    I've looked to Alessandro Guarneri blog, but it's a little bit different, because I don't want to throw an exception but I'd like to handle it....
    Can you guys help me with this question?

    Hi Vijaya,
    I was able to catch the exception like you said, on the proxy side.
    I'm trying to conceive some real and feasible dumps scenarios and for that I'm forcing dumps, and catching exceptions. Divisions by zero was one of the examples.
    For division by zero I was able to catch it with a cx_sy_no_handler exception, but I've another example which I'm not being able to catch it.
    I'm sendind an message e001(zisa), which will exit automatically from the function module. Am I able to catch that message? Meaning, can I catch it and treat it, instead of the system exiting the function and showing the corresponding message?Is there any cx_* ?
    Even better, on sxmb_moni I get:
    <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="INTERNAL">HTTP_RESP_STATUS_CODE_NOT_OK</SAP:Code>
      <SAP:P1>500</SAP:P1>
      <SAP:P2>Internal Server Error</SAP:P2>
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText><html> <body> <H1> 500 SAP Internal Server Error </H1> <B> Error message: </B> O centro nao existe ou nao esta preenchido. ( <B> type of termination: </B> ERROR_MESSAGE_STATE ) <BR /> </body> </html></SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>HTTP response contains status code 500 with the description Internal Server Error Error when sending by HTTP (error code: 500, error text: Internal Server Error)</SAP:Stack>
      <SAP:Retry>N</SAP:Retry>
      </SAP:Error>
    So, the SOAP adapter receives something. If it's not possible to catch this exception on the abap proxy side, can I catch and map that soap adapter error text on the BPM side?
    Thanks a lot for all of your attention

Maybe you are looking for