Enrico Parisi · Dec 1, 2024 go to post

What platform (Operating System) are you using for IRIS?

I think NTLM authentication is not available in IRIS for Linux.

Enrico Parisi · Dec 1, 2024 go to post

To debug your issue I suggest to enable SOAP logging setting this two global node:

Set ^ISCSOAP("LogFile")="/path/to/yourlog/filename.log"
Set ^ISCSOAP("Log")="ios"

Values for ^ISCSOAP("Log") are:
"i" — Log inbound messages
"o" — Log outbound messages
"s" — Log security information.

Then call your SOAP service and check the log file for hints on the actual issue.

When finished debugging remember to turn it off with Set ^ISCSOAP("Log")="" or Kill ^ISCSOAP("Log")

In error handling code, when using SOAP and a <ZSOAP> error in triggered, the actual error status is contained in %objlasterror variable, so:

Set displayString = ex.DisplayString()
If displayString [ "<ZSOAP>" {
    Set displayString=$system.Status.GetErrorText(%objlasterror)
}

It's all documented, I cannot post documentation links because the documentation site it's not working for me at the moment.

Enrico Parisi · Nov 28, 2024 go to post

According to the documentation, it's not possible exporting an object.

Edit: however, as pointed out by @Herman Slagman in the next post, it's indeed possible, I'm going to provide feedback to documentation team.

You can manually create the XML document using %XML.Writer, like:

	set writer=##class(%XML.Writer).%New()
	set writer.Indent=1
	set writer.NoXMLDeclaration=1
	set status=writer.OutputToDevice()
	set status=writer.StartDocument()
	set status=writer.RootElement("XMLTest")
	set status=writer.Element("Id")	
	set status=writer.WriteAttribute("Attribute","D1949EE1-7D03-4666-9548-D1A949E10327")
	set status=writer.EndElement()
	set status=writer.EndRootElement()
	set status=writer.EndDocument()

The output of the above code is:

<XMLTest>
  <Id Attribute="D1949EE1-7D03-4666-9548-D1A949E10327"/>
</XMLTest>

Having said that, what's your issue with the closing tag? Semantically there is no difference, any system should be able to handle both cases (with or without closing tag).

Enrico Parisi · Nov 28, 2024 go to post

My guess is that your %var local variable array is in conflict with the code executed by the embedded sql.

As you may know % local variables have global scope, therefore should be used with caution, particularly when calling "other code", like embedded sql in your case.

If a global scope % variable is needed, is advisable to follow the documentation on Local Variable Naming Convention:

Variable names starting with the % character are known as “percent variables” and have different scoping rules. In your code, for a local percent variable, start the name with %Z or %z; other names are reserved for system use.

I suggest to change your variable to %zvar or similar, if you do not need global scoping, remove the leading %.

Enrico Parisi · Nov 21, 2024 go to post

The time Veeam create a snapshot should be measured in seconds, not minutes!

If your server does not use/need any application guest processing (Oracle etc.), then in Veeam you can be disabled in "Application-Aware Processing Options" in the Backup Job configuration for your Suse IRIS server , "Disable application processing":

As @Timo Lindenschmid pointed out, you may consider backing up the secondary server.

In case you want to backup the primary, make sure to set mirror QoS appropriately.

Enrico Parisi · Nov 21, 2024 go to post

Ciao Pietro,

difficult to tell without looking at the code.

Looking at the response my guess (bet?😉) is that your code  has some error processing and if "somewhere" an error status is returned, then the error processing is triggered and is returning the response you see, including headers etc.

Enrico Parisi · Nov 20, 2024 go to post

In the documentation site (every page?) there is a "Feedback" blue button on the right of the page, click on it...

Enrico Parisi · Nov 15, 2024 go to post

Julian is correct, your code is inserting line breaks, remove the lines:

    If 'pInput.AtEnd {
        Set tSC = tStream.Write($C(10))
        $$$TRACE("Adding terminator.")
    }
Enrico Parisi · Nov 11, 2024 go to post

Since it's a vmware issue, not an InterSystems issue, I think you should ask vmware (now Broadcom).

Enrico Parisi · Nov 8, 2024 go to post

What's the status returned by the Send() method of %Net.SMTP class?
I believe it should contain some info.

Enrico Parisi · Nov 7, 2024 go to post

Your Business Operation (is supposed to) use the EnsLib.EMail.OutboundAdapter, but the in the code you use the %Net.SMTP class directly, ignoring the adapter.

