AnsweredAssumed Answered

Unable to execute a Java Code in vsm or vsi

Question asked by dinho1705 on Sep 19, 2017
Latest reply on Sep 20, 2017 by dinho1705

Hi ,

 

I am trying to execute a java code that add extra space on the right side, if a string is not of defined width.

code is:

//right padding

HOST_PROCESS_ID = String.format("%-" + 8 + "." + 8 + "s", HOST_PROCESS_ID);

or

HOST_PROCESS_ID = HOST_PROCESS_ID.format("%-" + 8 + "." + 8 + "s", HOST_PROCESS_ID);

 

this is giving me exception in vsm(data protocol) and in vsi(matchscript).

 

Please let me know if we can handle this by some other way as well.

 

Why this: calisa when encounter a series of spaces before or after a string in incoming request(lisa_vse_request) , it applies trim on the string. Hence I have to add padding exclusively to get my string of original length.

 

 

Please help, It's urgent.

 

Thanks,

Dinesh Kumar

Outcomes