IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.


#TechXchangePresenter
 View Only
Expand all | Collapse all

webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

webMethods Community Member

webMethods Community MemberMon September 28, 2015 07:41 AM

webMethods Community Member

webMethods Community MemberTue September 29, 2015 07:30 AM

  • 1.  webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Thu September 24, 2015 09:12 AM

    Team,

    Need one query/help on auto - re-submission of the webMethods service: pub.monitor.serviceControl:resubmit

    We are trying to resubmit a failed service/transaction automatically, rather than manually logging into MWS and do the job.

    Scenario: A service by name sendAcknowledgement have a logic to do it’s ack job. In case if the service is getting failed, it will log an error OR a failed transaction in MWS.

    Now, we have built another service, called: resubmitACK, where we are using the service: pub.monitor.serviceControl:resubmit to perform the task. The submission will happen based on the contextID which is generated for each transaction.

    Issue:

    While running the resubmitACK service, the transactions are not getting submitted; But when we log into MWS, navigate under the service section and search for the failed transaction; then if we resubmit the data, the service gets executed successfully.


    1.JPG


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 2.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Thu September 24, 2015 09:36 AM

    What is the output of pub.monitor.service:isResubmittable when you run it by contextID?

    You can resubmit services to any Integration Server that is defined as a remote
    server in the Integration Server Administrator for the local Integration Server (that
    is, the Integration Server on which Monitor is installed). If you want to resubmit
    services on the local Integration Server, that Integration Server must be defined to
    itself as a remote server. The remote server alias you enter in the Integration Server
    Administrator must be the complete DNS name for the Integration Server (for example,
    titanium.east.webmethods.com).


    #Integration-Server-and-ESB
    #B2B-Integration
    #webMethods


  • 3.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Thu September 24, 2015 11:03 AM

    Hi,

    When the picture 1.JPG as shown below, the value is getting ture; Now as shown in the WMS pciture 2.JPG, this is the service which we are trying to submit manually from the service as shown previously using the service: pub.monitor.serviceControl:resubmit.

    But still it is not working.



    #webMethods
    #B2B-Integration
    #Integration-Server-and-ESB


  • 4.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Thu September 24, 2015 11:12 AM

    Now, as you can see, initially we are searching the transaction which are failed as shown in picture 1.JPG and as shown in picture 2.JPG there are so many failed transactions been populated.

    In our service, what we are trying to do is:

    1. get all failed transactions for a particular service
    2. populate each failed transaction information under a string inside a document and populate as many documents as the failed transactions are under a document list
    3. loop over them and based on context id, resubmit automatically.

    Picture 3 explains all.




    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods


  • 5.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Fri September 25, 2015 07:57 AM

    Can you confirm why the service failed in the first execution, due to data error or connection error?

    If data error, you have to get the current pipeline by its context id (pub.monitor.service:getPipeline) and then modify the pipeline and pass it to pub.monitor.serviceControl:resubmit

    I tried the same and it is working as expected.


    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods


  • 6.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Sat September 26, 2015 03:36 PM

    Manju, are you sure you have done right code as Mahes was able to run it successfully. Better share your code what all needed to us ( Remove org specfic Util services if any from your service ) so that we can correct if any.

    Thanks,


    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods


  • 7.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Sat September 26, 2015 03:37 PM

    Manju, are you sure you have done right code as Mahes was able to run it successfully. Better share your code what all needed to us ( Remove org specfic Util services if any from your service ) so that we can correct if any.

    Thanks,


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 8.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Sun September 27, 2015 08:51 AM

    Hi Manju,

    Can you trace your code up to the control:resubmit step and verify pipeline if in the run-time variable are getting populated properly.As in the earlier post you have mentioned you are able to manually resubmit from mws,hopes there should not be any problem with audit settings or monitor related issue.

    Also before resubmit you can use isResubmittable service to verify if the particular service is resubmittable.

    Thanks
    Baharul Islam


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 9.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Mon September 28, 2015 03:01 AM

    Hi,
    I’m also facing the issue while re-submitting from flow servie.Scenerio i tested is i created one service which divides to numbers.I ran this service giving input as 1 and 0 deliberately so that the service will be failed.Then i went mws and got the context id of this failed service.Then by using this context id i fetched the pipeline using in buile monitor service then modified the pipeline by entering a number instead of 0,then i called “pub.monitor.serviceControl:resubmit” by giving the same contextid and pipeline to it.Then i verified in MWS still i see the old failed service only.And i don;t find the service with re-submitted status.I’m attacing the code.Please correct if i’m doing any thing wrong in this scenerio.
    1Capture.JPG
    2Capture.JPG


    #Integration-Server-and-ESB
    #B2B-Integration
    #webMethods


  • 10.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Mon September 28, 2015 05:13 AM

    Mahesh – Can you please share the sample code which you have written as a few members could not able to resolve the issue.

    Thanks,


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 11.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Mon September 28, 2015 05:55 AM

    Hi Mahesh,

    Is it possible, can you please do send / post the code; Not sure where we are lost in between.

    Thank you.


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 12.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Mon September 28, 2015 07:38 AM

    Sure, attaching the code sample on request. :slight_smile:

    Make sure the remote server is correctly set as shown in screen shot Capture_1

    Run the service MonitoringServicesCodeSamples:resubmitServices with the failed context ID with the input as show in the screen shot

    After resubmission you will a new contextID see Capture_2

    MonitoringServicesCodeSamples.zip (6.53 KB)


    #Integration-Server-and-ESB
    #B2B-Integration
    #webMethods


  • 13.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit



  • 14.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Tue September 29, 2015 04:22 AM

    Thank you Mahesh sir; Well we did follow as you mentioned, it worked just fine.

    There were a small hiccup when we had to work on in multiple IS instances and multiple MWS instances. We where having a rough time in figuring out a way to submit the service w.r.t specific serverID. Now we got that, done!

    Thanks a ton. :slight_smile:


    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods


  • 15.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Tue September 29, 2015 05:46 AM

    You are welcome :slight_smile:

    @ Jack,
    Are we good now?


    #Integration-Server-and-ESB
    #webMethods
    #B2B-Integration


  • 16.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Tue September 29, 2015 07:30 AM


  • 17.  RE: webMethods - Auto Re-submission from service pub.monitor.serviceControl:resubmit

    Posted Wed October 28, 2015 04:42 AM

    Yes Mahesh…we are good now.Thanks a lot


    #B2B-Integration
    #webMethods
    #Integration-Server-and-ESB