Alexey Maslov · Jun 23, 2021 go to post

Thank you, John,

the idea is good, while I'm still unhappy and need to dig more.

Alexey Maslov · Jun 21, 2021 go to post

Thank you all for the quick responses, but: from all the server-side source control functionality I used only the possibility to extent Studio's menu by adding items to the source control menu. E.g.

XData Menu
{
<MenuBase>
<Menu Name="%SourceMenu" Type="0">
<MenuItem Name="My item 1" Save="100"/>
<MenuItem Name="My item 2" Save="100"/>
...
</Menu>
<Menu Name="%SourceContext" Type="1">
<MenuItem Name="My item 1" Save="100"/>
<MenuItem Name="My item 2" Save="100"/>
...
</Menu>
</MenuBase>
}

Can I implement something similar with VS Code?

Alexey Maslov · Jun 17, 2021 go to post

Thank you for examples, but is it possible to get a list of deprecated and discontinued technologies? 

Alexey Maslov · Jun 9, 2021 go to post

Methods how these macros are defined are quite different: $$$ISWINDOWS is calculated using system call and always 1 on Windows platform, in contrast $$$WindowsCacheClient is defined manually, so it and can be easily set to 0 if needed.

Many years ago I faced a problem with LDAP which was solved this way (I didn't change ISC code, it was my own "fork"). Don't remember other details, only the fact.

Alexey Maslov · May 15, 2021 go to post

Converting the file name to UTF8 usually helps. E.g.

USER>s file=$zcvt("/home/qms/Müller_Jörg.txt","o","UTF8") w $zf(-100,"","touch",file)
0
qms@testhost:~$ ls -l Müller_Jörg.txt
-rw-rw-r-- 1 qms cacheusr 0 May 15 18:39 Müller_Jörg.txt
Alexey Maslov · May 11, 2021 go to post

Postgres: Release 12, default ubuntu install

Default install hardly had a chance to win. Why didn't you use IRIS default install?
For fair play, each DBMS should be best tuned by the appropriate specialist.

Alexey Maslov · Apr 19, 2021 go to post

Robert,

Are you introducing an ability to play with additional IRIS configuration settings without restarting a container? If so, it sounds reasonable.

To address one of the security issues mentioned by Dmitry, why not hardcode a public key (or even several public keys) and disable SSH password authentication?

Alexey Maslov · Mar 26, 2021 go to post

If I could explicitly set authentication method for various parts of our instance

Apparently you can do it for each part of your instance represented as a web application. Just look in System Management Portal (SMP): System > Security Management > Web Applications: all the /csp/sys/* stuff is nothing else but SMP's function groups starting pages.

Alexey Maslov · Mar 24, 2021 go to post
If you have an article posted on DC and an app downloaded on OEX

Did you really mean an app uploaded to OEX?

Alexey Maslov · Mar 19, 2021 go to post

Robert,
you are absolutely correct in your guess: I've just called it from terminal :)
Another option is to put agg into the PublicList of the caller method. I still like it more than passing by reference as it looks clearer.

P.S. Correct caller was added to my sample code. THX Robert.

Alexey Maslov · Mar 18, 2021 go to post

Just a small fix that makes the PublicList unnecessary:

ClassMethod Flatten(reference, Output flat)
{
    For {
        Set reference = $query(@reference)
        Quit:reference=""
        Set value = $listbuild(@reference)
        For i=1:1:$qlength(reference) {
            Set value = value_$listbuild($qsubscript(reference,i))
        }
        Set flat($i(flat)) = value
    }
}

The fixed method should be called in a slightly different way:

Method SomeMethod(...) [ PublicList = agg ]
{
  ...
  Do ..Flatten($name(agg),.summary)
  ...
}
Alexey Maslov · Mar 17, 2021 go to post

Just adding 2c:

  • mapping your class to pseudo_namespace %ALL makes it available to all other namespaces except %SYS

...it would be available to all namespaces including %SYS.

Alexey Maslov · Mar 15, 2021 go to post

Giving a developer the opportunity to turn off an auditing event deemed important to capture kind of defeats that purpose.

Agree with you that disabling audit events is basically a bad practice. 

The frequency and the purpose of those external calls were checked, and they are OK, while it's worth considering change $zu(-100) to something else, e.g. to command pipe, whether access to pipes is not logged to Audit.

Alexey Maslov · Mar 9, 2021 go to post

Now I've got an idea... It was not our case as it was a new instance of IRIS to create. We were just choosing the simplest way of passing databases and some other stuff (localization, Task Manager's tasks, etc) from Caché to IRIS. Installation of an old version of OS just for Caché's sake seems to be overkill, doesn't it?

Alexey Maslov · Mar 9, 2021 go to post

@Robert Cemper

Agree with you, "in-place conversion" is not of great aid in real cases. Its pathos name sounds a bit confusing, isn't it?

During my first tries to transfer our Caché APP to IRIS I took an approach similar to yours, although I preferred not to use ECP as it was possible to avoid running both instances concurrently.

The funny thing I noticed: if one creates a database in Caché, renames it to IRIS.DAT, stops Caché, and starts IRIS, it will be mountable, but the reverse is wrong: renaming IRIS.DAT has been created in IRIS to CACHE.DAT doesn't make it compatible with Caché.

Alexey Maslov · Mar 9, 2021 go to post

This is a first version with Frozen Plans

The first, but not the last one, so still not getting the idea of having this intermediate upgrade point.

...Cache/IRIS never runs on unsupported OS. Do you have a case with WRC on this topic?

Sorry, on which topic? Everyone knows that Cache/IRIS never runs on an unsupported OS.

Alexey Maslov · Mar 8, 2021 go to post

upgrade to 2016.2

What is the reason of this step? If OP's Cache version allows direct upgrade to 2018.1, it can be easily omitted.

OS Compatibility can be a stop factor for in-place conversion. E.g., preparing IRIS instance for a prospect, we faced a small problem with it: Cache 2017.2 (our App's supported version) turned to be incompatible with Ubuntu 18, which was chosen as on OS for IRIS.

Alexey Maslov · Feb 10, 2021 go to post

This limit of 256 characters is a known problem with command pipes in Cache, and it seems that yet in IRIS. Agree with Dmitriy: $zf(-100) would be OK.

Alexey Maslov · Jan 13, 2021 go to post

Hi Yuri,
Your feature table is great. Just a quick note: AWS Hosting, like any other kind of hosting, is mostly a hosting feature rather than ODBMS one.

Alexey Maslov · Dec 25, 2020 go to post

Besides mapping ^ERRORto a non-journaled database, you may want to tune the ErrorPurge configuration parameter that resides under  System > Configuration > Startup Settings in SMP. As its default (30 days) is usually too big, it can be easily reduced to 7 days.

Alexey Maslov · Nov 28, 2020 go to post

The user needs to have a separate local or domain Windows account to SSH in to the server prior to logging in to Caché

Any SSH server you might try (OpenSSH, etc) would act this way: to start command shell, you need to log in Windows.

Alexey Maslov · Nov 20, 2020 go to post

It all sounds like a software provider in maintenance for its customers.

In such a case it is usually easier to map that global from the separated database and distribute its updated copy among the customers.

Alexey Maslov · Nov 20, 2020 go to post

 "mirroring is unavailable for the current license" 

It seems that they have a single server license, so ECP is probably not an option as well.
Otherwise, it's difficult to imagine the scenario when ECP remote (single!) database would not be better than duplicating the data in two databases. Just two cases come to mind:

  • slow internet connection
  • need to dedicate a whole server for some heavy data processing.

Anna, if you tell us more about your task, we'd likely advise you better.

Alexey Maslov · Oct 16, 2020 go to post

This quick solution, alas, will not survive the upgrade to IRIS as %Library.RemoteResultSet class was excluded from IRIS.

Alexey Maslov · Oct 12, 2020 go to post

Julius, I enjoy your $tr solution.

As to $zdth, you've just missed dformat argument, so it should be:

set tmp=$e(datetime,1,8)_" "_$e(datetime,9,10)_":"_$e(datetime,11,12)_":00" write $zdt($zdth(tmp,8,3),8,3)

<ILLEGAL VALUE> occurs otherwise.

Alexey Maslov · Sep 30, 2020 go to post

Whenever I return "useful" value from a method I regret it afterward. E.g.

set square=##class(mathCls).squareTriangle(a, b, c)

What if something went wrong, e.g. actual parameters (a, b, c) are invalid? I need some sign of it, so I'm forced to add some kind of status code. Let it be of %Status type. So, the caller's code is getting more complex:

set square=##class(mathCls).squareTriangle(a, b, c, .sc) if $$$ISERR(sc) $$$ThrowStatus(sc)

In contrast, when the status code is returned, it is not getting significantly complex:

$$$TOE(sc,##class(mathCls).squareTriangle(a, b, c, .square))

Besides, if each method returns status (even when it is always $$$OK), the whole code is looking more consistent and does not need modification if some of its methods get new behavior and able to return some error status as well. 

Alexey Maslov · Sep 30, 2020 go to post

Doing finalization like this you are rejecting your previous point to use $$$qoe(...).