Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't set liveness-ttl flag using JETSTREAM_LIVENESS_TTL environment variable #28

Open
tom-sherman opened this issue Nov 20, 2024 · 2 comments

Comments

@tom-sherman
Copy link

tom-sherman commented Nov 20, 2024

Version: https://github.com/bluesky-social/jetstream/pkgs/container/jetstream/307057313?tag=sha-2aacb58

Steps to reproduce:

  1. Set JETSTREAM_LIVENESS_TTL=30s in your environment
  2. Run jetstream against an event stream that doesn't send any events (eg. a PDS running locally)

Expected behaviour:

Jetstream shuts down after 30 seconds.

Actual behaviour:

Jetstream shuts down after 15s and logs the message:

no new events in last 15 seconds, shutting down for docker to restart me

Additional context

This appears to be expected behaviour of urfave/cli. The default value used to be able to be overridden by an env var but that was "fixed" in urfave/cli#1528.

@tom-sherman tom-sherman changed the title Can't setliveness-ttl flag using JETSTREAM_LIVENESS_TTL environment variable Can't set liveness-ttl flag using JETSTREAM_LIVENESS_TTL environment variable Nov 20, 2024
@tom-sherman
Copy link
Author

tom-sherman commented Nov 20, 2024

Oh, actually maybe it's not a bug with jetstream actually. the option isn't available on the version of jetstream I'm using but it's the latest container that has been published on ghcr.

Is ghcr not up to date?

@tom-sherman
Copy link
Author

I changed to sha-0ab10bd (a version published 20 days ago instead of sha-2aacb58 which was published 3 days ago) and it works fine.

tom-sherman added a commit to likeandscribe/frontpage that referenced this issue Nov 20, 2024
tom-sherman added a commit to likeandscribe/frontpage that referenced this issue Nov 22, 2024
* ripped it all out

* we fetching

* pretty print json_strings coming back from jetstream

* tmp removed env for ws url and added commit filter

* Implement jetstream and sled

* Allow customising endpoint from env

* Run jetstream in local infra

* "Downgrade" jetstream

See bluesky-social/jetstream#28 (comment)

* Massage receive hook payload to match current old shape

* Update comment

* Reconnect logic

* Oops

* Better error handling

* Add missing env var

* jetstream1 -> jetstream2

* Update env vars

---------

Co-authored-by: Damein Sedgwick <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant