Skip to content

Commit

Permalink
Merge pull request #217 from fmherschel/angi-ScaleOut-newComparators
Browse files Browse the repository at this point in the history
Angi scale out new comparators
  • Loading branch information
fmherschel authored Nov 14, 2023
2 parents 185f4c8 + c95a383 commit a6632d5
Show file tree
Hide file tree
Showing 40 changed files with 1,227 additions and 893 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"test": "bmt",
"name": "blocked manual takeover",
"test": "block_manual_takeover",
"name": "block manual takeover, using susTkOver.py",
"start": "step10",
"steps": [
{
Expand All @@ -9,7 +9,7 @@
"next": "step20",
"loop": 1,
"wait": 1,
"post": "bmt",
"post": "block_manual_takeover",
"pSite": "pSiteUp",
"sSite": "sSiteUp",
"pHost": "pHostUp",
Expand Down
20 changes: 13 additions & 7 deletions test/json/angi-ScaleOut/defaults+newComparators.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
{
"checkPtr": {
"comparartorinline": [
"alfa!=dassollungleichsein",
"alfa != dassollungleichsein",
"lpa_@@sid@@_lpt > 160000",
"beta=dassollgleichsein"
"beta == dassollgleichsein",
"gamma >? 20000:(detla|epsilon)"
],
"comparatortuple": [
("noty", "alfa=ungleich"),
()
"comparator1": [
"key comp value",
"lpt >= 1699606819",
"lpt >= 1699606819:(20|30)",
"lss like [1-4]",
"lss ~ [1-4]",
"lss !~ [1-4]",
"srHook is None"
],
"globalUp": [
"topology=ScaleOut"
Expand All @@ -18,7 +24,7 @@
"score=150"
],
"pSiteUp": [
"lpt=1[6-9]........",
"lpt >= 1699606819",
"lss=4",
"srr=P",
"srHook=PRIM",
Expand All @@ -33,7 +39,7 @@
],
"sHostUp": [
"clone_state=DEMOTED",
"roles=master1:master:worker:master",
"roles ~ master1:master:worker:master",
"score=100"
],
"pHostDown": [
Expand Down
70 changes: 35 additions & 35 deletions test/json/angi-ScaleOut/defaults.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,57 +3,57 @@
"srMode": "sync",
"checkPtr": {
"globalUp": [
"topology=ScaleOut"
"topology = ScaleOut"
],
"pHostUp": [
"clone_state=PROMOTED",
"roles=master1:master:worker:master",
"score=150"
"clone_state == PROMOTED",
"roles == master1:master:worker:master",
"score == 150"
],
"pSiteUp": [
"lpt=1[6-9]........",
"lss=4",
"srr=P",
"srHook=PRIM",
"srPoll=PRIM"
"lpt > 1000000000",
"lss == 4",
"srr == P",
"srHook == PRIM",
"srPoll == PRIM"
],
"sSiteUp": [
"lpt=30",
"lss=4",
"srr=S",
"srHook=SOK",
"srPoll=SOK"
"lpt == 30",
"lss == 4",
"srr == S",
"srHook == SOK",
"srPoll == SOK"
],
"sHostUp": [
"clone_state=DEMOTED",
"roles=master1:master:worker:master",
"score=100"
"clone_state == DEMOTED",
"roles == master1:master:worker:master",
"score == 100"
],
"pHostDown": [
"clone_state=UNDEFINED" ,
"roles=master1::worker:" ,
"score=150" ,
"standby=on"
"clone_state == UNDEFINED",
"roles == master1::worker:",
"score == 150",
"standby == on"
],
"pSiteDown": [
"lpt=1[6-9]........" ,
"lss=1" ,
"srr=P" ,
"srHook=PRIM" ,
"srPoll=PRIM"
"lpt > 1000000000",
"lss == 1",
"srr == P",
"srHook == PRIM",
"srPoll == PRIM"
],
"sSiteDown": [
"lpt=10",
"lss=1",
"srr=S",
"srHook=SFAIL",
"srPoll=SFAIL"
"lpt == 10",
"lss == 1",
"srr == S",
"srHook == SFAIL",
"srPoll == SFAIL"
],
"sHostDown": [
"clone_state=UNDEFINED" ,
"roles=master1::worker:" ,
"score=100" ,
"standby=on"
"clone_state == UNDEFINED",
"roles == master1::worker:",
"score == 100",
"standby == on"
]
}
}
90 changes: 90 additions & 0 deletions test/json/angi-ScaleOut/freeze_prim_master_nfs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
{
"test": "freeze_prim_master_nfs",
"name": "freeze sap hana nfs on primary master node",
"start": "step10",
"steps": [
{
"step": "step10",
"name": "test prerequitsites",
"next": "step20",
"loop": 1,
"wait": 1,
"post": "shell test_freeze_prim_master_nfs",
"pSite": "pSiteUp",
"sSite": "sSiteUp",
"pHost": "pHostUp",
"sHost": "sHostUp"
},
{
"step": "step20",
"name": "failure detected",
"next": "step30",
"loop": 120,
"wait": 2,
"pSite": [
"srr == P",
"lpt >~ 1000000000:(20|10)",
"srHook ~ (PRIM|SWAIT|SREG)",
"srPoll == PRIM"
],
"sSite": [
"lpt >~ 1000000000:30",
"lss == 4",
"srr ~ (S|P)",
"srHook ~ (PRIM|SOK)",
"srPoll ~ (SOK|SFAIL)"
],
"pHost": [
],
"sHost": [
"clone_state ~ (PROMOTED|DEMOTED)",
"roles == master1:master:worker:master",
"score ~ (100|145)"
]
},
{
"step": "step30",
"name": "begin recover",
"next": "step40",
"loop": 300,
"wait": 2,
"todo": "pHost+sHost to check site-name",
"pSite": [
"lss ~ (1|2)",
"srr ~ (P|S)",
"lpt >~ 1000000000:(30|20|10)",
"srHook ~ (PRIM|SWAIT|SREG)",
"srPoll ~ (PRIM|SFAIL)"
],
"sSite": [
"lpt >~ 1000000000:30",
"lss == 4",
"srr ~ (S|P)",
"srHook == PRIM",
"srPoll ~ (SOK|PRIM)"
],
"pHost": [
"clone_state ~ (UNDEFINED|DEMOTED|WAITING4NODES)",
"roles == master1::worker:"
],
"sHost": [
"clone_state ~ (DEMOTED|PROMOTED)",
"roles == master1:master:worker:master",
"score ~ (100|145|150)"
]
},
{
"step": "step40",
"name": "end recover",
"next": "END",
"loop": 300,
"wait": 2,
"post": "cleanup",
"remark": "pXXX and sXXX are now exchanged",
"pSite": "sSiteUp",
"sSite": "pSiteUp",
"pHost": "sHostUp",
"sHost": "pHostUp"
}
]
}
90 changes: 90 additions & 0 deletions test/json/angi-ScaleOut/freeze_prim_site_nfs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
{
"test": "freeze_prim_site_nfs",
"name": "freeze sap hana nfs on primary site",
"start": "step10",
"steps": [
{
"step": "step10",
"name": "test prerequitsites",
"next": "step20",
"loop": 1,
"wait": 1,
"post": "shell test_freeze_prim_site_nfs",
"pSite": "pSiteUp",
"sSite": "sSiteUp",
"pHost": "pHostUp",
"sHost": "sHostUp"
},
{
"step": "step20",
"name": "failure detected",
"next": "step30",
"loop": 120,
"wait": 2,
"pSite": [
"srr == P",
"lpt >~ 1000000000:(20|10)",
"srHook ~ (PRIM|SWAIT|SREG)",
"srPoll == PRIM"
],
"sSite": [
"lpt >~ 1000000000:30",
"lss == 4",
"srr ~ (S|P)",
"srHook ~ (PRIM|SOK)",
"srPoll ~ (SOK|SFAIL)"
],
"pHost": [
],
"sHost": [
"clone_state ~ (PROMOTED|DEMOTED)",
"roles == master1:master:worker:master",
"score ~ (100|145)"
]
},
{
"step": "step30",
"name": "begin recover",
"next": "step40",
"loop": 300,
"wait": 2,
"todo": "pHost+sHost to check site-name",
"pSite": [
"lss ~ (1|2)",
"srr ~ (P|S)",
"lpt >~ 1000000000:(30|20|10)",
"srHook ~ (PRIM|SWAIT|SREG)",
"srPoll ~ (PRIM|SFAIL)"
],
"sSite": [
"lpt >~ 1000000000:30",
"lss == 4",
"srr ~ (S|P)",
"srHook == PRIM",
"srPoll ~ (SOK|PRIM)"
],
"pHost": [
"clone_state ~ (UNDEFINED|DEMOTED|WAITING4NODES)",
"roles == master1::worker:"
],
"sHost": [
"clone_state ~ (DEMOTED|PROMOTED)",
"roles == master1:master:worker:master",
"score ~ (100|145|150)"
]
},
{
"step": "step40",
"name": "end recover",
"next": "END",
"loop": 300,
"wait": 2,
"post": "cleanup",
"remark": "pXXX and sXXX are now exchanged",
"pSite": "sSiteUp",
"sSite": "pSiteUp",
"pHost": "sHostUp",
"sHost": "pHostUp"
}
]
}
Loading

0 comments on commit a6632d5

Please sign in to comment.