go to post Eduard Lebedyuk · Jun 29, 2022 If it's a non-production instance you can try running iris windows service (IRIS controller for IRISHEALTH in your case) under your windows user account, instead of the default system one. That usually helps. If it's not possible, either give system account rights to irissession or create a new user with rights for irissession and run the iris service under that account.
go to post Eduard Lebedyuk · Jun 17, 2022 Use Merge in your Business Service: Set genericRequest = ##class(Core.API.V1.Msg.GenericRequest).%New() Merge genericRequest.urlParameters = %request.Data And in BusinessOperation you can use this syntax: genericRequest.urlParameters("key")
go to post Eduard Lebedyuk · Jun 13, 2022 Each app should use it's own user with a minimal set of roles and permissions.
go to post Eduard Lebedyuk · Jun 13, 2022 DTLs work in-proc rather than in-queue so you can avoid the creation of new messages altogether. To be specific let's say you have a DTL: <transform sourceClass='Ens.StringRequest' targetClass='Ens.StringResponse' create='new' language='objectscript' > <assign value='source.StringValue' property='target.StringValue' action='set' /> </transform> It would be compiled into this (simplified for clarity): Transform(source,target,aux="") { Set (tSC,tSCTrans,tSCGet)=1 Set target = ##class(Ens.StringResponse).%New() Do:$S($D(%Ensemble("DoTrace")):%Ensemble("DoTrace"),1:##class(Ens.Util.Trace).DoTrace()) ##class(Ens.Util.Trace).WriteTrace("xform",$classname(),"Transform","transform from source "_source_$S(source.%Extends("%Persistent"):"/"_source.%Id(),1:"")_" to target "_target_$S(target.%Extends("%Persistent"):"/"_target.%Id(),1:"")_"") Try { Set zVALz=source.StringValue, zVALz=$S($IsObject(zVALz):zVALz.%ConstructClone(), 1:zVALz) } Catch ex { If (..#IGNOREMISSINGSOURCE&&($$GetOneStatusText^%apiOBJ(ex.AsStatus())["<INVALID OREF>")) { Set tIgnore=1 } Else { Set tSC=ex.AsStatus() } } If 'tIgnore { Set target.StringValue=zVALz } } As you see the only new message is response and request/aux are not saved anywhere. The same holds true for BPL invocations. Assuming this process: <process language='objectscript' request='Ens.StringRequest' response='Ens.StringResponse' height='2000' width='2000' > <sequence xend='200' yend='350' > <transform name='dtl' class='dtl.dtl' source='request' target='response' xpos='200' ypos='250' /> </sequence> </process> You'll have this S method: Method S1(process As Ens.BusinessProcess, context As Ens.BP.Context, synctimedout As %Boolean, syncresponses As %ArrayOfObjects(ELEMENTTYPE="%Library.Persistent"), request As %Library.Persistent, response As %Library.Persistent) As %Status [ Language = objectscript, PublicList = (process, context) ] { Set $ZT="Trap",status=$$$OK do { Set iscTemp=$G(response) Set status=$classmethod("dtl.dtl","Transform",request,.iscTemp,"") If $$$ISERR(status) Quit Set response=iscTemp Do process.ClearAllPendingResponses() Set ..%NextState="Stop" } while (0) Exit Quit ..ManageState(status) Trap Set $ZT="",status=..ManageStatus(status,"S1") Goto Exit } which does nothing except for calling a Transform method. No queueing is used throughout DTL usage. So, there are several options. 1. Do not create a new message, but rather pass your existing message. DTLs do not modify source or aux messages. 2. Use a registered, rather than a persistent class to pass values - in that case it won't be saved at all.
go to post Eduard Lebedyuk · Jun 9, 2022 When I developed this query I was concerned with large globals, certainly if there's an interest in small globals' size this might come useful.
go to post Eduard Lebedyuk · Jun 6, 2022 object="991@%Library.DynamicObject" Somewhere the object was written into a global and read from it.
go to post Eduard Lebedyuk · Jun 3, 2022 Picks up a message maybe (not sure what are you talking about in regards of jobs)? Check Reply Code Actions.
go to post Eduard Lebedyuk · Jun 3, 2022 Mad respect for nailing that VSCode look without using VSCode code.
go to post Eduard Lebedyuk · May 29, 2022 You can also call it like this: set rs = ##class(GMECC.DocmanConnect.Tables.vwNewGPs).GetRowsFunc() while rs.%Next() { do rs.%Print() } More info about implicit methods.
go to post Eduard Lebedyuk · May 26, 2022 Modifying initial request is debatable .Rather I'd recommend setting a status variable to callrequest.Stream.CopyFrom(request.Stream).This way request remains immutable.
go to post Eduard Lebedyuk · May 25, 2022 Windows error codes are here. ERROR_SHARING_VIOLATION 32 (0x20) The process cannot access the file because it is being used by another process.
go to post Eduard Lebedyuk · May 11, 2022 I think we can safely consider this contest closed. Honestly, it's more of a discussion than a contest.
go to post Eduard Lebedyuk · May 8, 2022 Please post SQL plans for slow queries and class def. WRC handles SQL performance issues.
go to post Eduard Lebedyuk · May 6, 2022 Try: Set production = ##class(Ens.Config.Production).%OpenId(productionId) Set item = ##class(Ens.Config.Item).%OpenId(itemId) Do production.RemoveItem(item) Set sc = production.%Save()
go to post Eduard Lebedyuk · May 6, 2022 Nice use of routines. I think it's a first time we're seen routines in classmethods for code golf.