Creating JMS request using Parasoft Rest APIs

Afshan_TabasumAfshan_Tabasum Posts: 7

We are trying create a MQ client request using transport as JMS.

Transport transport = new Transport();
transport.setType(TransportType.JMS);

But unable to figure out next steps on mapping of the queue details configurations which includes SSL set up and queue names. For establishing the MQ connection.

Comments

  • jakubiakjakubiak Posts: 424 admin

    Are you trying to configure a JMS request with the SOAtest desktop, or are you trying to programmatically configure a JMS request using the REST API of SOAtest server? Also, you mention MQ - are you trying to connect via Websphere MQ transport or over the more generic JMS transport?

  • benken_parasoftbenken_parasoft Posts: 618 ✭✭✭
    edited January 3

    As I mentioned recently in my other post, the "jump start Maven project" is outdated and might be removed later. Instead, there is a new java client available. Please see my response here: Read .tst file using java.

    I know that the REST API does not expose all transport configuration options that you might see in the SOAtest Desktop application, like those for JMS.
    However, this newer java client supports the current version of the REST API which has all the configuration for the WebSphere MQ transport. For example, you might have java code that looks like this:

    try (ParasoftApiRestClient client = new ParasoftApiRestClient("localhost", "username", "password")) {
        client.v5().getSoapClients().putSoapClient("/TestAssets/mytest.tst/Test Suite/SOAP Client", new SoapClientsPUTRequest()
                .withTransport(new Transport()
                        .withWebSphereMq(new WebSphereMqTransport()
                                .withMqAddress(new MqAddress()
                                        .withConnectionSettings(new ConnectionSettings()
                                                .withChannel(new ComplexValueFP()
                                                        .withFixed("mq_channel"))
                                                .withQueueManager(new ComplexValueFP()
                                                        .withFixed("QM"))
                                                .withPutQueue(new ComplexValueFP()
                                                        .withFixed("putQueue"))))
                                .withSsl(new Ssl()
                                        .withCipherSuite(new ComplexValueFP()
                                                .withFixed("SSL_RSA_WITH_RC4_128_SHA"))))));
    }
    
  • Afshan_TabasumAfshan_Tabasum Posts: 7

    Hi ,
    We need help to make a successful connection to WebMQ from Parasoft's desktop application. We have the following information ,
    Provider URL
    Initial context
    connection factory, but we don't see any option to configure SSL if we select the transport as JMS.

    So when we tried using the WebMQ transport of Parasoft message client, it requires a whole other set of information,
    now we have a CCDT file to proceed, but when we try to configure SSL we see the below error when we try to select the required cipher suite from the drop down,

    "Warning: The selected CipherSuite is not supported by your JRE. you may need to use an IBM JRE."

    Can you suggest on how to resolve this error.

  • jakubiakjakubiak Posts: 424 admin

    You need to install an IBM JRE on your system, and then you need to configure SOAtest desktop to use it by passing the following argument to the soatest executable:

    soatest.exe -Zjava_home path_to_your_java_8_installation

  • Afshan_TabasumAfshan_Tabasum Posts: 7

    By IBM JRE do you mean the IBM SDK available in the below link ??
    IBM® SDK 8 - https://www.ibm.com/developerworks/java/jdk/

  • benken_parasoftbenken_parasoft Posts: 618 ✭✭✭

    Yes. The URL to the download page has changed several times over the years but that looks like the current URL.

  • RajeshURajeshU Posts: 8

    @jakubiak As per your suggestion I installed IBM JRE and tried opening parasoft through command prompt with the following command ,
    soavirt.exe -Zjava_home C:\IBM_80\ibm_sdk80\bin

    But still I see the same warning ,
    "Warning: The selected CipherSuite is not supported by your JRE. you may need to use an IBM JRE."

    Am I pointing to the wrong jre path ? can you suggest ?

  • jakubiakjakubiak Posts: 424 admin

    Here is a list of cipher suites that are enabled and disabled by default within the IBM JRE 8. Can you verify whether the cipher suite you are trying to use is on this list and is enabled?

    https://www.ibm.com/support/knowledgecenter/en/SSYKE2_8.0.0/com.ibm.java.security.component.80.doc/security-component/jsse2Docs/ciphersuites.html

  • benken_parasoftbenken_parasoft Posts: 618 ✭✭✭

    soavirt.exe -Zjava_home C:\IBM_80\ibm_sdk80\bin

    Remove '\bin' from the end.

  • RajeshURajeshU Posts: 8

    Thanks @benken_parasoft and @jakubiak The warning is gone now. But when I post the request I see the below connection error although the right CCDT file is configured and queue manager, put queue and get queue details are entered still is the below error,
    MQJE001: Completion Code '2', Reason '2278 (MQRC_CLIENT_CONN_ERROR) '.

Sign In or Register to comment.