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.



#Automation


#Applicationintegration
#webMethods
#Integration
 View Only
  • 1.  Sharing client state C Api

    Posted 07/16/03 05:08 PM

    Hi all. I am using webmethod 4.1 and the C Api. The OS is HP-UX 11.

    I am trying to set a client share state broker and I can’t do it.

    I am doing the following:

    bcd=awNewBrokerConnectionDescriptor();
    b = 1;
    awSetDescriptionConnectionShare(bcd,b);
    awNewBrokerClient(szBrokerName,szBrokerHost,szClientName,
    szClientGroup,szApplName,bcd,&c);

    and when I try to set up the share limits, a NO PERMISSION ERROR arises. If I call awGetClientInfoById to retrieve the BrokerClientInfo structure, the value I get of can_share_state field is 0.

    Am I missing something??

    Thanks.

    (Sorry if it is a basic question. I am newbie with webMethods)


    #Integration-Server-and-ESB
    #webMethods
    #broker
    #Universal-Messaging-Broker


  • 2.  RE: Sharing client state C Api

    Posted 07/16/03 05:41 PM

    Shared state must be set when the client queue on the broker is first created. If the client queue was created on a previous run of the code you listed but didn’t have the awSetDescriptionConnectionShare turned on, you won’t be able to change it. You’ll need to destroy the queue (either via API or with the Administrator tool) and recreate it.


    #Universal-Messaging-Broker
    #broker
    #webMethods
    #Integration-Server-and-ESB


  • 3.  RE: Sharing client state C Api

    Posted 07/16/03 05:51 PM

    Thank you for you reply, Rob.

    I think I can assure that the queue is not created in a previous run by changing the value of the szClientName and using a name that was not previously used, am I right?

    Well, I changed the client name parameter (using an unused name) and the error (NO_PERMISSION) raised again. Does my client group need any special permision to do that? Does the broker need any particular setting to allow sharing state between client?

    Thank you.


    #webMethods
    #Integration-Server-and-ESB
    #broker
    #Universal-Messaging-Broker


  • 4.  RE: Sharing client state C Api

    Posted 07/16/03 06:42 PM

    Couple of items of note:

    awSetDescriptorConnectionShare sets the connection sharing, not the client state sharing. Use the awSetDescriptorStateShare function to share state. Keep in mind that shared state clients are not useful unless they are receiving events from more than one publisher.

    I think the permission error is probably related to something else. AW_ERROR_NO_PERMISSION means permission to join the client_group was denied. Is SSL involved at all? Is the error returned by the awNewBrokerClient call? Or is it later during a subscription attempt? Perhaps posting additional code snippets would reveal something.


    #Universal-Messaging-Broker
    #broker
    #Integration-Server-and-ESB
    #webMethods


  • 5.  RE: Sharing client state C Api

    Posted 07/16/03 07:02 PM

    Rob, thanks a lot four your time. You make me find the solution. I missed the awSetDescriptorStateShare.

    Now it is working fine.

    Thank you again.


    #webMethods
    #broker
    #Integration-Server-and-ESB
    #Universal-Messaging-Broker


  • 6.  RE: Sharing client state C Api

    Posted 04/06/09 05:36 AM

    Hi,Bartoalvarez:
    Now,I want to use the C API on wM7.1.2,but failed,so could you please share your code to me,tks,and my email is whg5338680@163.com ,tks in advance.


    #Integration-Server-and-ESB
    #webMethods
    #broker
    #Universal-Messaging-Broker