Service Virtualization

  • 1.  How to make setStateValue not Truncate String we set

    Posted Mar 14, 2018 02:28 PM

    When we setting up incoming request/response in to user defined property using  setStateValue, we are seeing string got truncated and we are not able to get complete XML in DevTest 10.1. Is there any way we can set up the property to do not truncate the value.

     

    Sample Code: 

    testExec.raiseEvent(212, "VSE_INFO[REQUEST]", testExec.getStateValue("lisa.vse.http.current.transaction.body").toString());
    testExec.raiseEvent(212, "VSE_INFO[RESPONSE]", lisa_vse_response.getBodyAsString());

     

    Output

     

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?><SOAP-ENV:Envelope xmlns:ns6="http://eai-schemas.wellsfargo.com/entity/account/"><root><ns3:hostName>165.126.168.94</ns3:hostName><ns3:billingAU>13205</ns3:_TRUNCATED_

     

    Reagrds,

    Dinesh.C



  • 2.  Re: How to make setStateValue not Truncate String we set
    Best Answer

    Posted Mar 14, 2018 02:32 PM

    Add the following to VirtualServiceEnvironment.vmoptions and see if it helps.  Restart the VSE Server after updating the vmoptions parameter.

    -Dtestexec.lite.longMsgLen=65000

     

     

    The longMsgLen value can be any big integer.



  • 3.  Re: How to make setStateValue not Truncate String we set

    Posted Mar 14, 2018 02:44 PM

    Thanks Ashutosh, it worked .



  • 4.  Re: How to make setStateValue not Truncate String we set

    Broadcom Employee
    Posted Mar 14, 2018 02:48 PM

    The solution mentioned by Ashutosh.Satyam will remove the _TRUNCATED_ from the display.

     

    The actual value itself doesn't get truncated - only when shown in the portal it shows this way.

    This property is set to a low value to conserve the memory footprint of the portal.

     

    So the value set in testExec using setStateValue is still available for usage later in the workflow.



  • 5.  Re: How to make setStateValue not Truncate String we set

    Posted Mar 14, 2018 02:54 PM

    Prem,

     

    Thanks for clarification, I want to display in Portal only with complete xml for our User to debug incoming request and response fro debug.