TritonDataCenter / TritonDataCenter/sdc-cloudapi

cueball HTTP agent config missing pinger or TCP keepalives

Open
#42 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
8
Forks
22
Avg merge
3d 9h
Merged PRs (30d)
1

Description

The current CueballHttpAgent config we're using in cloudapi is missing a pinger or TCP keepalive settings, which means that we can easily get "zombie" connections or races when cloudapi is talking to other components (like imgapi or napi) -- while cloudapi is writing a request out to a socket, the other end is closing it, and we get ECONNRESET errors.

It seems like all of the downstream services have a /ping endpoint, or at least don't respond with an error to that URI, so we should just need to add:

        "tcpKeepAliveInitialDelay": 10000,
        "ping": "/ping",
        "pingInterval": 60000,

We'll have to update the version of cueball as well, since the version we're using at the moment (2.1.1) has a bug that causes pingers to misbehave (joyent/node-cueball#102)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Find the cloudapi configuration that constructs CueballHttpAgent and inspect the dependency entry for cueball 2.1.1. Confirm the required pinger and TCP keepalive settings against the downstream /ping endpoints, then update cueball and verify the configuration prevents the reported connection-reset scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.