Dmitry Maslennikov · Apr 16, 2021 go to post

How many files are you trying to import this way?

Unfortunately VSCode not so good for such a task, and even any editor.

In fact, the best way will be to do it directly with Caché. Just using $system.OBJ.LoadDir, will do it much better.

Dmitry Maslennikov · Apr 16, 2021 go to post

So, in this case, In fact, if you are not going to migrate that data to IRIS in the end, I see no reasons to use IRIS for such data. And microservices has written in some other languages, really a better way. 

Would it be possible to synchronize the date from other services with IRIS? So, your patient data still will be there, and backed up in IRIS, with FHIR endpoint. So, in this case, you can use IRIS Production to do this particular task.

Dmitry Maslennikov · Apr 16, 2021 go to post

I mean, would not it be easier to migrate your data to existing realizations of FHIR offered by InterSystems. And you will not need to implement your API at all.

Dmitry Maslennikov · Apr 16, 2021 go to post

Microservices are supposed to run separately with an ability for scalability, failure recovery, and be independent of the running environment. And the major side effect of it, microservices are language-independent.

And IRIS production, not the platform for microservices at all. Just only one production, limited by one server, if you will need to add some more items to it, you have to update the entire production. Yes, it will be possible to scale services when needed, but it still will be limited by the resources of the server where the production running. There are no easy ways how to automatically recover Production after failure. 

So, nowadays, would recommend trying Kubernetes as a platform for microservices, each microservice could be written in any supported by IRIS language (nodeJS, .Net, Python, Java). With IRIS itself running in the mirror for high availability.

Speaking about HealthCare application, why would you even decide to implement some own way, when FHIR already covers most of the things you would need?

Dmitry Maslennikov · Apr 15, 2021 go to post

That's interesting, but did you try to discover the differences, not only in the number of rows?

I would suggest, that the issue in time formats.

Try to play with different modes in SMP

Dmitry Maslennikov · Apr 12, 2021 go to post

I won't recommend using squashing, as it makes caching image layers useless.

Have a look at this nice tool, which may help to discover why your final image is so big.

btw, one thing I noticed working on macOS, is that the final image much bigger than expected, while the same Dockerfile on Linux, produces an image of a reasonable size.

Another possible issue is that it comes from the Language Server, you may temporarily disable that extension if it's installed and active to see if it's changed (reload is required). And if the issue disappears I would suggest installing the latest beta version of Language Server. And fill the issue in the repo, if it's still happens.

The issue is probably in export settings, which used to find a real file for resources on server. You can check it by opening ObjectScript Explorer, when you dive to your classes/routines, it should show an icon next to the name, the same as in File Explorer. So, it's mean that it's linked correctly. If not. you have to look at "objectscript.export" settings, you may find some useful info about this here.

We build IRIS with ZPM this way, and the reason was to shrink the final size

But the best you achieve if you will not change anything in the system database, which is quite big, and it makes no sense in the end.

Dmitry Maslennikov · Mar 31, 2021 go to post

Class Security.Users is available only from %SYS, you can map it to your namespace, but I would not recommend to do it. I think, you can just have a method just for this exact thing, where you can switch to %SYS namespace, gather what's you need, and that's it. In this method you will need to use New $namespace command, so, when it will return back to your original namespace when returns. As a ClassMethod it would look like this

ClassMethod GetUserInfo(username, ByRef props) As %Status
{
  New $Namespace
  Set $Namespace = "%SYS"
  Return ##class(Security.Users).Get(username, .props)
}
Dmitry Maslennikov · Mar 30, 2021 go to post

While you have just ordinary system terminal in VSCode you can open IRIS terminal as you would do it outside of VSCode, and it’s depends on where you are working. For Linux it would be just like iris session IRIS. Or if it’s in docker, it should be in docker exec, or docker-compose exec

Dmitry Maslennikov · Mar 30, 2021 go to post

Hi,

1. Yes, there a few options for debugging ObjectScript code in VSCode, including running any class method or routine, attach to a running process, only CSP debugging not supported, yet

2. VSCode offers a ways to run system’s terminal internally. And you can run IRIS terminal there, if you working locally. If you working remotely, you’ll need to configure remote access to it, with ssh or telnet, and connect to it from VSCode internal terminal. Yes, as an option could be web terminal.

Dmitry Maslennikov · Mar 29, 2021 go to post

Hi @David Loveluck, and anybody who wanted it.

Have a look at one of my latest projects. I did Grafana plugin for IRIS, which can connect and gather any data directly. It's in active development and will be extended with much more possibilities very soon. And I'm going to publish it on Grafana Plugins list as well, for easier installation. Stay tuned, and do not hesitate to contact me directly or through issues in the repository, if you have some advice, what would you like to see there first.

Dmitry Maslennikov · Mar 21, 2021 go to post

It looks like the issue in the order of compilation, and you have to properly configure it. Look at the parameter System in class, in most cases, it will be enough. If you have it properly configured if you even uncompile the entire project, and compile everything, just with CompileAll method it should be successful without any errors.

Dmitry Maslennikov · Mar 19, 2021 go to post

You can do it by yourself. I would recommend looking at the page of all emoji list in Unicode. There you may find a link to the latest version of data in text files, which will be possible to parse quite easily with ObjectScript. So, you can just import that data and use it as you want. And you will need to update it regularly when it gets some new emojis.

Dmitry Maslennikov · Mar 11, 2021 go to post

You can check how many license units available with this method $SYSTEM.License.LUAvailable()

And next depends on the kind of application, you develop. If it's some web application, and you have to achieve it for web session, I would try using %CSP.SessionEvents with OnLogin event, check how many license units are available and who is logging in, and decide to decline the login.

If you need it for some else ways of connections, I think the best place would be ZAUTHENTICATE.

CSP files are real files on disk and case sensitivity is depends on operating system. So, I suppose you using some Linux.

Since 2016.2 there are no reasons to keep storing source code in XML. Even in transition process, I would recommend to store codebase based on the lowest supported version of platform.

Cache and IRIS able to export and import source code in UDL format, as seen in VSCode. 
 

If you would stay with XML format just because you’d like to keep history consistent, it can be solved by converting entire history in the like it was always in UDL.

ahh, you have a just a wrong JSON, I would recommend to find a way how to fix it from the side where it comes from.

Key names in the JSON also have to be wrapped by quotes