Workflow Runtime Event Queue Data

Does a script exist to cleanup the runtime data in the WF Event queue's ???

Actually, this can be done automatically by setting the Queue Table retention time. There is DBMS_AQADM.ALTER_QUEUE/ALTER_QUEUE_TABLE API to alter the amount of time processed messages are retained in the queue.

Similar Messages

  • Workflow in event queue based on a deleted object

    Hi all,
    I'm facing a problem with a workflow that goes to the event queue, meanwhile the object is deleted and then the WF is released from the event queue in Error. The WF is based on the BO BUS2032 (sales order).
    Here are the steps:
    1-Sales order created or changed --> event generated --> WF linked to that event goes to event queue
    2-Meanwhile the WF is the event queue waiting to be released, the sales order is deleted
    3-The WF is released from the event queue but in ERROR status (this is because the BO instance does not exist anymore)
    In this scenario, is there a way to end the WF with CANCELLED status instead of ERROR? is there anyy FM or exit you know ehere I can check if the BO still exists once the WF is released from the event queue?
    Thanks!!!!!

    Some questions/options:
    1) How/why does the WF go into an error exactly? Does it try to complete the first step? What if you put a condition step as a first step in the WF and check whether the object is initial and if it is, then cancel the workflow.
    2) How about deleting the event from the queue from some user-exit/badi in the sales order deletion. If I remember correctly the events when queued are in table SWEQUEUE. Probably you can find some function to delete events from the queue. Take a look for example function SWE_EVENT_QUEUE_DELETE to see the idea. Or take a look into transaction SWEAD. There you can delete events from queue. Check what it does and do the same in your code.
    3) Is this really a big problem? Are there so many sales orders deleted?
    In general I think that the whole event queue seems to many times cause lots of problems (the event queue job disappears, WFs will not get started, and whatever.). I try to avoid using it.
    Regards,
    Karri

  • Integration Event Queue Fields

    Getting starting on an integration project between Siebel OnPremise 8.1 HOR and OnDemand and I am seeing some conflicting information in the documentation versus what really happens with fields of data in the Event Queue.
    I cannot remember exactly where but I came across documentation indicating that not all "tracked fields" may appear in a given integration queue event. It seemed to indicate that only the user key data and system fields like operation, created, created by etc would be recorded in the queue.
    However in testing I have found that all my tracked fields are appearing in the queue except for custom fields and custom fields do appear when that field changes. I done only very limited testing but wanted to get others input on how this works.
    If all the data I need will be in the queue then I can just map that data to my OnPremise data and apply the update.
    If I should only expect a small subset of data then I'll have to use the event queue data to query the full record and then apply an update from the query result.
    Thoughts?

    Two things need to happen for a Workflow to trigger the creation of an Integration Event:
    1) The Workflow condition (if a condition exists) needs to evaluate to true.
    2) One of the "tracked" fields need to be udpated.
    An Event may be missed when the Workflow condtion is true but no tracked field is updated. When you configure Integration Event fields to be tracked, what you are doing is telling the system to create an Event record if one of the tracked fields has been modified. A common misconception is that the tracking fields are the fields that will be returned in the Event record, this is not the case, only a few unconfigurable audit fields are returned in an Event record.

  • Data flow error in workflow runtime

    I have many workflow's (standard or not) that present error in runtime.
    The data flow between container task and container workflow doesn't work if one element is empty, but this element not is mandatory.
    List of errors:
    - ParForEach 000000
    - Object FLOWITEM method EXECUTE cannot be executed
    - and others...
    These errors occurs if <b>some information</b> of the workflow container that is used in <b>some data flow</b> (binding definition) will be <b>empty</b>, the workflow will present error in the start.
    List of specific error:
    Error during result processing of work item 000000395235
    Error when processing node '0000000083' (ParForEach index 000000)
    Error when creating a component of type 'Etapa'
    Error when creating a work item
    Error within method CL_SWF_RUN_WIM_BATCH->_CREATE_WORKITEM_CONTAINER
    Source (expression '&STANDARDMATERIAL.MAILCENTRAL&') of binding assignment is not available
    Source (expression '&STANDARDMATERIAL.MAILCENTRAL&') of binding assignment is not available
    Error in the evaluation of expression '&STANDARDMATERIAL<???>.MAILCENTRAL&' for item '17'
    Error when determining attribute 'MAILCENTRAL' of object instance '[BO.BUS1001006.000000000010279
    Error in the evaluation of expression '&STANDARDMATERIAL<???>.MAILCENTRAL&' for item '17'
    Error when determining attribute 'MAILCENTRAL' of object instance '[BO.BUS1001006.000000000010279
    These errors did not occur before the Support Package SAPKB70012.

    Hello Arghadip,
    Yes, the attribute is empty and not is mandatory. These error occur in Standard Workflow SAP and Customer Workflow (my developments).
    These error occurs if <b>some information</b> (attribute) of the workflow container that is used in <b>some data flow</b> (binding definition) will be empty.
    Example: I have a SendMail step in my workflow, and the email address is one attribute from business object. Before this step (sendmail), when the previous step is concluded and if the attribute (mail address) is empty, the error ocurr's.
    I believe that the email would not have to be sent for nobody, and not ocurr's an error. I think that these problem is one support package error.
    Thanks,
    Kleber

  • Events remained in Event Queue.

    Hi All.
    We have a situation in which the triggering event for a workflow reamined in the "Event Queue".
    The status of the event is "Waiting because of e", which is not very descriptive.
    This happenend on a certain date, same events are successfully triggered before and after this date.
    What could be the reason for the same.

    Check this link
    Re: Event is in Waiting state.
    Thanks
    Arghadip

  • Additional event queue appearing after RMI callback

    Hi,
    I am working on a client-server applicaion in which the client passes the server a callback object so it can be notified if shared data is changed so it can refresh.
    After receiving the notification from server the processing is moved to a Runnable executed on the dispatch tread with SwingUtilities.invokeLater(Runnable).
    But a case arose in which there there seems to appear an additional event queue.
    The original event queue (Thread name is AWT-EventQueue-2) is busy. Then in a thread named "RMI TCP Connection(3)-192.168.1.4" a notification comes but it is dispatched on a thread named "AWT-EventQueue-0". But I want the notification processing happen after AWT-EventQueue-2 has finished its current task.
    How can I avoid the additonal queue creation and what wrong am I doing so it is created(Swing is single-threaded as I have read everywhere)?
    Thanks
    Mike

    I found a way to solve this but I am not sure it is good.
    I save reference to the event queue the application uses on startup and instead of
    SwingUtilities.invokeLater(changeRunnable)
    use
    systemQueue.postEvent(new java.awt.event.InvocationEvent(Toolkit.getDefaultToolkit(), changeRunnable));
    Currently that works fine and change events are dispatched synchronously to the other things happening. But I wonder if there is a chance that the system queue is substituted in runtime by another queue and my reference will become invalid.
    Mike

  • Runtime Event Setup

    I have created a EAI workflow whcih send an xml msg. to JMS Q. To tiger this workflow I have created runtime events on BC Contact WriteRecord, WriteRecordUpdated and Delete Recrod. Except Delete record other two runtime events works just fine and the xml msg is recevied by the Q.
    however, for the delete record I am getting the follwoing error
    " [1] Error invoking service 'EAI XML Converter', method 'IntObjHierToXMLDoc' at step 'Convert to XML'.(SBL-BPR-00162)
    [2] The XML hierarchy cannot be converted to an XML document.(SBL-EAI-04112)
    [3] Error writing to file reference 'C:\sia811\siebsrvr\temp\1-MMPI_0.tmp'.(SBL-EAI-50176)"
    Any clue what could be the issue ?
    Thank you.
    Edited by: 907545 on Jul 3, 2012 6:36 AM

    Hello,
    There is no such property that identifies New / Delete record as far as I recall. However, if you need to indicate to the JMS team that this is from a New / Delete record you could add another tag in your message (probably like a tag from the field of main BC), the location is for you and the JMS team to decide.
    For this you can try with Data maps if you go with making this like a field.
    Warm Regards,
    Tanmay Jain

  • Error while deleting events from the integration event queue

    I am trying to delete all the events from the integration event queue after reading it, like this (this is in Java):
            IntegrationEventWS_DeleteEvents_Input input = new IntegrationEventWS_DeleteEvents_Input();
            input.setDateTime("");
            input.setLastEventId("");
            try {
                 ((Default_Binding_IntegrationEventWS)onDemandStub).deleteEvents(input);
            } catch (Exception e) {
                 log.error("Deleting events from integration queue failed: ", e);
            }Alas, I get the following error message:
    Invalid method parameter(s): 'File Id'(SBL-ODS-50007)What does this mean? What is this mysterious "File Id" it supposedly gets? I don't see it anywhere in the SOAP message I'm sending and it isn't mentioned anywhere in the docs.
    Thanks in advance for any input.

    Dont keep this attributes null
    input.setDateTime(""); //Put a Default Time way in
    the past. Ex:"1/1/2000"
    input.setLastEventId(""); //pass the eventIdThe documentation states that those two are optional (although they are not nillable, for some reason). I tried to set the date to today, but I got the same result. Since setting a date is supposed to delete all events older than that date, I don't think setting it in the past will delete anything.

  • Error "Event Queue Overflowed​" with the "Write file to Citadel Server"

    Hello,
    I can import data from a file and I can see the data
    in the historical database without troubling.
    But I always have this error "Event Queue Overflowed", that don't perturb my data and my application (I have just this boring message).
    I have tried many things :
    - increasing the size of my input buffer (-> 1.000.000, no change) : I don't think so that it's important because I've tried with a value of 100 and anyway sometimes my application works with this small value of 100.
    - increasing the File_location tag size (-> 260). No change.
    - My write to Citadel.cfg is in the LabVIEW folder.
    Can you help me ?
    Thank you.

    Hi,
    What version of LabVIEW DSC are you using? if it is 6.1, have you applied fixes linked below.
    http://digital.ni.com/softlib.nsf/websearch/513AA4​A0BB60D10086256B48006D44B5?opendocument
    I have seen a similar issue at the link below.
    http://exchange.ni.com/servlet/ProcessRequest?RHIV​EID=101&RNAME=ViewQuestion&HOID=506500000008000000​8C640000&ECategory=LabVIEW.Datalogging+and+Supervi​sory+Control
    Please let me know if you have read it through?
    Best Regards,
    Remzi A.

  • Terminating Event to Event Queue due to Work Item Lock

    I have a dialog workflow task based on an asynchronous method defined with a terminating event.  When the user executes the work item, the method generates the terminating event (via a V2 change document) but the work item is enqueued (locked) by the same user (locked when they execute the work item from SBWP) and therefore the terminating event goes into error and is placed in the event queue.  The background job which processes the event queue does not redeliver the event so it stays in the event queue and the work item fails to complete.  Other than dequeing the work item lock myself with a function call how do I get around this catch 22?

    Hello Martin,
    Actually, the locking happens whether I have the task as asynchronous or synchronous.  The problem is the timing. If the user does not release the lock (by backing out of the dialog which is executed) prior to the terminating event attempting to enqueue and complete the work item then the event goes into error and is inserted into the event queue (and lingers there indefinitely, almost). Another issue with the asynchronous approach is that even if the user backs out of the dialog before the event actually attempts to complete the work item they will still see the work item in the inbox unless they click the refresh button when they get back to the inbox. 
    I have changed the task to synchronous but here is my scenario and another question.
    The process being workflowed is the approval of service entrysheets (similar to an invoice if you are not familiar with External Services).  In our process, there are a large number of documents being created and requiring approval by particular approvers.  It is a normal scenario for an approver to have, lets say 25 documents in his inbox awaiting approval. It was not practical for him to have to navigate back and forth between his inbox and the approval task screen.  Therefore, I give the users the option of (when executing a work item) having all the documents in his in-box (for this particular task) be presented in an approval list screen.  They can then do a mass approval of the 25 documents with 1 click and 1 navigation.  This list screen is also available to be executed outside workflow via a tcode.  So, when the user executes the mass approval (either from the inbox or outside workflow) the work items are terminated via the terminating event assigned to the approval task.
    A couple of issues remaining:
    1) Given my example of 25 work items (user executes 1 work item from in-box
    and I displayed all 25) being approved, when the user returns to the in-box, the 24
    items remain in his inbox until he clicks the refresh button since these were not actually "executed" from the workflow engines point of view.  However, these were terminated successfully because they were not "locked".
    <b>Question:</b> Is there a way (user exit?) to trigger the inbox refresh automatically.
    2) Now, the issue with the actual work item which the user executes from the inbox.  As I mentioned, the work item is locked as soon as the user executes it and is not released until they back out of the dialog or logoff.  So, here is what happens:  If the terminating event is sent before the lock is released the event is sent to the event queue.  If they then back out back to the in-box, its OK since I put some code in the SWO1 object type program (rememeber, its now synchronous) which will determine if they did the approval/rejection and the work item will complete and the event in the event queue will be deleted the next time the Event Queue Background job runs (it deletes any events for work items already in COMPLETED status). However, lets say they simply log off rather than backing up to the in-box or they don't do anything and are eventually logged off by timeout. In this case the code in the object type program to determine if the approval/rejection was done does not get executed (control does not return to the object type program) and the work item remains in "STARTED" status and remains in the users inbox and the event is in the event queue. So, now we have a work item that should be completed still sitting in the users in-box and the terminating event in the event queue. So the next time the user goes to their inbox the work item is still there.  The interesting thing is that though this may be confusing to the user, if they then attempt to execute the work item, they will get a message: "Work item currently being completed by event" (Message SWF_RUN 644) and the event sitting in the event queue gets redelivered and completes the work item.  To alleviate this problem I was thinking of adding a call to SAP_WAPI_WORKITEM_COMPLETE in the approval list screen after they do the approval but I'm guessing it wont work since it probably will try to enqueue the work item and it will still be locked. 
    Hopefully you haven't nodded off reading this rambling note...
    Thank you,
    Bob

  • KIMYONG: Outbound Workflow Notification Event Message 를 tracking하는 방법

    Purpose
    Outbound Workflow Notification Event Message 가 발송됐으나 user가 받아보지 못한경우 가 발생했으나 user
    이를 tracking하는 방법을 알아보고자 한다.
    Solution
    1. notification 이 발송될때 oracle.apps.wf.notification.send event발생한다
    event key 로 Notification ID 를 사용한다.
    2. 다음 조건에서만 The e-mail notification이 발송된다.
    i) Notification status is OPEN or CANCELED
    ii) Notification mail_status is MAIL or INVALID
    SELECT status, mail_status
    FROM wf_notifications
    WHERE notification_id = '&nid';
    iii) Recipient Role has a valid e-mail address and notification preference is in the format MAIL%
    SELECT email_address,
    nvl(WF_PREF.get_pref(name, 'MAILTYPE'),notification_preference)
    FROM wf_roles
    WHERE name = upper('&recipient_role');
    iv) Workflow Deferred Agent Listener is running
    v) Workflow Notification Mailer is running
    3. e-mail로 발송되기전 message가 2번 정지한다.
    Raised --> WF_DEFERRED Queue --> Processed by Deferred Agent Listener --> WF_NOTIFICATION_OUT Queue --> Processed by Notification Mailer and sent as e-mail
    4. oracle.apps.wf.notification.send을 dispatch 할때 error가 발생하면
    message 는WF_ERROR queue에 enqueue되고 .
    Error Agent Listener 가 WF_XML.Error_Rule 을 수행하는 oracle.apps.wf.notification.send 의
    ERROR subscription 을 dispatch합니다.
    5. notification id 와 WF_DEFERRED and WF_NOTIFICATION_OUT queue 의 message stauts 등을 확인하기 위해 $FND_TOP/sql/wfmlrdbg.sql 를 수행합니다.
    PROCESSED in WF_DEFERRED - The message is enqueued to WF_NOTIFICATION_OUT
    PROCESSED in WF_NOTIFICATION_OUT - The message is sent as e-mail
    READY in WF_DEFERRED - Check if Deferred Agent Listener is running
    READY in WF_NOTIFICATION_OUT - Check if Notification Mailer is running
    6. notification id 의 outbound XML message 를 분석합니다.
    . The wfmlrdbg.sql output provides the XML message generated by WF_XML.Generate at the time the script is run. If the original XML message used by the mailer is required to be analyzed following SQL may be used.
    SELECT tab.user_data.text_lob text_lob
    FROM applsys.aq$wf_notification_out tab
    WHERE dbms_lob.instr(tab.user_data.text_lob,'&1') > 0
    7. 필요하다면 WF_NOTIFICATION_OUT queue 를 rebuild 합니다.
    The wfntfqup.sql script rebuilds the WF_NOTIFICATION_OUT queue by dropping and recreating
    that queue, removing pending notification messages from the WF_DEFERRED queue, and
    repopulating the WF_NOTIFICATION_OUT queue from the Oracle Workflow Notification System
    tables.
    Wfntfqup.sql Version >=115.9
    If you have implemented Oracle Alert and the WF_NOTIFICATION_OUT queue contains any pending
    alert e-mail messages, those messages must be processed before the queue can be rebuilt. The
    wfntfqup.sql script checks the queue for any alert e-mail messages and, if it finds any, the
    script returns an error message that specifies how many alert e-mail messages are pending
    and indicates that these messages must be processed before the script can run.
    Wfntfqup.sql Version <= 115.8
    If you have implemented Oracle Alert and the WF_NOTIFICATION_OUT queue contains any pending
    alert e-mail messages, those messages must be processed before the queue can be rebuilt. The
    wfntfqup.sql script checks the queue for any alert e-mail messages and, if it finds any,
    exits without performing any changes.
    Stop Notification Mailer, rebuild Mailer Queue using $FND_TOP/patch/115/sql/wfntfqup.sql.
    Reference
    Note 433359.1

    Thanks for your update.
    I have checked as per the metalink doc "242941.1" . i am getting below message only for IMAP.
    *C:\prod\scripts>%AFJVAPRG% -classpath %AF_CLASSPATH% -Dprotocol=imap  -Ddbcfile=
    c:\prod\prodappl\fnd\11.5.0\secure\PROD_qlng-s-012\prod.dbc -Dserver=qlng-s-003.
    qalhatlng.int -Dport=995 -Dconnect_timeout=120 -Ddebug=Y -Daccount=oracle1@qlng
    .om -Dpassword=System123 -DdebugMailSession=Y oracle.apps.fnd.wf.mailer.Mailer
    MLRTST : oracle.apps.fnd.cp.gsc.Logger.Logger(String, int) : Logging to System.o
    ut until necessary parameters are retrieved for Logger to be properly started.
    DEBUG: getProvider() returning javax.mail.Provider[STORE,imap,com.sun.mail.imap.
    IMAPStore,Sun Microsystems, Inc]*
    Kindly suggest need to any setup in ms exchange server or firewall level.
    Thanks

  • Workflow -  runtime error

    Hi all,
    I am creating workflow for material master. When i save and excute in SWDD system shows the following error.
    Runtime Errors         MESSAGE_TYPE_X
    Date and Time          01.10.2009 13:20:51
    Short text
         The current application triggered a termination with a short dump.
    What happened?
         The current application program detected a situation which really
         should not occur. Therefore, a termination with a short dump was
         triggered on purpose by the key word MESSAGE (type X).
    Error analysis
         Short text of error message:
         Unable to read RFC destination WORKFLOW_LOCAL_300
         Long text of error message:
         Technical information about the message:
         Message class....... "SWF_RUN"
         Number.............. 617
         Variable 1.......... "WORKFLOW_LOCAL_300"
         Variable 2.......... "RFC_READ_DESTINATION_TYPE"
         Variable 3.......... "DESTINATION_NOT_EXIST"
         Variable 4.......... " "
    Trigger Location of Runtime Error
         Program                                 CL_SWF_RUN_WIM_LOCAL==========CP
         Include                                 CL_SWF_RUN_WIM_LOCAL==========CM088
         Row                                     10
         Module type                             (METHOD)
         Module Name                             IF_SWF_RUN_WIM_UTL_INTERNAL~GET_SYSTEM_USER
    Source Code Extract
    Line  SourceCde
         1 METHOD if_swf_run_wim_utl_internal~get_system_user .
         2   DATA: l_excp TYPE REF TO cx_swf_run_wim.
         3
         4   TRY.
         5       IF me->m_int_state-system_user IS INITIAL.
         6         me->m_int_state-system_user = cl_swf_run_workflow_properties=>get_rfc_destination_us
         7       ENDIF.
         8       re_user = me->m_int_state-system_user.
    Can any one please give me solution for this issue.
    Thanks in advance,
    Babu

    I thought correctly
    The RFC destination is the most important one for using workflows in any system.
    Ask someone with SAP_ALL SAP_NEW profiles to execute that action automatically. Or do it yourself if you have it.
    And you have to check the Sapna Modi Blog, because every action is explained in detail.
    Kind regards, Rob Dielemans

  • Event Queue Deadlock Error

    LabVIEW 7.1, PDA Module for Palm OS (long-time LV programmer, new to PDA module)
    I am writing an app that displays a main screen of choices via Boolean button controls.  An Event structure is used to detect ValueChange in the Booleans.  When a button is clicked, a sub-vi is called that opens the sub-vi's front panel that has data display and a couple of buttons that are also processed by an event structure.  I got a "event queue deadlocked" error message when testing.  Does this application structure violate the "single event structure in a loop" rule, even though one queue is in a sub-vi?  Must I use a state machine or some other architecture to make this work?
    Thanks,
    BevP

    A lot of time has passed but now I find the same problem and I have the solution.
    If you have an event structure you MUST show the control and indicators involved in the cases in the front panel and in the monitor of your PDA/Touchscreen device, because oterwise the event queue deadlocked error appears.
    It makes sense becasuse if you do not show them; you will never be able to call events and the aplication is going to stuck. 

  • MACOS 10.4: Solve AWT Event queue hangup

    Hi,
    I'm having trouble with the AWT eventqueu. On MacOS 10.4, using Java 5 Runtime, my applet sometimes blocks. When looking at the threadstack, the deadlock always appears in the Event Loop, dispatching an AWT event, blocking in the CGlobalCursorManager._updateCursor call. In fact the CGlobalCursorManager.findHeavyweightUnderCursor Native call.
    I already tried some workarounds:
    - overwrite the validate method of my custom AWT components. Making sure that they do not block forever. This solves the problem for events coming through the overidden component, but it has to work for every event that might trigger the GlobalCursorManager.
    I had some possible solutions for which I would like some pro's and con's in this forum:
    1. I could try to kill the event loop. Is it possible to quit the event loop and restart it from within the applet ?
    2. Can I force each AWT container to use another implementation of the validate method ?
    3. Can I set another, customized, CGlogalCursorManager ?
    4. Other possibilities ?
    Thanks in advance for all those responding.

    I think you mean that I can override the validate method for each custom UI object separately.
    That's a possibility, but I was looking for a more general solution. If possible, I would to extends one
    class. E.g. can I set another event queue ? That way, I could make a custom event queue in case of a Mac OS browser.

  • After all event queue be empty

    Hello everyone,
    I know events are added to event queue from application thread or background thread (using Platfrom.runlater() ) . but I find out when some events add to event queue , UI dosent upadate until the event queue be empty (all events be handled ). My question is what object update UI after all event handled and more information about it .
    thanks

    Hi,
    QUEUE_NOT_EMPTY--> There are incompletely processed OCS requests in the tp buffer.
    Use the following tp command to display these requests-->
    tp SHOWBUFFER <SID> -D SOURCESYSTEMS= TAG=SPAM
    You can continue processing the queue as soon as these requests have been processed completely, or deleted from the tp buffer.
    http://help.sap.com/saphelp_nw04/helpdata/en/7e/c6c2ad98a711d2b429006094b9ea64/content.htm
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCUPGOCSSPAM/BCUPGOCSSPAM.pdf
    you probably forgot to confirm last SPAM or SAINT application.
    go into SPAM and choose CONFIRM
    go into SAINT, and choose FINISH
    OR
    It appears that already some support pack update is in process. So check tcode SPAM or SAINT and see whether anything is running.If it is running wait for it or see whether it is asking for confirmation.. then u need to confirm the queue.
    Also you can go to tcode SPAM and see display/define tab and see whether anything is available over there..if you are sure u dont want to import the ones in the queue,then just delete the queue using trash icon over there..
    Regards,
    Srini Nookala

Maybe you are looking for