Skip to content

Commit 9e15bf0

Browse files
MakarovS96zitros
authored andcommitted
[New] Add IRIS compatibility
* Add IRIS compatibility to installer * Change condition by @MakarovS96
1 parent c778185 commit 9e15bf0

File tree

1 file changed

+23
-7
lines changed

1 file changed

+23
-7
lines changed

src/cls/WebTerminal/Installer.cls

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,12 @@ ClassMethod CreateProjection(cls As %String, ByRef params) As %Status
8181
set cspProperties("Description") = "An application representing the open socket for /terminal application."
8282
set cspProperties("DispatchClass") = ""
8383
set role = ..GetDBRole(dbdir)
84-
set cspProperties("MatchRoles")=":%DB_CACHESYS" _ $case($get(role)'="", 1: ":"_role, :"")
84+
if ($system.Version.GetISCProduct() >= 4) {
85+
set cspProperties("MatchRoles")=":%DB_IRISSYS" _ $case($get(role)'="", 1: ":"_role, :"")
86+
} else {
87+
set cspProperties("MatchRoles")=":%DB_CACHESYS" _ $case($get(role)'="", 1: ":"_role, :"")
88+
}
89+
8590
set st = ..RegisterWebApplication("/terminalsocket", .cspProperties)
8691
do:($$$ISERR(st)) ##class(WebTerminal.Analytics).ReportInstallStatus(st)
8792
return:$$$ISERR(st) st
@@ -178,12 +183,23 @@ ClassMethod CreateAllNamespace() As %Status
178183
set ns = "%All"
179184
set st = $$$OK
180185
if ('##Class(Config.Namespaces).Exists(ns)) {
181-
set Properties("Globals") = "CACHETEMP"
182-
set Properties("Library") = "CACHELIB"
183-
set Properties("Routines") = "CACHETEMP"
184-
set Properties("SysGlobals") = "CACHESYS"
185-
set Properties("SysRoutines") = "CACHESYS"
186-
set Properties("TempGlobals") = "CACHETEMP"
186+
187+
if ($system.Version.GetISCProduct() >= 4) {
188+
set Properties("Globals") = "IRISTEMP"
189+
set Properties("Library") = "IRISLIB"
190+
set Properties("Routines") = "IRISTEMP"
191+
set Properties("SysGlobals") = "IRISSYS"
192+
set Properties("SysRoutines") = "IRISSYS"
193+
set Properties("TempGlobals") = "IRISTEMP"
194+
} else {
195+
set Properties("Globals") = "CACHETEMP"
196+
set Properties("Library") = "CACHELIB"
197+
set Properties("Routines") = "CACHETEMP"
198+
set Properties("SysGlobals") = "CACHESYS"
199+
set Properties("SysRoutines") = "CACHESYS"
200+
set Properties("TempGlobals") = "CACHETEMP"
201+
}
202+
187203
set st = ##Class(Config.Namespaces).Create(ns, .Properties)
188204
if ($$$ISERR(st)) {
189205
do $System.Status.DisplayError(st)

0 commit comments

Comments
 (0)