go to post Oliver Wilms · Jun 24 Thank you for clarifying the double encoding I was doing. I just tested my code with a HTML document. Will it work with %Stream.FileBinary?
go to post Oliver Wilms · Jun 24 Here is my lookFile method which gets the stream for %Set: ClassMethod lookFile(pFile As %String = "https://jira.devops.myserver.com/my-jira/plugins/servlet/raven/attachmen... 1343.docx", pFileNew As %String = "") As %Stream.Object { Set q = """" Set tData = q_pFile_q Set tFileOutlog = "/ICS/jira/wlogDATA" Set tFileOutput = "/ICS/jira/wgetDATA1343.docx" Set tSC = ##class(Oliver.ZF).JiraGet(tData,tFileOutput,tFileOutlog) ; Set tEncodeFN = ..GetEncodeFilename(pFile) Set tEncodePath = "/ICS/jira/" Set pEncode = tEncodePath_tEncodeFN ; Set tEncodedFilename = ##class(Oliver.Base64).B64EncodeWordDoc(tFileOutput,pEncode) Set pStream = ..GetStream(pEncode) Quit pStream }
go to post Oliver Wilms · Jun 24 Why do you say the stream is typically a binary stream? This is the method where I get the Stream: ClassMethod GetStream(pFile As %String = "/tmp/shortObjectFile.txt") As %Stream.Object { Set pStream = ##class(%Stream.FileCharacter).%New() Set pStream.Filename = pFile Quit pStream } The code to produce the encoded file will be in my next response.
go to post Oliver Wilms · Jun 24 Enrico, thank you very much for your help! I use this line of code to get a base64 encoded Stream: Set pStream = ..lookFile(value) I use this line to set the stream into the dynamic object: Do obj.%Set("data",pStream,"stream>base64")
go to post Oliver Wilms · Jun 23 IRIS for Windows (x86-64) 2022.3 (Build 606U) Mon Jan 30 2023 09:08:55 EST It works when I use the filename set newObject = {}.%FromJSONFile("c:\tmp\longObjectFile.txt")
go to post Oliver Wilms · Jun 23 Thank you, Julius for the example. I replaced set newObject = {}.%FromJSONFile(file) in my code with set newObject = {}.%FromJSON(file) to get rid of the error.
go to post Oliver Wilms · Jun 22 Note: Base 64 encoding is not able to encode a string which contains unicode (2 byte) characters. If you need to Base 64 encode an unicode string, you should first translate the string to UTF8 format, then encode it. s BinaryText=$ZCONVERT(UnicodeText,"O","UTF8")s Base64Encoded=$system.Encryption.Base64Encode(BinaryText)Now to Decode it:s BinaryText=$system.Encryption.Base64Decode(Base64Encoded)s UnicodeText=$ZCONVERT(BinaryText,"I","UTF8")
go to post Oliver Wilms · Apr 13 I would like to help, but I do not understand what is the data or how the data is created. Can you share sample data or the code that creates / updates the data?
go to post Oliver Wilms · Apr 10 I also have a Business Operation that sometimes experiences failures. My Reply Code Actions setting is E=R, my Retry Interval is 60, my Failure Timeout is -1. When a message fails, it retries after 60 seconds. This Business Operation is called from a BPL. Connect Timeout (5) and Response Timeout (30) are the default values. We usually do not get timeout, but we sometimes receive 500 Internal Server Error. In this case I check the response in BPL and initiate a retry.
go to post Oliver Wilms · Mar 21 STOPALLPRODUCTIONSTry {Kill arrayDo ##class(%SYS.Namespace).ListAll(.array)Set ns = ""For {Set ns = $Order(array(ns))If (ns = "") QuitKill xSet x = $$MyFunc(ns)Write "x = ",x,!}Return} Catch {Write $ZERROR,!}QuitMyFunc(ns)Try {Write "ns = ",ns,!ZN nsSet sc1 = ##class(Ens.Director).StopProduction()Write "sc1 = ",sc1,!} Catch {Write $ZERROR,!}Return ns
go to post Oliver Wilms · Mar 17 I just tried in my local IRIS using Postman: http://localhost:52773/api/mgmnt/v2/user/myapp I got 201 response and I see classes in Package myapp in USER namespace. When I try the request with invalid JSON body, I got 404 Not Found response.
go to post Oliver Wilms · Feb 3 Hello, I just completed the survey about the interactive InterSystems IRIS Digital Health Interoperability Instruqt Course. I am also missing bonus points for Video and Second Article for iris-hl7. Thank you for your attention :-)
go to post Oliver Wilms · Jan 31 Management Portal > System > Globals > View Global Data ^EnsHL7.Segment
go to post Oliver Wilms · Jan 24 I appreciate the responses from Alexander Koblov. I wonder if @Bob Kuszewski could provide suggestion how is it possible to add mirror member outside of Kubernetes cluster.
go to post Oliver Wilms · Jan 16 You may or may not see it in Event Log based on what is in ^Ens.Debug global.
go to post Oliver Wilms · Jan 16 My concern is that IKO deploys failover members with cluster local network addresses. Can an async that is located outside of the Kubernetes cluster be added to the mirror configured by IKO?
go to post Oliver Wilms · Jan 12 Characters like \ and CR LF must be escaped. In BPL I assign myVariable = request.RawContent Conversion to JSON was successful with this: Set data={} Set data.value=myVariable Set x=data.%ToJSON()