Hi Jennifer,

first things yes mirroring is supported in AWS and Azure. What is not working is the automatic VIP failover managed by IRIS. This is due to limitations imposed by the cloud providers, as you cannot dynamically add an IP address.

For this usually a loadbalancer is utelized, that queries a specific csp page on the mirror servers to decide which mirror is active and redirect the "VIP" accordingly.

Also depending on what access (application,xDBC) you need, you can deploy a load balanced array of web servers. These can host the webgateway, which in turn can be configured to be mirror aware and does no tneed a VIP to automatically failover.

Best Regards

Timo

Hi,

question is here how is that global being populated/created? Is this global defined by usage of a class inheriting from %Persistent?

If so, a fast way would be to be using %Extent to enumerate all instances and then look at the rowcount.

e.g.

set query = ##class(%SQL.Statement).%New()
set qStatus = query.%PrepareClassQuery("User.Person","Extent")
set rset=query.%Execute()
d rset.%Display()
zw %ROWCOUNT

So just looking at your SQL,. You got 2 parameters in your where clause.

Select IDName from MSDS_Common.ComponentSub

 Where 

    (is null or %UPPER(Component)[%UPPER(?))

    and Active=1

If the first dropdown is null this will always be true if Active is 1

Try changing the where clause to

 Where 

    (is null AND ( %UPPER(Component)[%UPPER(?))

    and Active=1

This will check if first parameter is empty and if subcomponent contains the second parameter and if its active.

as an alternative you could use to standard traceroute 

 traceroute -n -T -m 5 -q 1 -p 80 hostname.local

-p portnumber

-T use TCP syn for connects

-m max TTL to test

If it succeeds it will return all IPs if the IP is not reachable it will only report *.
If the port is blocked it will return somethink like

 1  192.168.1.198  0.411 ms !X

Where !X means admin prohibited.

Hi,

if you make some assumptions

1. numbers are always enclosed in curved brackets

2. you want to always return string starting with REASON

this could be as easy as just:

set mystring="REASON->Blood(1.23)"

w "REASON"_$extract(mystring,$find(mystring,"(")-1,*)

or if you really want to use regex:

IRISHEALTH:USER>set mystring="REASON->Blood(1.23)"
IRISHEALTH:USER>set regex=##class(%Regex.Matcher).%New("^([A-Z]*)->.*(\([0-9]*.[0-9]*\))",mystring)
IRISHEALTH:USER>zw regex.Locate()                                               1
IRISHEALTH:USER>zw regex.Group(1)
"REASON"
 IRISHEALTH:USER>zw regex.Group(2)
"(1.23)"

The entrypoints of ZMIRROR are called during the mirror failover process. E.g. if the backup mirror has successfully taken over all roles and now has become primary the relevant entrypoint (not sure but something like HasBecomePrimary^ZMIRROR) is being called. So code added to that entrypoint will be executed at that time .

ZMIRROR cannot be used for monitoring purposes only to execute actions during a failover process.