go to post Marc Mundt · Feb 8, 2018 Thanks, this is helpful.In your routing rule, can you try setting the condition from "Document.OriginalFilename Contains "NTWD33"" to "1"? Also, can you post a snapshot of the "general" tab in the rule editor?
go to post Marc Mundt · Feb 8, 2018 Hi Lorraine,A few questions to help us get a clearer picture:Which component is generating the 5005 error? Is it the router or the business operation?Can you post a screenshot or the source code for your routing rule?Is your router calling a transformation or just passing the file through unchanged?What happens if you remove all logic from your router and just change it to do a simple "send" with no transformation?-Marc
go to post Marc Mundt · Jan 11, 2018 It sounds like you might be able to avoid the problem of converting to XML and creating an EnsLib.EDI.XML.Document if you were able to access fields in your persistent message class from your routing rule logic?If your persistent message class has discrete properties, you can still refer to these directly in a routing rule condition even without the VDoc style GetValueAt().If your message object has references to repeating child objects and you need to get to a deeper level such as checking a property of the Nth child object you can do this by creating a custom function and passing it the Document object as a parameter.
go to post Marc Mundt · Jan 8, 2018 Does it need to be a binary executable or would a batch file work? It is possible to execute a Caché routine/method from a Windows command line or batch file by invoking the Caché binary and passing it the name of what you want to execute. The docs give this example for freezing and thawing the database for backups:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=... CD C:\InterSystems\E20131\mgr\ ..\bin\cache -s. -B -V -U%SYS ##Class(Backup.General).ExternalThaw()
go to post Marc Mundt · Dec 5, 2017 The high-level steps are:Create a Java class using the APIs provided by your JMS server (ActiveMQ, RabbitMQ, etc.) and create a JAR file. JMS is a standardized API, not a protocol, so there is not one universal JMS client that will work with all JMS servers.Use the Java Gateway wizard to generate COS proxy classes for your Java classSetup a Java Gateway Service in your production. Make sure it points to your custom JAR file and the JAR file provided by the JMS server vendor.Create a custom business service or operation that calls the COS proxy class methods.When adding the service or operation to the production, configure it to point to the Java Gateway Service and use the correct Java classFor a Business Operation, you'll just use the usual approach: the message map points to a custom method. The custom method then calls the COS proxy class methods for your Java class. The BO class should extend Ens.BusinessOperation and use the adapter EnsLib.JavaGateway.OutboundAdapter.For a Business Service, there's an out of the box adapter, EnsLib.JavaGateway.InboundAdapter. You just need to create a custom Operation that extends Ens.Business service and uses EnsLib.JavaGateway.InboundAdapter as it's adapter. This is quite nice, because EnsLib.JavaGateway.InboundAdapter handles most everything automatically. Your Java class just needs to implement a set of methods defined by the Inbound Adapter. See the class reference for EnsLib.JavaGateway.InboundAdapter for more details: * .Connect(pJGClientConnectSpec,pTimeout,pInbound) * .Disconnect(pInbound) * .IsConnected(pInbound) * .getErrorText() [returns empty string if no error on previous method call] * .ReceiveMessage(pTimeout) [inbound only; pMsgIn return needs not be populated if timed out] * .SendResponse(pMsgOut) [inbound only, optional-needed if OnProcessInput will return an object] * .SendMessage(pMsgOut,pGetReply,pResponseTimeout) [outbound only; pMsgIn return needs not be populated if no responses are anticipated]I've created some sample code including a production and Java classes. It includes a generic class that implements most of the necessary methods using standard JMS API methods and provides an ActiveMQ-specific subclass that uses the ActiveMQ proprietary methods to initiate the connection.As always, this is sample code for demonstration purposes only and is not production ready.
go to post Marc Mundt · Dec 1, 2017 Alerts (Ens.AlertRequest) are treated like any other message in Ensemble -- you can transform them to different message types and route them to an outbound business operation.Have a look at the docs regarding alerts here:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...And the docs regarding file adapters here:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...One approach you can consider is to transform the Ens.AlertRequest into an Ens.StreamContainer and then use an EnsLib.File.PassthroughOperation to write it out to a file:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...If you need to write the alert to a file in a structured format, you can consider creating a RecordMap for your output format, transform the Ens.AlertRequest into your custom RecordMap object, and then use EnsLib.RecordMap.Operation.FileOperation to write it out to the file:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...
go to post Marc Mundt · Nov 29, 2017 One approach would be to create a custom business service that manages an SSH connection by calling a command line SSH client similar to your existing UNIX scripts. It would start the connection when the production/business service starts, clean it up when the service is stopped, and can log errors in the Ensemble error log.
go to post Marc Mundt · Nov 20, 2017 You can use the Enumerate stored procedure in the Ens.Job class to get a list of running Ensemble jobs (config items) in the current namespace. If you need to get other system level details about the process, the "job" field is the same as the process id from %SYS.ProcessQuery.From a SQL query tool you can call it with:call Ens.Job_Enumerate()From my earlier comment: %syPidtab.inc includes a list of Job Types and their corresponding IDs.
go to post Marc Mundt · Nov 15, 2017 Jess,I see that it's been a month since you posted this, so you've probably found a solution already.Application ACK mode should still be what you want to use. It doesn't matter if you're actually sending it to another application -- your Business Process can return the RSP_K22 to the Business Service and it should send it back to the caller.Marc
go to post Marc Mundt · Nov 8, 2017 The content of an EnsLib.HL7.Message is actually stored in streams, which don't have a fixed size, so theoretically there is no maximum size for an HL7 message.The RawContent property is a bit misleading. This is a convenience for accessing the content of the message, but it's not where the content is actually stored. RawContent is generated dynamically from the underlying streams but only returns the first 10000 characters.If you want to access the full, raw, untruncated message you can use one of the OutputTo* methods such as OutputToLibraryStream.
go to post Marc Mundt · Nov 7, 2017 Hi Stephen, This can be done with a custom query. See below for some sample code that takes the form of a stored procedure. This stored procedure only handles items in a single namespace, but you could adapt it to run across multiple namespaces. To call the stored procedure from a SQL query tool:call Sample.Util_SettingsByName('Port') The parameter you pass is the name (or names, comma-separated) of the setting(s) you want to get a list of. Leave it blank to get a list of all settings. Best,Marc Class Sample.Util Extends %RegisteredObject { /* ***************************************************** * ** N O T I C E ** * * - TEST/DEMO SOFTWARE - * * This and related items are not supported by * * InterSystems as part of any released product. * * It is supplied by InterSystems as a demo/test * * tool for a specific product and version. * * The user or customer is fully responsible for * * the maintenance of this software after delivery, * * and InterSystems shall bear no responsibility nor * * liabilities for errors or misuse of this item. * * * ***************************************************** */ Query SettingsByName(SettingName As %String) As %Query(ROWSPEC = "BusinessHost:%String,SettingName:%String,SettingValue:%String") [ SqlProc ] { } ClassMethod SettingsByNameExecute(ByRef qHandle As %Binary, SettingNames As %String = "") As %Status { s qHandle=##class(%ArrayOfObjects).%New() &sql(select %DLIST(id) into :tHostIDs from ENS_Config.Item order by Name desc) s tHostIDList=##class(%Library.ListOfDataTypes).%New() s tSC=tHostIDList.InsertList(tHostIDs) s tSC=qHandle.SetAt(tHostIDList,"HostIDs") s tSC=qHandle.SetAt(##class(%ArrayOfDataTypes).%New(),"Counters") s tSC=qHandle.GetAt("Counters").SetAt(0,"CurrHost") s tSC=qHandle.GetAt("Counters").SetAt(0,"CurrSetting") if ($L(SettingNames)>1) { s SettingNames=$ZCONVERT(SettingNames,"U") s tFilterList=##class(%Library.ListOfDataTypes).%New() s tSC=tFilterList.InsertList($LISTFROMSTRING(SettingNames)) s tSC=qHandle.SetAt(tFilterList,"FilterList") } Quit $$$OK } ClassMethod SettingsByNameClose(ByRef qHandle As %Binary) As %Status [ PlaceAfter = SettingsByNameExecute ] { Quit $$$OK } ClassMethod SettingsByNameFetch(ByRef qHandle As %Binary, ByRef Row As %List, ByRef AtEnd As %Integer = 0) As %Status [ PlaceAfter = SettingsByNameExecute ] { s tCurrHost=qHandle.GetAt("Counters").GetAt("CurrHost") s tCurrSetting=qHandle.GetAt("Counters").GetAt("CurrSetting") s tHostIDs=qHandle.GetAt("HostIDs") s tFilterList=qHandle.GetAt("FilterList") s oHost=qHandle.GetAt("Host") do { if ('$IsObject(oHost)||(oHost.VirtualSettings.Count()<tCurrSetting)) { if (tCurrHost=tHostIDs.Count()) { s AtEnd=1 q } s tCurrHost=tCurrHost+1 s tCurrSetting=1 s tHostID=tHostIDs.GetAt(tCurrHost) s oHost=##class(Ens.Config.Item).%OpenId(tHostID,0) s tSC=oHost.PopulateVirtualSettings() s tSC=qHandle.SetAt(oHost,"Host") s tSC=qHandle.GetAt("Counters").SetAt(tCurrHost,"CurrHost") } s tSettings=oHost.VirtualSettings s tSetting=tSettings.GetAt(tCurrSetting) s tStngName=$LISTGET(tSetting,2) s tStngValue=$LISTGET(tSetting,3) s tCurrSetting=tCurrSetting+1 } while ($IsObject(tFilterList)&&('tFilterList.Find($ZCONVERT(tStngName,"U")))) if ('AtEnd) { s Row=$LB(oHost.Name,tStngName,tStngValue) } s tSC=qHandle.GetAt("Counters").SetAt(tCurrSetting,"CurrSetting") Quit $$$OK } }
go to post Marc Mundt · Sep 26, 2017 Also, have a look at the query "SubclassOf" in %Dictionary.ClassDefinitionQuery:http://docs.intersystems.com/latest/csp/documatic/%25CSP.Documatic.cls?P...
go to post Marc Mundt · Sep 11, 2017 Salim,Steps to customize the patient search page are available in the HealthShare documentation. You can navigate to it or search for "Customizing the Patient Search Page".You should not modify HS.UI.PatientSearch.cls directly -- you should subclass it and override the relevant methods.Best,Marc
go to post Marc Mundt · Jun 6, 2017 You can find the current segment count using field counting syntax: source.GetValueAt("(*)") To create a new segment have a look at the documentation for EnsLib.HL7.Segment, particularly the method ImportFromString. To insert a segment into a message, have a look at EnsLib.HL7.Message::InsertSegmentAt.
go to post Marc Mundt · Jun 6, 2017 There is no standard Ensemble function that accepts multiple values and looks up each one in a lookup table in a single call.You can achieve this by creating a custom function which accepts a delimited string with all of the values and then iterates through each value and calls the standard "lookup" function once for each value.
go to post Marc Mundt · Jun 6, 2017 FHIR support is included in HealthShare Health Connect. There are some great introductions to FHIR capabilities on our Learning Services website. Just search for "FHIR".
go to post Marc Mundt · Jun 6, 2017 Yes, you just need to wrap them in parentheses and use "||" for "or": if ((ReceivingFacility="A") || (ReceivingFacility="B") || (ReceivingFacility="C")) { Or look at using other functions like $LISTFIND or the "[" (contains) operator: if ($LISTFIND($LISTBUILD("A","B","C"), ReceivingFacility) {
go to post Marc Mundt · Jun 6, 2017 HTML can be output using normal <item> tags with the copyHtml attribute.By the way, I see you're a member of QP's team. I'd suggest talking with some of the local Trak technical specialists -- they are experts in Zen reports.
go to post Marc Mundt · Jun 6, 2017 Ensemble's ESB components can accept an HTTP request and pass it through to a downstream system.Here's a link to the ESB section of the Ensemble docs.