I have several business operations that are all pointed to the same http server. Is there a way to set the http server within some sort of properties file or within the objectscript code? I want to be able to set the http server setting once rather than for every business operation. Any advice on how to go about doing this would be appreciated.
Is there a way to have a context property be available across 2 or 3 different business processes? For example if I am setting a value in a context property within one business process and want to use the same context property in a second business process, is this possible? Is this something that can be done with the "Context Superclass"?
I am still new to cache objectscript and am trying to figure out how I would go about removing the escape characters from my JSON below. When I call the $toJSON method it's adding the "\" character in the file path.
{"FileStatus":"P","Path":"\/somepath\/test\/test123\/filename.txt","InterchangeOID":"100458"}
My Code:
set tJSONFile = {"FileStatus":pRequest.FileStatus,"Path":pRequest.Path,"InterchangeOID":pRequest.InterchangeOID}
set tJSONFile = tJSONFile.$toJSON()
Thanks.
Is their a way to queue messages in a business operation to be processed later? I want to process messages over a certain size on a schedule, but let everything else process in real time. Is their a way to do this with one business operation or would I have to queue the large messages in a different business operation?
I have an http adapter that calls out to a web service and is looking for a "Completed" response. I want the adapter to wait a certain number of seconds before calling out again to get a response. I have tried setting the retry interval on the business operation but that does not do it. See my code below.
While pResponse.StringValue = "Processing" {
set tSC=..Adapter.PostURL(tURL,.tHTTPResponse,,tId)
do tHTTPResponse.Data.Rewind()
set pResponse.StringValue = tHTTPResponse.Data.Read(3000000,.tSC)
$$$TRACE("Second Response: "_pResponse.StringValue)
}
What is the best way to pass a list(collection) of integers from one BPL to another BPL?
Here is what I have now, but this doesn't seem to be working. In the CALL to the other BPL I am trying to pass the EOBList. Not sure what I am doing wrong.
I am trying to create a list of id's which are of type integer. I have created a class like below and then I am trying to call the class from a BPL to first initialize the list. In the BPL, I have an assign action that is using set and a context variable setup to hold the list data. The property is using the class I have created, ##class(MSI.IN835.EOBList).%New(). I keep getting an error back saying the method does not exist. Why does it not like the %new method? I am new to cache object script, so if their is a better way to do this, I am open to that as well.