Code Monkey home page Code Monkey logo

Comments (6)

guzzijones avatar guzzijones commented on July 3, 2024 2

Never comment anything ever. EVER.

from stackstorm-k8s.

guzzijones avatar guzzijones commented on July 3, 2024

After making this change for a shorter action_runner.graceful_shutdown we still see the actions getting stuck in a running state.

from stackstorm-k8s.

guzzijones avatar guzzijones commented on July 3, 2024

Let this be a lesson to everyone. Do NOT put inline comments in your config file:

...
 return opt.type(value)","host":"stackstorm","severity":"info","facility":"user",
{"timestamp":"2023-12-04T18:23:26+00:00","message":" 2023-12-04T18:23:19.7932543Z stdout F   File \"/opt/stackstorm/st2/lib/python3.8/site-packages/oslo_config/types.py\", line 145, in __call__","host":"st
{"timestamp":"2023-12-04T18:23:26+00:00","message":" 2023-12-04T18:23:19.79325789Z stdout F     value = int(value)","host":"stackstorm","severity":"info","facility":"user","sysl
{"timestamp":"2023-12-04T18:23:26+00:00","message":" 2023-12-04T18:23:19.793259422Z stdout F ValueError: invalid literal for int() with base 10: '610 # 10 mins'","host":"stackstorm
...

from stackstorm-k8s.

guzzijones avatar guzzijones commented on July 3, 2024

Whelp it turns out I STILL am not seeing graceful shutdowns. All executions immediately get abandoned.
I did some more digging.
Here we check the st2actionrunner service if it has any members.
But in the config for st2 coordination | service_registry defaults to FALSE.
So set service_registry = True in the coorination settings in the config.
We should probably make this the default?

from stackstorm-k8s.

guzzijones avatar guzzijones commented on July 3, 2024

I can confirm turning on the service registry fixed my graceful shutdown.

from stackstorm-k8s.

cognifloyd avatar cognifloyd commented on July 3, 2024

But in the config for st2 coordination | service_registry defaults to FALSE. So set service_registry = True in the coorination settings in the config. We should probably make this the default?

This looks like the right place to add anything in the chart:

{{- if index .Values "redis" "enabled" }}
[coordination]
url = redis://{{ template "stackstorm-ha.redis-password" $ }}{{ template "stackstorm-ha.redis-nodes" $ }}
{{- end }}

We could do this:

     {{- if index .Values "redis" "enabled" }}
     [coordination]
+    service_registry = True
     url = redis://{{ template "stackstorm-ha.redis-password" $ }}{{ template "stackstorm-ha.redis-nodes" $ }}
     {{- end }}

I do not use the redis subchart, so that would not change the default for me. I pass this in via st2.config in values. So, we could also do something like:

+    [coordination]
+    service_registry = True
     {{- if index .Values "redis" "enabled" }}
-    [coordination]
     url = redis://{{ template "stackstorm-ha.redis-password" $ }}{{ template "stackstorm-ha.redis-nodes" $ }}
     {{- end }}

Which option would you prefer? Or something else entirely?

from stackstorm-k8s.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.