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.

 View Only
Expand all | Collapse all

Using webM Broker as JMS Provider

  • 1.  Using webM Broker as JMS Provider

    Posted Fri December 17, 2004 12:32 AM

    One of our project requires to configure Broker as a JMS provider - this is something abs. new to me. The requirement is to have webLogic clients publishing on and subscribing to the Topics defined on the Broker JMS. I did some reading (BrokerJMS Prog Guide), it is too much to grasp and I am failing to understand all that is required to be done. If someone could guide me through the steps that need to be taken to make this work, Id be extremely grateful. Also, am I correct in my understanding that each webLogic client that needs to publish/subscribe to the Topic on Broker JMS needs to have Broker JMS installed? Does this mean that the clients will need to use Broker JMS API while publishing/subscribing the messages?

    PLEASE HELP… TIA,
    Rohit


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


  • 2.  RE: Using webM Broker as JMS Provider

    Posted Fri December 31, 2004 09:52 AM

    Rohit,

    Is your requirement to publish JMS to broker direct from a client?

    There are very good code samples that come with the webMethods installation. Browse through the examples, and you’ll be all set within no time. The code samples are located at <wmroot>\Broker\samples\BrokerJMS

    The clients do not need to have the Broker installed. Broker is the hub to which you’re going to send the JMS messages. You would need to have connectivity to the broker, broker client jars, JMS jar and client jars of any JNDI provider that you would have to use.


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


  • 3.  RE: Using webM Broker as JMS Provider

    Posted Wed January 12, 2005 03:37 AM

    Haragopal,

    Thanks for a response… I kindda figured out the stuff and made it to work. I started by using the samples, but the instructions given in the guide to install and run the samples are short of several steps because of which, I wasted a lot of time.

    For anyone who is looking for a similar solution… here’s what you need to do:

    Install the Broker JMS Provider (if not already installed) on the machine that hosts your broker.

    Install the WmJMSAdmin package (available in webM 6.1 FP 1) on IS. This package provides a GUI to not only create objects (Destinations & Connection Factories) on Broker JMS, but also binds them to the JNDI that you may want to use (the JNDI templates are available in the GUI, however, the webMethods JNDI is not a production version and is not supported by webMethods). Create Connection Factories, and Destinations using this tool.

    Besides creating and binding the objects, the WmJMSAdmin tool, also creates appropriate groups on the Broker JMS. These groups are associated with the Connection Factories (CF) and used by the clients to connect and publish messages. Clients don’t have to specify the groups… the groups are used implicitly based on the CF being used.

    Once the objects are created and bound verify them in the JNDI.

    Now you can use standard JMS Clients to publish/subscribe messages on the Destinations created on Broker JMS by looking up the Connection Factory and Destination in JNDI.

    Rohit


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


  • 4.  RE: Using webM Broker as JMS Provider

    Posted Sat March 12, 2005 02:07 AM

    I am hung up on the installation of WmJMSAdmin. I installed IS FP-2. The following folder structure exists:

    C:\webMethods61\IntegrationServer\packages\WmJMSAdmin
    –code
    ----jars
    ------jmsnaming61.jar
    ----source
    –config
    ----a6_jndi.properties
    ----jms_admin
    –resources

    However, the WmJMSAdmin package is not visible to IS or IE, and it is not listed as an inactive package.

    How do I make this package visible to IE?


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


  • 5.  RE: Using webM Broker as JMS Provider

    Posted Sun March 13, 2005 01:30 AM

    I surmounted my installation problem by uninstalling JMS, deleting its folders, and re-installing JMS and WmJMSAdmin.

    Now I need help in configuring JMS under wm. Here is my attempt at filling in the needed parameters:

    JMS Connector
    JNDI Initial Context: com.sun.jndi.fscontext.RefContextFactory (???)
    JNDI Provider Url: http://localhost:6849
    JNDI Security Principal: blank
    JNDI Security Credentials: blank
    JNDI Other Properties: blank
    Queue Connection Factory JNDI Name: ???
    JMS User: Administrator
    JMS Password: ***
    retype JMS Password: ***

    WmJMSAdmin—>Connection Factories
    Lookup Name: ???
    Connection Factory Name: ???
    Client ID: ???
    JMS Broker: broker000@localhost

    WmJMSAdmin—>Connection Factories–Create a QueueConnectionFactory
    Lookup Name: ???
    Connection Factory Name: ???
    Client ID: ???
    JMS Broker: broker000@localhost

    WmJMSAdmin—>Destinations–>Create a Queue
    Lookup Name: ???
    Queue Name: Q1
    JMS Broker: broker000@localhost

    Can anyone help fill in the blanks?


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


  • 6.  RE: Using webM Broker as JMS Provider

    Posted Mon March 14, 2005 04:04 PM

    Richard,

    I presume that you have the Broker JMS installed… You are going in the right direction… just a few things to note:

    1. com.sun.jndi.fscontext.RefContextFactory is a file system based JNDI provider ie the JNDI are stored in a file (.bindings), so the provider URL should point to the location of file that contains the JNDI bindings.
      ** Sun JNDI is not recommended for prod use.

    2. The Queue Connection Factory JNDI Name is the actual name of the QCF that you want to use, the LookUp name is the one that you will use in your java client/JMS adapter to lookup that QCF.

    3. Client Id is the id that you want your clients to use while creating connection from your Connection Factories. Each connection created from your CF will contain a clientId that is derived from the clientId specified by you in the CF settings.

    I do not know what is the sequence of steps you followed to set up your Broker JMS provider. First try creating a JMS Broker using the ‘JMS Broker’ link in WmJMSAdmin page. Give the name of the JMS Broker (broker000), Broker Server Name (localhost) and the port number (6489 or whatever it is in your case). Before you proceed to the next step, ensure that a connection has been obtained with this JMS Broker when you click the ‘Add’ button to add the JMS Broker.

    Once the JMS Broker is added and connected, add the JNDI Provider. Select the appropriate template… this would give you the sample provider url… ie file:/<path-of-ur-.bindings-file>

    When the above is configured, you may proceed to add the CFs and then the Destinations. For the sake of convenience, you may give the same JNDI Name and Lookup Name for the objects (CFs and Destinations) and later when you have gotten ev thing to work, you can rename them appropriately.

    HTH, Rohit


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


  • 7.  RE: Using webM Broker as JMS Provider

    Posted Tue March 15, 2005 09:06 PM

    Ok, I have made some progress, but I am not home free yet. For the benefit of others, here is what I did:

    1. copied BrokerJMS61.jar from Broker\lib to IntegrationServer\lib

    2. Implemented the PointToPoint.java client as shown in Appendix B of the webMethods JMS Provider Programmer Guide.

    3. Added the following code snippet to show useful info about the connection

      qcf = (javax.jms.QueueConnectionFactory) ctx.lookup(qcf_admin_object);
      System.out.println(“Looked up Queue Connection Factory object.”);
      System.out.println(“qcf=”+qcf.toString());

    4. Ran WmJMSAdmin to configure a connection factory and queue (destination).

    5. Output from java clientJava
      Looked up Queue Connection Factory object.
      qcf=com.wm.broker.jms.QueueConnectionFactory:
      brokerName: Broker #1
      brokerHost: localhost:6849
      sessionClientGroup: BrokerJMS_Sessions
      connectionClientId: QueueConnection
      sharedState: false
      sharedStateOrdering: none
      tcpConnectionSharing: true
      strictClientId: false
      sslCertificateFilename: null
      sslEncrypted: false

    6. Screen shot of webMethods JMS Administrator
      =============================================
      JMS > Connection Factories > QCF1
      Return to Connection Factories
      Modify Connection Factory

      Information
      Lookup Name QCF1
      Class com.wm.broker.jms.QueueConnectionFactory
      Type QueueConnectionFactory
      JMS Broker Name Broker #1@localhost
      Connection Client Group QueueConnectionFactory_ConnectionClientGroup
      Session Client Group QueueConnectionFactory_SessionClientGroup
      Connection Client Id QueueConnection
      Shared State false
      Shared State Ordering none
      TCP Connection Sharing true
      Strict Client Id false
      SSL Encrypted false
      =============================================

    7. Screen shot of webMethods JMS Administrator
      =============================================
      JMS > Destinations > Q1
      Return to Destinations
      Modify a Destination
      Create queue for Queue Receiver
      Remove queue for Queue Receiver

      Information
      Lookup Name Q1
      Queue Name queue1
      Class com.wm.broker.jms.Queue
      Type Queue
      Client Group queue1_ClientGroup
      Shared State false
      Shared State Ordering none
      =============================================

    8. Created JMS connector

    9. Created JMS adapter service for sender

    10. Created JMS adapter service for receiver

    11. Created sender flow service to call adapter sender service
      I need to figure out how to send a message (convert string to javax.jms.Message)

    12. Created receiver flow service to call adapter receiver service
      I need to figure out how to receive a message

    Thanks for the help so far by everyone.


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


  • 8.  RE: Using webM Broker as JMS Provider

    Posted Wed March 30, 2005 05:05 PM

    Do we need to create a JMS adapter service to retreive the message from the Broker or can we directly have a trigger subscribe to this message?

    This is something that the documentation does not cover at all.

    Please help.

    Thanks.

    Vishal Venkatram


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


  • 9.  RE: Using webM Broker as JMS Provider

    Posted Wed March 30, 2005 05:41 PM

    Vishal,

    Yes, if you want to receive those messages in webMethods you will need to create JMS Adapter Services to do so. Note, when you configure Broker as a JMS provider, it is no longer just a simple broker. You will need to treat it just as any other JMS Provider - say weblogic.

    HTH, Roh


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


  • 10.  RE: Using webM Broker as JMS Provider

    Posted Mon April 04, 2005 07:46 PM

    Rohit,

    Thanks for this information.

    How cluster aware is the JMS adapter? And how well does the Broker scale as a JMS provider.

    I have several other questions and would like to talk to you.

    Thanks.

    Vishal


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


  • 11.  RE: Using webM Broker as JMS Provider

    Posted Mon April 04, 2005 08:30 PM

    Vishal,

    In the JMSAdapter guide, there is a section on JMS Adapter in a Clustered Environment. You might want to read up this section to get an understanding of the functioning of JMS Adapter in a clustered env. There are a few things that you need to be aware and careful of and this section explains them.

    As for the scalablity… uhmm well… not too sure… because I started a project with initial requirement to use Wm Broker as the JMS provider… however, we were still using the weblogic JNDI (webMethods has not released its JNDI service for prod). Thus the client decided to use the weblogic JMS instead of the webMethods and I didn’t get a chance to explore Broker-JMS any further. I guess you would know already that webM broker as a JMS provider can use weblogic/LDAP or a File System (Sun’s) JNDI.

    Let me know what other questions you have… I will try wherever I can help.

    Roh


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


  • 12.  RE: Using webM Broker as JMS Provider

    Posted Sun December 18, 2005 06:27 PM

    Hi all,
    I don’t have much knowledge about weblogic…i need to communicate with weblogic to Broker JMS Provider,

    Mainly project deals:

    I will get messages(using Broker as a JMS Provider ) from weblogic client, I need to validate that massages through Modeler and than i need to perform webservices routing to application server.

    Q1) what are the steps involved in this case
    Q2) how can i perform communication between weblogic to webMethods.
    Q3) what type of messages Broker can receive and after how can i process
    Please guide me , i am new for this type of task.

    It is grate helpful for me if anybody can guide me.

    Thank you and have a nice day


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


  • 13.  RE: Using webM Broker as JMS Provider

    Posted Wed March 18, 2009 04:37 PM

    Hi Rohit,

    I am also trying to connect to the wm broker jms from weblogic to post and subscribe messages.
    I am getting confused trying to read the broker programmers guide.
    You had mentioned about using the wmJMSAdmin package to create the necessary jms components on the wm broker.
    However, I am stuck at using a JMS template to use. Which one should I use for this purpose?
    Can you please provide step by step instructions on how to send an receive messages from WM Broker?


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