#InterSystems IRIS

19 Followers · 5.5K Posts

InterSystems IRIS is a Complete Data Platform
InterSystems IRIS gives you everything you need to capture, share, understand, and act upon your organization’s most valuable asset – your data.
As a complete platform, InterSystems IRIS eliminates the need to integrate multiple development technologies. Applications require less code, fewer system resources, and less maintenance.

Article Iryna Mykhailova · Mar 31, 2023 3m read

Saw the other day an article with the usage of the %ZEN package when working with JSON and decided to write an article describing a more modern approach. At some recent point, there was a big switch from using %ZEN.Auxiliary.* to dedicated JSON classes. This allowed to work with JSONs more organically.

Thus, at this point there are basically 3 main classes to work with JSON:

  • %Library.DynamicObject - provides a simple and efficient way to encapsulate and work with standard JSON documents. Also, there is a possibility instead of writing the usual code for creating an instance of a class like
set obj = ##class(%Library.DynamicObject).%New()

it is possible to use the following syntax

set obj = {}
  • %Library.DynamicArray - provides a simple yet efficient way to encapsulate and work with standard JSON  arrays. With arrays you can use the same approach as with objects, meaning that yu can either create an instance of the class
set array = ##class(%DynamicArray).%New()

or you can do it by using brackets []

set array = []
  • %JSON.Adaptor is a means for mapping ObjectScript objects (registered, serial or persistent) to JSON text or dynamic entities.
5
2 1974
Question Pietro Di Leo · Oct 16, 2023

Hi everyone, 

My problem today is how to send an HTTP message to a web service deployed via Render and gunicorn. 

Issue

Every time I try to contact the web service I get an error. Searching on the web, I've found this StackOverflow question that suggests the issue could be set off from a missing "/" character in the endpoint string.

