Creating a QueueConnectionFactory - Websphere

This is a discussion on Creating a QueueConnectionFactory - Websphere ; I happened to see a nice article http://www-128.ibm.com/developerwork...502_woolf.html and it really helped me to understand how to do a standalone app with MQ... I completed it and it works great. Just wanted clarify something, the tutorial has an script to ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Creating a QueueConnectionFactory

  1. Creating a QueueConnectionFactory



    I happened to see a nice article http://www-128.ibm.com/developerwork...502_woolf.html
    and it really helped me to understand how to do a standalone app with MQ... I completed it and it works great.


    Just wanted clarify something, the tutorial has an script to create QueueConnectionFactory .... in my case I can not do that as MQ support group doesn't allow this..... do you know if I can do this programmatically from a non J2EE java application?

    MQ support group will only create a Q Manager and Q for me.

    Please advise.

    Your help is highly appreciated!

    Raj

  2. Re: Creating a QueueConnectionFactory

    QueueConnectionFactory is a JMS construct as implemented by (for example)
    'MQ Classes for JMS'. Q Manager and Q are 'MQ Classes for Java' constructs.
    I'm not sure what you mean by 'MQ support group' and therefore I don't know
    what you mean by '...doesn't allow this'.

    WebSphere MQ has 2 different Java APIs. MQ Classes for Java is an
    Object-Oriented form of the MQI, implemented in Java; it makes all the
    features of MQ available to Java applications, but is MQ-specific so
    applications cannot be easily ported to other JMS providers, and it does not
    have an administrative layer allowing connection and destination details to
    be abstracted from the code. MQ Classes for JMS is an implementation of the
    JMS specification from Sun, controlled by the Java Community Process; it
    allows applications to be more easily ported between messaging environments
    since it uses an open standard API, has administered object support and can
    be used as a JMS Provider within a J2EE application server such as WebSphere
    Application Server, but does not enable all of the more advanced features of
    MQ to be used.

    Take another look at your MQ installation; you should find com.ibm.mqjms.jar
    alongside com.ibm.mq.jar, so you can choose which of the 2 APIs to use.
    Either of them can be used in a standalone Java application (J2SE rather
    than J2EE). See also the WebSphere MQ 'Using Java' manual.

    Brian

    wrote in message
    news:696894721.1141398986615.JavaMail.wassrvr@ltsg was007.sby.ibm.com...
    >
    >
    > I happened to see a nice article

    http://www-128.ibm.com/developerwork...502_woolf.html
    > and it really helped me to understand how to do a standalone app with

    MQ... I completed it and it works great.
    >
    >
    > Just wanted clarify something, the tutorial has an script to create

    QueueConnectionFactory .... in my case I can not do that as MQ support
    group doesn't allow this..... do you know if I can do this programmatically
    from a non J2EE java application?
    >
    > MQ support group will only create a Q Manager and Q for me.
    >
    > Please advise.
    >
    > Your help is highly appreciated!
    >
    > Raj




  3. Re: Creating a QueueConnectionFactory

    vanniarajan@yahoo.com wrote:
    >
    > I happened to see a nice article
    > http://www-128.ibm.com/developerwork...502_woolf.html
    > and it really helped me to understand how to do a standalone app with MQ...
    > I completed it and it works great.


    Good to hear

    > Just wanted clarify something, the tutorial has an script to create
    > QueueConnectionFactory .... in my case I can not do that as MQ support
    > group doesn't allow this..... do you know if I can do this programmatically
    > from a non J2EE java application?


    You can, although you will lose the ability to switch JMS providers without
    changing your code. The incantation for use with the WebSphere MQ JMS provider is:

    QueueConnectionFactory qcfact = new com.ibm.mq.jms.MQQueueConnectionFactory();

    I'd recommend that you double-check you've asked the right people before you
    resort to this. You might find that your JNDI managers are different to your MQ
    support team.

    Hope this helps,

    Phil
    --
    XMS Client Development

+ Reply to Thread