In the Interoperability portal your implementation  provide the email adapter configuration (server, certificate, credentials etc. etc.) that in fact are then ignored in the code. This makes it very confusing for anyone using the portal, now...and in the future!

So the first question is, do you want to use the EnsLib.EMail.OutboundAdapter or not?

If you want to use the adapter, if you have not already done it, I suggest to start with the documentation:

Using the Email Outbound Adapter and Settings for the Email Outbound Adapter

If you don't what to use the EnsLib.EMail.OutboundAdapter, then remove the reference from your code.

Using %Net.SMTP class directly (right?), you said that "...I get the error that the property UseSTARTTLS is not available." and this is very strange, can you confirm you are using IRIS version 2021.1?
Is your code the same as in your first post or has changed? If changed, can you post the modified code that fail?

Last but not least, are you sure your outlook.com account allow user/password authentication? Or you must use OAuth2 authentication??

Enrico Parisi · Nov 6, 2024 go to post

Evidently "The first 4KB of the stream cannot be compressed by at least 20 percent."

Demonstration:

USER>set data="" for i=1:1:400 set data=data_"a"_i
 
USER>set compressed=##class(%SYSTEM.Util).Compress(data,"lz4")
 
USER>write $length(data)," - ",$length(compressed),!
1492 - 1481
 

P.S.: IRIS use lz4 compression for streams

Enrico Parisi · Nov 6, 2024 go to post

From Stream Compression documentation:

.....new stream data is automatically compressed, except for the following cases, where the data is not suitable for compression:

  • The stream can be stored in a single chunk less than 1024 characters long.
  • The stream is already compressed, that is, the first chunk of data matches a typical compressed file format, such as JPEG, MP3, or ZIP.
  • The first 4KB of the stream cannot be compressed by at least 20 percent.

I guess your test runs into these cases.

Enrico Parisi · Nov 6, 2024 go to post

Rules are subclasses of Ens.Rule.Definition class, to list rules you can use the class query SubclassOf in the %Dictionary.ClassDefinition class.

From ObjectScript:

Set rs=##class(%Dictionary.ClassDefinition).SubclassOfFunc("Ens.Rule.Definition")
Do rs.%Display()

From SQL:

Call %Dictionary.ClassDefinition_SubclassOf('Ens.Rule.Definition')

Enrico Parisi · Nov 4, 2024 go to post

You can Export from DEV using:

Set status=##class(EnsLib.DICOM.Util.AssociationContext).ExportXML()

And import in PROD with:

Set status=##class(EnsLib.DICOM.Util.AssociationContext).ImportXML()

See class reference documentation.

Enrico Parisi · Nov 4, 2024 go to post

You did not specify the IRIS version, so I assume you are using the latest version.

You can export the source of a class to a file:

Do $system.OBJ.ExportUDL("My.Class.Name.cls","/full/path/My.Class.Name.cls")

Enrico Parisi · Nov 1, 2024 go to post

What's your use case? Are you using Ens.BusinessProcess or Ens.BusinessProcessBPL?

Enrico Parisi · Oct 30, 2024 go to post

I don't think there is a ready to use SQL query/procedure but you can call the class query "TypeCategories" in the class "EnsLib.HL7.Schema" from ObjectScript:

	set ResultSet=##class(EnsLib.HL7.Schema).TypeCategoriesFunc()
	do ResultSet.%Display()
Enrico Parisi · Oct 30, 2024 go to post

In the documentation page there is a "Feedback" button/link on the right, I encourage you to provide your comments as Feedback, possibly linking this post in the Community.

Enrico Parisi · Oct 29, 2024 go to post

Hi Timo, your sample is not a valid/full check for "valid number":

USER>set number="123.40"
 
USER>write (+number=number)
0
USER>write $isvalidnum(number)
1
Enrico Parisi · Oct 28, 2024 go to post

True, but the problem definition is:

If both fields are numeric and the result of subtraction of field1-field2 is positive.

My understanding/interpretation is that the subtraction and further test should be performed only "If both fields are numeric", so the code should check that condition.

If the first part of the problem (If both fields are numeric) is irrelevant....then the question/problem definition is misleading.

Enrico Parisi · Oct 27, 2024 go to post

Use XML format and you get 6x faster load than using UDL.

My guess the difference is due to the parsing needed by UDL import.

My estimate in your case you can get as low as 42 seconds, I'm curious to see the actual numbers.