[Progress Communities] [Progress OpenEdge ABL] Forum Post: Error 9407 connection failure

Status
Not open for further replies.
K

k036169

Guest
Hello, I'm sending sales figures to an analytic platform with a post to receive back forecasts. I can set batches of several products. I send data in json format with a POST, platform might take a while to process, so i can query result with a GET. When i send batches of 20 products, the 13 firsts are processed OK, then 14th & 15th fail because of Progress error 9407, then next are processed OK. If i send a big batch, POST works, but connection failure error occurs on the GET... I'm probably missing something in my code (part of it at the end of the message), i checked OpenEdge documentation/KB but didn't find any clue... Did someone face this issue and find a solution to this ? Thanks. Thierry oLib = ClientLibraryBuilder:Build() :Library. oClient = ClientBuilder:Build() :UsingLibrary(oLib) :Client. oURI = NEW URI(STRING(UriSchemeEnum:https), in-endpoint-url). oURI:port = in-endpoint-port. oURI:path = in-endpoint-path. OSTRING = NEW STRING(iplcPayload-data). oRequest = RequestBuilder :post(oURI, OSTRING) :ContentType(in-payload-type) :AcceptJSON() :AddHeader('x-api-key',in-api-key) :Request. oResponse = oClient:Execute(oRequest). oEntity = oResponse:Entity. opJsonResult = CAST (oentity, JsonObject) NO-ERROR. cRequestID = opJsonResult:getCharacter("requestId") NO-ERROR. cAAstatus = "". cAAStatus = opJsonResult:getCharacter("status") NO-ERROR. IF cAAStatus <> "" THEN IF cAAStatus = "not-ready" THEN DO: ASSIGN in-endpoint-path = in-endpoint-path + "/" + cRequestID oURI:path = in-endpoint-path. DO iWaitLoop = 1 TO 480 : PAUSE 60 NO-MESSAGE. oRequest = RequestBuilder :GET(oURI, OSTRING) :ContentType(in-payload-type) :AcceptJSON() :AddHeader('x-api-key',in-api-key) :Request. oResponse = oClient:Execute(oRequest). oEntity = oResponse:Entity. opJsonResult = CAST (oentity, JsonObject) NO-ERROR. cRequestID = opJsonResult:getCharacter("requestId") NO-ERROR. cAAstatus = "". cAAStatus = opJsonResult:getCharacter("status") NO-ERROR. IF cAAstatus <> "not-ready" THEN LEAVE. END. END.

Continue reading...
 
Status
Not open for further replies.
Top