Clear filter
Article
Eduard Lebedyuk · Mar 13, 2018
In this series of articles, I'd like to present and discuss several possible approaches toward software development with InterSystems technologies and GitLab. I will cover such topics as:Git 101Git flow (development process)GitLab installationGitLab WorkflowContinuous DeliveryGitLab installation and configurationGitLab CI/CDIn the first article, we covered Git basics, why a high-level understanding of Git concepts is important for modern software development, and how Git can be used to develop software.In the second article, we covered GitLab Workflow - a complete software life cycle process and Continuous Delivery.I this article we'll discuss:GitLab installation and configurationConnecting your environments to GitLabGitLab installationWe're going to install GitLab on premise. There are many ways to install GitLab - from source, package, in a container. I'm not actually going to describe all the steps here, there is a guide for that. But still, some notes.Prerequisites:Separate server - since it's a web application and a fairly resource intensive it's better to run it on a separate serverLinux(Optional but strongly recommended) Domain - required to run pages and secure the whole setupConfigurationFirst of all, you'd probably need to send emails with notifications.Next, I recommend installing Pages. As we discussed in the previous article - artifacts from the script can be uploaded into GitLab. User can download them but it's useful to be able to open them directly in browser and for that we need pages.Why do you need pages:To display some generated wiki or a static page for your projectTo display html artifactsOther stuff you can do with pagesAnd as html pages can have an onload redirect, they can be used to send the user wherever we need. For example here's the code that generates html page which sends a user to the last executed unit test (at the moment of html generation):
ClassMethod writeTestHTML()
{
set text = ##class(%Dictionary.XDataDefinition).IDKEYOpen($classname(), "html").Data.Read()
set text = $replace(text, "!!!", ..getURL())
set file = ##class(%Stream.FileCharacter).%New()
set name = "tests.html"
do file.LinkToFile(name)
do file.Write(text)
quit file.%Save()
}
ClassMethod getURL()
{
set url = "http://host:57772"
set url = url _ $system.CSP.GetDefaultApp("%SYS")
set url = url_"/%25UnitTest.Portal.Indices.cls?Index="_ $g(^UnitTest.Result, 1) _ "&$NAMESPACE=" _ $zconvert($namespace,"O","URL")
quit url
}
XData html
{
<html lang="en-US">
<head>
<meta charset="UTF-8"/>
<meta http-equiv="refresh" content="0; url=!!!"/>
<script type="text/javascript">window.location.href = "!!!"</script>
</head>
<body>
If you are not redirected automatically, follow this <a href='!!!'>link to tests</a>.
</body>
</html>
}
There's is a bug I encountered using pages (502 error when browsing artifacts) - here's a fix.
Connecting your environments to GitLab
To run CD scripts you need environments - configured servers to run your application. Assuming you have a Linux server with InterSystems product installed (let's say InterSystems IRIS, but it would work with Caché and Ensemble too) these steps would connect environment to GitLab:
Install GitLab runnerRegister runner with GitLabAllow runner to call InterSystems IRIS
Important note on installing GitLab runner - DON'T clone servers after you installed GitLab runner. Results are unpredictable and most unwelcome.
Register runner with GitLab
After you run the initial:
sudo gitlab-runner register
you'd be presented with several prompts and While most of the steps are fairly straightforward several are not:
Please enter the gitlab-ci token for this runner
There are several tokens available:
One for the whole system (available in administration settings)One for each project (available in project settings)
As you connect a runner to run CD for a specific project you need to specify a token for this project.
Please enter the gitlab-ci tags for this runner (comma separated):
In your CD configuration, you can filter which scripts run on which tags. So in the most simple case specify one tag which would be environment name.
Please enter the executor: ssh, docker+machine, docker-ssh+machine, kubernetes, docker, parallels, virtualbox, docker-ssh, shell:docker
If you're using the usual server without docker choose shell. Docker would be discussed in the later parts.
Allow runner to call InterSystems IRIS
After connecting runner to GitLab we need to allow it to interact with InterSystems IRIS, to do that:
gitlab-runner user should be able to call csession. To do that add him to cacheusr group:
usermod -a -G cacheusr gitlab-runnerCreate gitlab-runner user in InterSystems IRIS and give him roles to do CD tasks (write to DB, etc)Allow OS-level authentication
For 2 and 3 other approaches can be used, such as passing user/pass but I think that OS authentication is preferable.
Conclusion
In this part:
Installed GitLabConnected environments to GitLab
Links
Installation instructionsPagesRunnerPart I: GitPart II: GitLab workflow
What's next
In the next part, we'd write our Continuous Delivery configuration. Hi Eduard,
I have followed your Article. On our own Linux environment it works well but when I try to run it on a clients windows server; and the following command is run by the runner
irissession IRISHEALTH -U TEST "##class(isc.git.GitLab).load()"
we get the following "error"
<NOTOPEN>>
I do not know why this happens, it does look like it has something to do with user rights but I am totally lost at this point as we have done everything I can think off relating to grant correct access etc.
Do you perhaps have something you can point me to to try and get this working, the client running the Windows server does does not want to move to Linux as they do not have IT people that can work on it. 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.
Question
Ricardo Alves dos Santos · May 29
Hello everyone,
I’m using VS Code with the InterSystems ObjectScript extension and I want to keep my local folder (client-side) as the “source of truth” while still using the built-in Server Source Control features (diff, stage, commit, etc.) against my IRIS/Ensemble instance.
So far:
I have a local Git repository with my .cls and .mac files.
I’ve configured "objectscript.serverSourceControl.respectEditableStatus": true and "objectscript.serverSourceControl.disableOtherActionTriggers": false in my .vscode/settings.json.
I’m able to export and import code manually, and IntelliSense works when I export my server code locally.
However, when I edit files in my local folder, I don’t see the “Source Control” icons or context-menu actions injected by the ObjectScript extension—those only appear when I open files under the ISFS server mount.
What I’d like to achieve:
Edit files locally in my Git project.
On save (or via a keyboard shortcut), push changes to the server (export & compile).
Use the ObjectScript Source Control UI (icons, diff, commit…) directly on those local files without manually opening the ISFS folder.
Has anyone successfully configured a fully client-side workflow that still leverages the extension’s Server Source Control features? Are there additional settings, workspace layouts (multi-root?), or keybindings I should use to bridge the gap between my local edits and the server’s Source Control UI?
Thank you in advance for your guidance! For anyone else who may be interested, here is my answer to @Ricardo.AlvesdosSantos's question that I provided on the GitHub Discussion he opened:
The extension intentionally doesn't support what you want to do. You have to pick a side. Since you're using Git and are happy to edit the files on your local file system, I suggest you turn off source control on the server and fully embrace the client-side editing workflow. Your local file system will be the "source of truth" and the extension will sync files with the server on save and compile them. The only change is that instead of using IRIS to run the source control actions, you can use any number of industry-standard Git-compatible tools. VS Code works well with Git out of the box, and there are additional extensions you can install to make that experience even better. You can also use a different GUI application like GitHub Desktop or Sourcetree, or the git CLI directly.
Question
Mohamed Ashik · Jun 20, 2020
I have a set of strings that contains special characters. Im trying to write a sql query to remove all the special characters in the string. Im using Intersystems cache sql.
Example
%Lis&ten - Listen you can use $ZSTRIP retrieve the specified string, for more information you can refer https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=RCOS_fzstrip This helps alot, Thank you Dhinupa. if you know exactly what characters you want to remove you may use $TRANSLATE (in SQL) !
docs: https://cedocs.intersystems.com/latest/csp/docbook/Doc.View.cls?KEY=RSQL_d_translate characters are random, it can be any of the special characters. but yeah i was able to use this directly in my query. Thank you :)
Article
Victor Sanner · Apr 20, 2022
Hi,
I have wrote an article about how to install the intersystems cache driver in a Docker container, and then deploy it using Azure Functions:
How to run a (Python) Azure Function as a Docker container & Deploy it using Bicep | Victor SannerThis might be useful to others, especially the dockerfile which I have copied below. This builds a debian docker container and installs the Intersystems Cache driver, which python can then use :)
To enable ssh & remote debugging on app service change the base image to the one below
# FROM mcr.microsoft.com/azure-functions/python:3.0-python3.6-appservice
FROM mcr.microsoft.com/azure-functions/python:3.0-python3.6
ENV AzureWebJobsScriptRoot=/home/site/wwwroot \
AzureFunctionsJobHost__Logging__Console__IsEnabled=true
# Add ODBC Driver requirements
RUN apt-get update \
&& apt-get install unixodbc -y \
&& apt-get install unixodbc-dev -y \
&& apt-get install freetds-dev -y \
&& apt-get install freetds-bin -y \
&& apt-get install tdsodbc -y \
&& apt-get install --reinstall build-essential -y
# add pyodbc requirements
RUN apt-get install python-pyodbc -y
#copy the driver to container
COPY /Driver /usr/lib/intersystems/odbc
#run install script
RUN /usr/lib/intersystems/odbc/ODBCinstall
#copy the odbc configuration file to the container
COPY odbc.ini /etc/intersystemsodbc.ini
#make the odbc library aware that we have added a new driver
RUN odbcinst -i -d -f /etc/intersystemsodbc.ini
#symlink the odbc driver, not sure if its required
RUN ln -s /usr/lib/x86_64-linux-gnu/libodbccr.so.2.0.0 /usr/lib/x86_64-linux-gnu/odbc/libodbccr.so
#copy the Azure Functions project to the docker image
COPY . /home/site/wwwroot
#install the python libraries as you would usually do
RUN cd /home/site/wwwroot && pip install -r requirements.txt
I hope this saves some people a lot of time, because it was quite a challenge to build this!
Question
Eduard Lebedyuk · Aug 17, 2019
I have two local instances:IRIS for Windows (x86-64) 2018.1.2 (Build 626_3U) Wed Jun 12 2019 19:07:59 EDTIRIS for Windows (x86-64) 2019.1 (Build 510U) Thu Mar 14 2019 14:13:37 EDTI'm using Java Gateway to talk to external system.Both instances are using the same:jargenerated classjava versionThey are calling the same method with this java signature:
package isc.rabbitmq;
public class API {
public void sendMessage(byte[] msg) throws Exception {}
}
On the InterSystems IRIS side I'm calling it like this:
set sc = ##class(%Net.Remote.Service).OpenGateway(gatewayName, .gatewayConfig)
set sc = ##class(%Net.Remote.Service).ConnectGateway(gatewayConfig, .gateway, "PATH-TO-JAR", 1)
set api = ##class(isc.rabbitmq.API).%New(gateway)
set stream = ##class(%GlobalBinaryStream).%New()
do stream.Write(123456)
d api.sendMessage(stream)
And the method works for IRIS 2018.1.2, however on IRIS 2019.1 the byte[] is NULL.
IRIS documentation is stating that %GlobalBinaryStream is a correct class to use:
Any ideas what changed? Solved.Streams are not passed only for overloaded methods.This does not work:
public class API {
public void sendMessage(byte[] msg) throws Exception {}
public void sendMessage(byte[] msg, String Id) throws Exception {}
}
However this does:
public class API {
public void sendMessage(byte[] msg) throws Exception {}
public void sendMessageId(byte[] msg, String Id) throws Exception {}
}
Announcement
Spencer Frey · Aug 31, 2022
Hi everyone!
I am recruiting on a fully remote Intersystems Developer. This role will be a long term contract to begin with high likelihood of extensions or conversion permanent. Please check out the job description down below and feel free to send me an email with your resume: Spencer.Frey@insightglobal.com
The Healthcare Integration Developer is responsible for designing, developing, and deploying the complex near real-time and real-time data interoperability solutions using Healthcare industry-standard data formats/specifications (HL7, FHIR, EDI, etc.). The role is responsible for consulting with internal customers, team members, and external vendors to design, build, test, and manage application services. A key responsibility is strategically collaborating with cross-functional teams to understand operational needs, perform gap analysis and convert customer requirements into custom interoperability solutions using in-depth knowledge of healthcare business processes and data integration optimization. This role is the internal expert in system capabilities and architectural interoperability standards. Also is responsible for maintaining system changes, documenting functional and technical requirements, mapping process flows, establishing test plans, conducting system testing, establishing user manuals, and administering training related to the interoperability code.
Must Haves:2+ years experience with Intersystems Development2+ years experience with Intersystems IRIS areas of APIM, FHIR Server, and Longitudinal Patient record2+ years experience with HL72+ year experience with one or more programming language ( C#, Python, TCL, ESQL, M, T-SQL, JavaScript)Healthcare Experience
Plus:
Experience with AWS or Azure Cloud Services
Experience with FHIR
Epic experience - inner connect (API tool), chronicles, custom development
Bachelors Degree
Experience with Healthcare Interoperability/Interface engines is it open to China developers?
Question
Kalle Päplow · Mar 29, 2023
Hello,
I have a question regarding the Intersystems Caché Database and its jdbc driver. I need to set the connection timeout for the database, but I couldn't find any documentation stating that the jdbc driver for Caché supports setting the connection timeout. However, I noticed that the jdbc driver for the Intersystems Iris Database appears to support this feature.
My question is, can I use the Iris jdbc driver to set the connection timeout for the Caché Database?
The jdbc driver I use: cache-jdbc-2.0.0.jar
Thank you for your help.
Best regards,Kalle
Announcement
Athanassios Hatzis · Jan 2, 2018
Connected Data London ConferenceTRIADB is an emerging unique and valuable technology in NoSQL database modelling and BI analytics. The following video is from a presentation and demonstration of TRIADB prototype implemented on top of Intersystems Cache database and driven with a CLI in Python (Jupyter-Pandas). In fact this is the second time in the past year that a prototype based on this technology is implemented and demonstrated. The first one was built on top of OrientDB multi-model database and driven by a Mathematica notebook.Unfortunately the light conditions were not ideal for the demonstration of our system. We recommend you visit the links at the right side of the following table to view Pandas notebooks in addition to the video above. You may also start the video at the corresponding time. Time (min:sec)Pandas Notebooks in HTML format05:00Traversal and Hypergraph09:00Hypernodes, Hyperedges and Tuples11:45Hypercollections13:00Data Model15:30MappingAnd these are the slides from the presentationTechnical ObjectivesIntegration of multiple data resources, automatic correlation, aggregation and exploration based on Associative Semiotic Hypergraph technology (see S3DM/R3DM).Key Differentiating FactorsMulti-Perspective Database Framework : tuples, domain sets, objects and hypergraphAct both as an operational and data warehouse database with a 360 degree viewAutomatic fixed indexing schema instead of user-defined secondary indexingManage the references instead of data. Fully referenced and relational based on fixed composite indexing. No duplicates but single value instance instead based on system defined primitive data typesMapping and consolidation of multiple data resources on user-defined data modelsDeveloper friendly and easily programmable thanks to powerful functional commands in PythonFunctional operations (e.g. Get, Add) with standard parameters instead of a query language with variable partsChallengeProve that a system built with this technology can be beneficial for either a single-user and/or competive for a big enterprise with suitable use-casesNext milestoneA better PoC prototype preferably sponsored by Intersystems Cache or perhaps another database vendor. We are actively looking for teammates and partners for the next phase of the project.
Question
Michael Gosselin · Jun 15, 2023
I am trying to set up VS Code so that it will connect to a new server running IRIS 2023.1, and I can't seem to get the setup to accept my errors. I enter all the requested information, and at the end I receive a message:
Failed to store server '$(name)' definition.
Source: InterSystems Server Manager (Extension)
I've submitted a bug log with VSCode, but then I noticed the source, and figured it might be related to the extension instead of the program, and was wondering if others have received this message. The VSCode is 1.79.1, for the record.
Thanks as always. @Michael.Gosselin The best place to report those issues is the GitHub repository for the Server Manager extension. Also, any details you can give us would be great. Does a server already exist with that name in your user settings? Do you have a workspace open?
cc @John.Murray Please use Command Palette to run "Preferences: Open User Settings (JSON)", then review the contents for any syntax errors. My hunch is the file contains an invalid JSON structure, so the extension's call to update the "intersystems.servers" object in it is failing. Server name must be in all lowercase. @Eduard.Lebedyuk the presence of '$(name)' in that message is misleading because of a small SM bug. If @Michael.Gosselin had tried entering exactly that when adding the definition he would have seen this:
Fair enough. Thank you for the suggestion. The server exists, but not on my laptop. I don't think there's a workspace open; should there be? @John.Murray : this is my entire JSON user settings:
{
"intersystems.servers": {
}
}
}
I bet you didn't expect that. And I just noticed there was a third "}". I'll try removing that. That fixed it. Thank you @John.Murray I'm glad to hear that. Don't know how it could have happened, unless you'd been editing the JSON directly.
I have opened https://github.com/intersystems-community/intersystems-servermanager/issues/186 to capture the issue about the error message not being a template literal.
Question
Jon Astle · Apr 18, 2023
I have updated some legacy VB/ASP.NET code and changed the references of InterSystems.Data.CacheClient to InterSystems.Data.IRISClient. I am struggling with the code as I am not a .NET expert and there is little or no documentation.
I have published the code on several test IIS sites and on some the code works fine but on others I get the below error. The error doesn't appear to be O/S specific as I have it working on some Windows 2016 servers and not working on other Windows 2016 servers. I have checked the network card settings as the error seems to refer to IPv6 and IPv6 is not enabled on any of the servers.
None of the discovered or specified addresses match the socket address family.Parameter name: context
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.ArgumentException: None of the discovered or specified addresses match the socket address family.Parameter name: context Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: None of the discovered or specified addresses match the socket address family.
Parameter name: context]
System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) +2500829
System.Net.Sockets.TcpClient.EndConnect(IAsyncResult asyncResult) +68
InterSystems.Data.IRISClient.TCPDevice.Connect(String Address, Int32 Port, Int32 timeoutMSec, Boolean ipv6) +559
InterSystems.Data.IRISClient.TCPDevice.Connect(String Address, Int32 Port, Int32 timeoutMSec) +142
InterSystems.Data.IRISClient.TCPDevice..ctor(IPEndPoint ipEndPoint, IRISADOConnection conn) +438
InterSystems.Data.IRISClient.IRISPool.CreateNewPooledConnection(IRISADOConnection conn) +159
InterSystems.Data.IRISClient.IRISPool.GetPooledConnection(IRISADOConnection conn) +198
InterSystems.Data.IRISClient.IRISPoolManager.GetConnection(IRISADOConnection conn) +579
InterSystems.Data.IRISClient.IRISADOConnection.OpenInternal() +89
InterSystems.Data.IRISClient.IRISADOConnection.Open() +95
[IRISException (0x80004005): [IRIS Provider] Communication link failure: System.ArgumentException; None of the discovered or specified addresses match the socket address family.
Parameter name: context]
InterSystems.Data.IRISClient.IRISADOConnection.Open() +702
ManagedCache.ExecuteReader(String QueryText) +64
_Default.Page_Load(Object sender, EventArgs e) +62
System.Web.UI.Control.OnLoad(EventArgs e) +132
System.Web.UI.Control.LoadRecursive() +66
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2428
Announcement
Anastasia Dyubaylo · May 10, 2022
Hi Community,
See how you can develop in Python and connect to InterSystems IRIS® data platform with PyODBC and the Native API:
⏯ Using Python to Connect to InterSystems IRIS
Enjoy watching on InterSystems Developers YouTube channel and stay tuned!
Announcement
Anastasia Dyubaylo · Jul 12, 2022
Hey Community,
Enjoy watching the new video on InterSystems Developers YouTube channel:
⏯ Multi Model Capabilities of InterSystems IRIS
Learn how the multi-model architecture of InterSystems IRIS data platform can benefit your applications. Use the data model that fits each task—relational, object, or native access—while working in your language of choice.
Stay tuned!
Announcement
Anastasia Dyubaylo · Mar 18, 2019
Hi Community!
We are pleased to invite you to the upcoming webinar "Machine Learning Toolkit (Python, ObjectScript, Interoperability, Analytics) for InterSystems IRIS" on 26th of March at 10:00 (Moscow time)!
We will talk about ML Toolkit - a set of functional extensions for mathematical modelling for InterSystems IRIS data platform.
The following topics would be discussed:
IRIS as a driver for mathematical modelling environments (Python, etc.);
IRIS as an application development platform for mathematical modelling (native library of algorithms);
IRIS Interoperability as a designing environment for adaptive analytical processes;
IRIS Analytics as an environment for visualization of the mathematical algorithms results;
ML Toolkit usage scenarios.
Audience: The webinar is designed for Python/ObjectScript Developers, Data Scientists and Data Engineers.
Note: The language of the webinar is Russian.
We are waiting for you at our webinar! Register for free now! And Tuesday, April 23rd at 11am EDT we would be running an English version of the webinar.Register here.
Announcement
Angelo Bruno Braga · Mar 7, 2022
Hi Developers,
We are carefully preparing our first 🏆 InterSystems Technical Article Contests in Portuguese 🏆.
As the contest will be officially launched next week, take advantage of this week to choose your topic or, if you are new to InterSystems technology, take the opportunity to learn a little more about the technology in this period to be able to participate!
Without giving any spoilers ....
In addition to the contest being in Portuguese, there will be several new features both in terms of prizes and in relation to how the contest works.
So get ready and,
Stay tuned!!!! 
That's AMAZING news!! I can't wait for it participem!!!! Whoever wants to participate, I make myself available to translate from English to Portuguese. Great initiative Yuri !
Members, keep in mind that only new articles will be accepted ! Translated articles that are already published on English/Spanish/Japanese/Chinese communities will not be accepted !
Good luck !!!