I've tried in many ways, both including and excluding the final slash character, but I always get an error:

  1. When using a URL without the final slash (e.g., https://<renderProjectName>.onrender.com), the message is successfully sent but I get the error HTTP/1
4
0 348
Discussion Scott Roth · Oct 12, 2023

I am trying to move us to Securing the Management Portal using Apache and the Web Gateway.

Our Development environment/namespace only has 1 server, but both Test and Production have failover/DR mirroring containing 3 servers for Test, and 3 additional servers for Production. 

  • Development - 1 server
  • Test -2 server's setup for Failover, and 1 Async DR Mirror
  • Production - 2 servers' setup for Failover, and 1 Async DR Mirror

In Test and Production, the mirroring is setup using an Arbiter and the VIP address is controlled at the Hardware level.

  • Should I have 1 centralized location for t
4
0 399
Question Padmaja Konduru · Oct 16, 2023

Could you please help anyone how to import Python package in %SYSTEM package and to use python methods to write in object script class?

I used the following link to install the Python but I can't see the Python package in %SYSTEM package and my program throwing the Class Does not exist error?

https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cl…

Please help on this..

5
0 764
Announcement Luis Angel Pérez Ramos · Oct 19, 2023

It's true! QuinielaML has incorporated the most important leagues in Europe (and Brazil) into its prediction service, so, dear members of the Developer Community, wherever you are from, you will be able to have the predictions of your favorite leagues at your disposal.

From the predictions screen you will have access to each of the new leagues included, being able to record the matches for each journey:

Taking advantage of the progress of the league, we have improved the QuinielaML prediction model by reducing the weight of historical results that weighed down some of the predictions and

Amazon Proclaims Amazon's 'Borat 2' To Be 'Great Success'

0
0 199
InterSystems Official Fabiano Sanches · Oct 18, 2023

InterSystems announces its third developer preview for the 2023.3 release of InterSystems IRIS® and InterSystems IRIS for HealthTM.

Future preview releases are expected to be updated biweekly and we will add features as they are ready.

Please share your feedback through the Developer Community so we can build a better product together. Initial documentation can be found at these links below. They will be updated over the next few weeks until launch is officially announced (General Availability - GA):

Highlights

There are several exciting

0
0 311
Question Adrian Howe · Oct 16, 2023

Hello,

I have a problem attempting to store a base 64 encode stream into the OBX:5 field of a HL7 message, by using the StoreFieldStreamBase64 method.

I'm using a transformer to input the contents of a pdf within a stream container (Ens.StreamContainer). The output is a HL7 message (EnsLib.HL7.Message 2.5:ORU_R01).

The transformer is being used in a business process.

This is the code used in the transformer to encode the stream to base 64:

Try {
     Set pdfStreamObj = source.StreamGet()
   } Catch {
      Quit
   }

 //Set PDF stream object into OBX:5
   Set status = target.StoreFieldStreamBa

2
0 533
Article Luis Angel Pérez Ramos · Aug 25, 2023 4m read

Taking advantage of the Quiniela ML application and as we indicated in the previous article, we are going to explain how we can perform a JWT authentication between our frontend developed in Angular and our backend developed in InterSystems IRIS.

I remind you of the architecture of our QuinielaML project:

Usually it is a cumbersome process in web applications to develop the administration and management of user access, but in our case InterSystems IRIS simplifies the process by providing us with all the infrastructure we need.

JSON Web Token Authentication

IRIS provides web applications

11
2 602
Question Dmitrij Vladimirov · Sep 18, 2023

Hello community, I need to solve a complex but trivial issue.

Given:

Two tables "Comment" and "Post". Each one contains an "Author" field, which is essentially a user ID. In these tables, each user ID represents an author. The goal is to count all participants together and then group them by month, language, and other metrics.

The question is how to do this within the IRIS ecosystem. Is it even possible to take two tables, get distinct data from them and then combine into one cube?

1
0 241
Question Ashok Kumar T · Sep 29, 2023

Hello Community,

I have couple of question about the DynamicSQL.

1. The %ObjectSelectMode is working perfectly in the DynamicSQL for the object property in direct query. However this is not supported for class query. Is there any way to resolve this / Get the object value for class query result.

2. What is the reason behind for a stored query prepared using %PrepareClassQuery() you must use the %Get("fieldname") method.

Class Samples.DB.NewClass1 Extends%Persistent
{
Property Address As NewClass3;ClassMethod TestQuery()
{ 
	set statement = ##class(%SQL.Statement).%New()
	set statem
3
0 457
Article David Hockenbroch · Oct 4, 2023 8m read

We are back to %SYS once again! Since we covered managing users and resources in the last two articles, we can finally move on to roles. As you may have guessed, there are a lot of methods of managing them that you have already seen in our previous writings. However, we can still encounter key differences in this particular class.

Before we begin, bear in mind that this is another class that should not be manipulated through direct SQL access. In newer versions of IRIS, you will find a NoSQL trigger that will prevent you from doing that anyway. However, if you have an older version of Cache,


3
5 730
Article Mihoko Iijima · Oct 12, 2023 1m read

InterSystems FAQ rubric

ObjectScript allows you to pass any number of arguments using arrays. Do it by adding ... after the argument name.

An example is as follows. In the example statement, the argument information is set in a global variable (a variable stored in the database) so that it can be easily checked after the method is executed.

Class TEST.ARGTEST1 Extends%RegisteredObject
{
ClassMethod NewMethod1(Arg... As %StringAs %Boolean
{
 kill ^a
 merge ^a = Arg
}
}

The result of running it in the terminal is as follows.

USER>DO##class(TEST.ARGTEST1).NewMethod1(1,2,3,4,5)
US
1
0 520
Question Yone Moreno · Oct 11, 2023

Hello,

First of all; thanks for your time reading this post, and thanks for your answers and help. I am really grateful.

We have the following need: Send a DICOM Find Document to get the complete list of a patient's studies from an Outbound System, which we simulate with the tool called "dcm4che" specifically with these two commands:

1º.Initialize a DICOM database in simulator. We will use this database to run queries using DICOM C-FIND commands:

./dcmdir -c ./shared/DICOMDIR --fs-id SAMPLEDICOMS --fs-desc ./shared/dicom/descriptor ./shared/dicom

2ºStart simulated DICOM archive that us


14
0 431
Question Robert Cemper · Oct 15, 2023

MIRROR is the best solution for almost immediate replications to a Failover Server.
The related mechanics are based on Global Journaling.

Globals hold Data and Classes and Routines and more ...
If Mirroring is in place all is in sync. With minimum delays
This is of course  rather useful for code changes in Classes, Routines, ....

To what extent is Embedded Python covered by Mirroring?
Or:
What is required to Synchronize EmbeddedPython like Mirroring. 

2
0 250
Question Robert Cemper · Oct 15, 2023

With ECP we have the option to have a collection of Frontend instances
All Frontend servers typically have a common Master in the background
Concentrating data on the Master server is the primary goal.

As a side effect, this applies also to Classes, Routines, .. anything stored in Globals.
This is probably not the most efficient setup. But rather common anyhow.

Is embedded Python code also stored in Globals?

What is the recommended solution for a similar installation?

2
0 264
Question prashanth ponugoti · Oct 13, 2023

Hi Friends ,

We have a use case to search a given word in pdf and based on the result i need to send pdf to particular outbound system.

Here we used to do with some java library help in oracle soa integrations , now we are migrating oracle soa to intersystems .

Please help me if we have any library available in objectscript cahe.

Thanks,

Prashanth

1
0 275
Article Eduard Lebedyuk · Oct 13, 2023 1m read

For containers in ECS files are not editable if the file size is larger than ephemeral storage free space. For example if I have 4Gb free I can't edit 8Gb file. But if I start container with 50 Gb of ephemeral storage (24Gb free) I can edit my 8Gb file just fine. Even file attributes cannot be changed: chattr -i <file> fails if the amount of free ephemeral storage is not enough (and so db can't be mounted for writing).

This can cause iris container failure on startup if large DB is both RW and mounted on start. Possibly it can cause container to fail during runtime if the DB grows above a

0
0 373
Question Gautam Rishi · Oct 4, 2023

Hi all,
I am trying to compile my swagger class file with swagger JSON which is a valid JSON as I created it and verified from swagger.io 2.0 spec.
But getting below error. I am not very clear with the error message. Please help me resolve the same.
ObjectScript error: <CLASS DOES NOT EXIST>removeprj+7^%occClass *SwaggerClass

> ERROR #5091: An error has occurred while removing projection SwaggerClass:Reference.

> ERROR #5030: An error occurred while compiling class 'SwaggerClass'

1
0 283
Announcement Henrique Dias · Feb 12, 2023

Attention all developers!

Get ready to revolutionize your testing process with iris-tripleSlash, the ultimate unit test solution.

Say goodbye to boring and repetitive unit testing and hello to effortless and efficient testing.

With iris-tripleSlash, you can easily generate unit test cases using the power of automatic documentation.

2
0 358
InterSystems Official Bob Kuszewski · Oct 11, 2023

InterSystems has made the decision to stop further development of the InterSystems Cloud Manager and label it as deprecated as of the InterSystems IRIS 2023.3 release.  InterSystems will continue to support existing customers using the technology, but it is no longer recommended for new deployments.

Customers in the cloud who are interested in deploying and managing an IRIS deployment with many systems are encouraged to consider Kubernetes and the InterSystems Kubernetes Operator, which has very similar functionality to ICM.

Customers with questions on their current or planned use of ICM sho

0
0 527
Question Emil Odobasic · Oct 10, 2023

Hello everyone!
I have manually created a REST-service that receives incoming HTTP-GET calls together with an URL-map. As shown below:

XData UrlMap [ XMLNamespace = "https://www.intersystems.com/urlmap]
{
<Routes>
<Route Url="/testGet" Method="GET" Call="Handler" />
</Routes>
}

ClassMethod Handler(req As %Stream.Object) As %Status
{
set Class = ##class(Ens.Request).%New()

set status = ##class(Ens.Director).CreateBusinessService("TestService", .instance)
set status = instance.OnProcessInput(Class, .response)

if $ISOBJECT(response)
{
         write response.%ToJSON()
}Quit $$$OK
}

Through the c

6
0 486
Question Norman W. Freeman · Oct 4, 2023

I have some code that fire this kind of request very often : 

set request = ##class(%Net.HttpRequest).%New()
set request.Server = ... //always the same set request.Location = ... //always the same do request.EntityBody.Write(...) //this is different from one request to anotherdo request.Post() 

If it was called in a loop I could move the HttpRequest instantiation outside, unfortunately this is not the case. The code is called from lot of different places.

I have been wondering if there is a class in IRIS that already implement a connection pool
Eg: a set of connections is maintained a

3
0 328
Question Timothy Leavitt · Sep 12, 2023

It's a feature of ObjectScript (perhaps widely known, perhaps not) that if you open the same object ID multiple times, you end up with the same OREF. For example:

USER>set obj1 = ##class(Sample.Person).%OpenId(1)
 
USER>set obj2 = ##class(Sample.Person).%OpenId(1)

USER>w obj1,!,obj2
1@Sample.Person
1@Sample.Person

Generally speaking, this is an important feature - you won't end up accidentally modifying the same record via multiple paths and losing some of the changes.

I have a use case, though, where in %OnBeforeSave I want to actually get the old version of the object (and, theoret

10
2 508
Question Rob Tweed · Oct 10, 2023

I'm using a customised IRIS Community Edition Docker Container: Node.js has been added and the Native API for Node.js directory moved to a node_modules folder in /home/irisowner.  I've changed the _SYSTEM password using the Management Portal (which connects to IRIS just fine)

If I shell into the running container and try to connect with a JS script file containing this:

        const IRISNative = require('intersystems-iris-native');

        let connectionInfo = {

          host: 'localhost',

          port: 1972,

          ns: 'USER',

          user: '_SYSTEM',

          pwd: 'secret',

2
0 260
Question Rob Tweed · Oct 10, 2023

I think there have been articles published here before but I'm struggling to find them:

I'd like to be able to create my own customised version of the official IRIS Community Edition Container, eg with Node.js and a number of modules pre-installed.  So, for example, can I create my own Dockerfile that begins with something like:

         FROM containers.intersystems.com/intersystems/iris-community-arm64:2023.2.0.227.0

and then I can add my own stuff to it?

... or is there another recommended approach?

Any info appreciated

4
0 501
Question Dmitry Maslennikov · Oct 10, 2023

Is there any solution to how to purge the usage of the connection in Community Edition?

I have a working portal, where can't do even any simple SQL Query

Why? Because somehow I've exceeded a license limit (pardon, connection limit, when it comes to Community Editon)

So, this page shows, 8 users ate all connections

This page is useless, 0 connections in use

And this page is useless too, even when I have matches from the usage list, I can do nothing with

Recently, I posted an idea, to make Community Edition limited by resources, not by connections, it would help a lot, but it

5
0 390