iris-docker-multi-stage-script

A python script to keep your docker iris images in shape ;)

Witout changing your dockerfile or your code you can reduce the size of your image by 50% or more !

TL;DR

Name the builder image builder and the final image final and add this to end of your Dockerfile:

Modify your Dockerfile to use a multi-stage build:

ARG IMAGE=intersystemsdc/irishealth-community:latest
FROM $IMAGE as builder

Add this to end of your Dockerfile:

FROM $IMAGE as final

ADD --chown=${ISC_PACKAGE_MGRUSER}:${ISC_PACKAGE_IRISGROUP} https://github.com/grongierisc/iris-docker-multi-stage-script/releases/latest/download/copy-data.py /irisdev/app/copy-data.py

RUN --mount=type=bind,source=/,target=/builder/root,from=builder \
    cp -f /builder/root/usr/irissys/iris.cpf /usr/irissys/iris.cpf && \
    python3 /irisdev/app/copy-data.py -c /usr/irissys/iris.cpf -d /builder/root/ 

Boom! You're done!

12 8
7 564

Hi developer folks!

Thanks to all of you who start the development with InterSystems IRIS from the basic development template!

Recently, thanks to @Dmitry Maslennikov's contributions I've updated the Dockerfile to make the development simpler, images lighter and the building process faster. And it looks more beautiful too ;)

Here is what changed:

11 4
2 399
Article
· Sep 26, 2023 1m read
Create JSON Objects and Arrays by SQL

The related package avoids adding %JSONAdaptor to each class but uses instead
SQL functions JSON_OBJECT() to create my JSON objects. With this approach, you can
add JSON to any class - even deployed ones - without any need for change or recompiling.

The trigger was the Export of M:N relationships as JSON objects or arrays.

11 0
0 307
Article
· Dec 25, 2021 2m read
AOC2021-rcc

After >40 years of writing in-countable lines of code in M*/COS/ISOS (and a bunch of archaic languages)
I decided for myself to set a strong signal for the future. We have Embedded Python available
(still pre-release)! I just felt it as a sacrilege to ignore this excellent NEW opportunity and
stay with the old sermon that I had used for decades.

11 0
0 289

Hi all,

When is a Developer Community post not a Developer Community post? When it's just a few sentences wrapped around a link to InterSystems documentation! And what better way to finish up 2021 than by telling you about something cool that's been available since v2020.3? As the ball drops in Times Square, curl up with this:

Repeating Previous Commands

11 31
1 1.1K
Article
· Feb 8, 2019 2m read
Client Websockets based CSP

The Caché / Ensemble standard distribution contains in namespace SAMPLES
a nice example of a CSP page consuming WebService as a Client.
I have modified it not only to display the replies but to feed them back into a Global.
I used the classic Hyperevent to achieve this. The replies end up as a log in global^WSREPLY.
When there is no input anymore the page closes and goes away.

There are 2 versions with visible and hidden display during operation.
dc.WSCSP.reverseVerbose.cls and dc.WSCSP.reverseHidden.cls

11 0
0 475

InterSystems is pleased to announce a new Developer Download site providing full kit versions of InterSystems IRIS Community Edition and InterSystems IRIS for Health Community Edition. These are available free of charge for application development use.

You can download directly from the InterSystems Developer Community by selecting Download InterSystems IRIS.

11 13
0 3.1K

Adding VSCode into your IRIS container

One of the easiest ways to setup repeatable development environments is to spin up containers for them. I find that when iterating quickly, it was very convenient to host a vscode instance within my development container. Thus, I have created a quick container script to add a browser-based vscode into an IRIS container. This should work for most 2021.1+ containers. My code repository can be found here

11 5
0 744

A customer recently asked if IRIS supported OpenTelemetry as they where seeking to measure the time that IRIS implemented SOAP Services take to complete. The customer already has several other technologies that support OpenTelemetry for process tracing. At this time, InterSystems IRIS (IRIS) do not natively support OpenTelemetry.

11 4
1 264

As IRIS was announced yesterday by Paul Grabscheid I would be highly interested to get in touch with it.

- How can we get qualified for a closer view ?
- Where can we get some (preliminary) description + documentation.
- Is there any FT available ?

I'm especially interested in the areas around included/embedded/attached JVM and SPARK .

11 3
0 654
Article
· Apr 21, 2021 1m read
Ctrl+C / Ctrl+V in IRIS Terminal

It's possible to enable Ctrl+C / Ctrl+V in IRIS Terminal for Windows.

To do that, open Terminal and select Edit > User Settings and enable Windows edit accelerators. This setting specifies whether the Terminal enables the common Windows edit shortcuts (Ctrl+C, Ctrl+V, Ctrl+Shift+V), in addition to the basic Terminal edit shortcuts (Ctrl+Insert and Shift+Insert).

