Skip to content
This repository has been archived by the owner on Jul 7, 2020. It is now read-only.

Add HEKETI_IGNORE_STALE_OPERATIONS env variable in heketi. Helps to d… #447

Merged

Conversation

SaravanaStorageNetwork
Copy link
Member

@SaravanaStorageNetwork SaravanaStorageNetwork commented Mar 5, 2018

…ecide whether to ignore the stale pending operations db entries in the database.

Default value is true.

Signed-off-by: Saravanakumar sarumuga@redhat.com


This change is Reviewable

@centos-ci
Copy link
Collaborator

Can one of the admins verify this patch?

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

ok to test

Copy link
Contributor

@obnoxxx obnoxxx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a question about the doc text in the ocp templates (would apply to both heketi and deploy-heketi templates...)

@@ -121,3 +123,6 @@ parameters:
displayName: heketi fstab path
description: Set the fstab path, file that is populated with bricks that heketi creates
value: /var/lib/heketi/fstab
- name: HEKETI_IGNORE_STALE_OPERATIONS
displayName: Heketi ignore stale operations
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Heketi ignore stale operations" --> "Whether to ignore stale operations at startup" ?

@@ -121,3 +123,6 @@ parameters:
displayName: heketi fstab path
description: Set the fstab path, file that is populated with bricks that heketi creates
value: /var/lib/heketi/fstab
- name: HEKETI_IGNORE_STALE_OPERATIONS
displayName: Heketi ignore stale operations
description: Whether to ignore the stale pending operations db entries in the database
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be a little more verbose?

"This allows to control whether heketi should start up when when there are stale pending operation entries present in the database."

Maybe even more (not sure how long this can/should be): " ... Setting this to true lets heketi ignore existing pending operations at startup. Setting it to false causes heketi to refuse to start if pending operations are found in the database."

Copy link
Contributor

@obnoxxx obnoxxx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed, please set the value to "True" in the templates.

@SaravanaStorageNetwork
Copy link
Member Author

@obnoxxx @raghavendra-talur Please check

Copy link
Contributor

@obnoxxx obnoxxx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The resulting templates LGTM now, thanks for the update!

But I have a nitpick about the commits:

  • The first adds the var and an initial description.
  • The second commit changes the value (which would be OK), but also changes (elaborates on) the description...

I suggest squashing the two commit or else reworking it such that the second only changes the values from true to false...

@raghavendra-talur
Copy link
Member

@SaravanaStorageNetwork Also, looks like we need to have the value as string and bool. Enclose true in quotes.

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

retest this please

Copy link
Contributor

@obnoxxx obnoxxx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM now.
let's see what centos-ci has to say about this. :-)

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

ok to test

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

@SaravanaStorageNetwork centos-ci failed:

11:54:20 heketi topology loaded.
11:54:20 /usr/bin/kubectl -n default exec -i deploy-heketi-6db75b9566-vrtg4 -- heketi-cli -s http://localhost:8080 --user admin --secret '' setup-openshift-heketi-storage --listfile=/tmp/heketi-storage.json  2>&1
11:55:29 Saving /tmp/heketi-storage.json
11:55:29 /usr/bin/kubectl -n default exec -i deploy-heketi-6db75b9566-vrtg4 -- cat /tmp/heketi-storage.json | /usr/bin/kubectl -n default create -f - 2>&1
12:01:27 Error from server: timeout
12:01:27 Error from server (Timeout): the server was unable to return a response in the time allotted, but may still be processing the request (post endpoints)
12:01:27 Unable to connect to the server: http2: server sent GOAWAY and closed the connection; LastStreamID=59, ErrCode=NO_ERROR, debug=""; some request body already written
12:01:27 The connection to the server 192.168.10.90:6443 was refused - did you specify the right host or port?
12:01:27 Failed on creating heketi storage resources.

…ecide whether to ignore the stale pending operations db entries in the database.

Default value is True.

Signed-off-by: Saravanakumar <sarumuga@redhat.com>
@SaravanaStorageNetwork
Copy link
Member Author

ok to test

@SaravanaStorageNetwork
Copy link
Member Author

13:15:33 Error from server (Timeout): error when creating "myapp.yaml": the server was unable to return a response in the time allotted, but may still be processing the request (post pods)
13:15:33 waiting for app pod to become available
13:15:45 putting content into application
13:15:54 Error from server (NotFound): pods "myapp" not found
13:15:54 verifying we get back our content from the app
13:15:54 % Total % Received % Xferd Average Speed Time Time Time Current
13:15:54 Dload Upload Total Spent Left Speed
13:15:54
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0curl: (6) Could not resolve host: http; Name or service not known
13:15:54 ERROR: did not get expected output from nginx pod

nginx pod failing ? seems like network issue.. @obnoxxx

@SaravanaStorageNetwork
Copy link
Member Author

ok to test

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

retest this please

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

ok to test

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

why is the @centos-ci not reacting to the magic incantations? ... :-/

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

hah, it just takes a short while! :-)

@SaravanaStorageNetwork
Copy link
Member Author

There is no change between previous run and this one - but failed during deploy-heketi - Could you retrigger @obnoxxx

@jarrpa
Copy link
Contributor

jarrpa commented Mar 5, 2018

retest this please

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

This is weird. Seems to be failing arbitrarily at different stages of the test run. Is it related at all?

@raghavendra-talur
Copy link
Member

@obnoxxx i don't think. So network error or a package is broken.

@SaravanaStorageNetwork
Copy link
Member Author

@obnoxxx I have verified the test steps works in my local setup - but fails in CI.

I have sent another PR to verify whether any issue with env variable value true. #448

If that also fails, some issue with CI.
else, issue with using "true" value which we added here.

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

Also created PR #449 to test the centos-ci. That PR just changes a readme...

@jarrpa
Copy link
Contributor

jarrpa commented Mar 5, 2018

retest this please

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

hey, did it actually already pick up a heketi build with the HEKETI_IGNORE_STALE_OPERATIONS variable support? with value true/false?

@raghavendra-talur
Copy link
Member

hey, did it actually already pick up a heketi build with the HEKETI_IGNORE_STALE_OPERATIONS variable support? with value true/false?

Whether it did or not should not matter. Isn't it?

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

ugh #448 succeeded...

@obnoxxx
Copy link
Contributor

obnoxxx commented Mar 5, 2018

hooray, it passed!

@obnoxxx obnoxxx merged commit 0b27a92 into gluster:master Mar 5, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants