Submit and vote on feature ideas.

Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

Creating JMS request using Parasoft Rest APIs

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

  • jakubiak
    jakubiak Posts: 795 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_parasoft
    benken_parasoft Posts: 1,228 ✭✭✭
    edited January 2019

    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"))))));
    }
    
  • 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.

  • jakubiak
    jakubiak Posts: 795 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

  • 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_parasoft
    benken_parasoft Posts: 1,228 ✭✭✭

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

  • RajeshU
    RajeshU Posts: 19

    @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 ?

  • jakubiak
    jakubiak Posts: 795 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_parasoft
    benken_parasoft Posts: 1,228 ✭✭✭

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

    Remove '\bin' from the end.

  • RajeshU
    RajeshU Posts: 19

    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) '.

  • benken_parasoft
    benken_parasoft Posts: 1,228 ✭✭✭

    Client connection errors from IBM MQ can sometimes be tricky to troubleshoot. If the server is refusing the connection, it won't necessarily disclose the reason to the client in which case you need to check the logs on the queue manager side. Otherwise, if there is some issue with the client refusing to connect to the server, then sometimes you can find more detail by double clicking on the error in the Quality Task view. Sometimes, you can also find more error detail in the xtest.log file in a Technical Support Archive (TSA). Parasoft Support can assist you in creating this and analyzing it.

  • dsarabu
    dsarabu Posts: 2

    Hi benken, I am using the below command to open parasoft soa test (9.10.6) using IBM JRE

    "C:\Program Files\Parasoft\SOAtest & Virtualize\9.10\soavirt.exe" -Zjava_home "C:\ibm_sdk80"

    But I still 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."

    While my other colleagues(who are using 9.10.7) are not seeing this error although they are using the same JRE and the command. Is this because of the SOATest version?

  • dsarabu
    dsarabu Posts: 2

    correction - the version I am using is 9.10.5

  • jakubiak
    jakubiak Posts: 795 admin

    That argument works for 9.10.5 as well.

  • benken_parasoft
    benken_parasoft Posts: 1,228 ✭✭✭
    edited December 2019

    While my other colleagues(who are using 9.10.7) are not seeing this error although they are using the same JRE and the command. Is this because of the SOATest version?

    No. Probably something else about your particular environment or maybe you have a typo or pointed at the wrong folder or something. If you click "Help > About > Installation Details > Configuration" look for "java.home" to confirm which java is actually being used.