After that Ctrl+C / Ctrl+V would work.

Also <SYNTAX> errors after incorrect copy/paste go away.

Docs.

11 7
1 331

Here you'll find a simple program that uses Python in an IRIS environment and another simple program that uses ObjectScript in a Python environment. Also, I'd like to share a few of the troubles I went trough while learning to implement this.

Python in IRIS environment

Let's say, for example, you're in an IRIS environment and you want to solve a problem that you find easy, or more efficient with Python.

You can simply change the environment: create your method as any other, and in the end of it's name and specifications, you add [ Language = python ]:

11 9
5 1.4K
Article
· Sep 18, 2023 7m read
Vectors support, well almost

Nowadays so much noise around LLM, AI, and so on. Vector databases are kind of a part of it, and already many different realizations for the support in the world outside of IRIS.

Why Vector?

  • Similarity Search: Vectors allow for efficient similarity search, such as finding the most similar items or documents in a dataset. Traditional relational databases are designed for exact match searches, which are not suitable for tasks like image or text similarity search.
  • Flexibility: Vector representations are versatile and can be derived from various data types, such as text (via embeddings like Word2Vec, BERT), images (via deep learning models), and more.
  • Cross-Modal Searches: Vectors enable searching across different data modalities. For instance, given a vector representation of an image, one can search for similar images or related texts in a multimodal database.

And many other reasons.

So, for this pyhon contest, I decided to try to implement this support. And unfortunately I did not manage to finish it in time, below I'll explain why.

11 7
4 860

Artificial Intelligence (AI) is getting a lot of attention lately because it can change many areas of our lives. Better computer power and more data have helped AI do amazing things, like improving medical tests and making self-driving cars. AI can also help businesses make better decisions and work more efficiently, which is why it's becoming more popular and widely used. How can one integrate the OpenAI API calls into an existing IRIS Interoperability application?

11 5
3 216

csp-log-tutorial

Prerequisites

Make sure you have git installed.

I created a git folder inside the IRIS mgr directory. I right clicked the git folder and chose Git Bash Here from the context menu.

git clone https://github.com/oliverwilms/csp-log-tutorial.git

Clone my csp-log-tutorial GitHub repo if you like to try it out for yourself.

11 1
0 283

Hey Developers,

You asked - we did it! We're glad to announce the next competition for InterSystems Developers! Please welcome:

🏆 InterSystems Programming Contest: Developer Tools 🏆

Submit an application that helps to develop faster, contribute more qualitative code, helps in testing, deployment, support, or monitoring of your solution with InterSystems IRIS.

Duration: March 29 - April 25, 2021

Total prize: $8,500

11 16
1 3.2K

Last week saw the launch of the InterSystems IRIS Data Platform in sunny California.

For the engaging eXPerience Labs (XP-Labs) training sessions, my first customer and favourite department (Learning Services), was working hard assisting and supporting us all behind the scene.

11 3
0 980
Article
· Sep 14, 2020 3m read
IRIS Native API for ObjectScript

It seems to me that for some reason this didn't make its way to the official documentation
and seems to be rather unknown though implemented already in IRIS 2020.1

Thanks to @Dan Pasco I got a hint on the classes involved.
I used the recommended sequence of how to use it.
it is all directly taken from Class Reference and I just collected it to create a first overview.

11 1
2 623
Article
· May 30, 2022 3m read
ObjectScript Syntax For GitLab

Hi Community,

Recently, I migrated a series of Objectscript repositories from XML to UDL format.
After the migration, I was a bit disappointed by the presentation on the GitLab web interface.

Since Objectscript syntax is supported by GitHub, I thought It would be also supported by GitLab. Unfortunately, the library used by GitLab to highlight the code does not have an extension to support Objectscript.

11 1
2 473
Article
· Jul 25, 2022 8m read
Introduction to Django part 2

In the first part, I've shown how to start a new project on Django, as well as define new models and add already existing models.

This time, I'll introduce an admin panel, available out of the box and how it can be useful.

Important note: do not expect that if you try to repeat actions from this post it will work for you, it does not. During the article, I had to do some fixes in the django-iris project, and even in DB-API driver made by InterSystems to fix some issues there as well, and I think this driver is still in development, and we will get more stable driver in future. Let's decide that this article only explains how it could be if we would have all done.

11 2
0 364

Released with no formal announcement in IRIS preview release 2019.4 is the /api/monitor service exposing IRIS metrics in Prometheus format. Big news for anyone wanting to use IRIS metrics as part of their monitoring and alerting solution. The API is a component of the new IRIS System Alerting and Monitoring (SAM) solution that will be released in an upcoming version of IRIS.

11 2
7 1.8K