{
  "topic": "errors.CALLOUT_FAILED",
  "path": [
    "errors",
    "CALLOUT_FAILED"
  ],
  "title": "CALLOUT_FAILED — every try of a processor, criterion or function callout failed",
  "synopsis": "A callout is tried on one compute member after another: until one answers, until a failure forbids another try, or until the tries its `retryPolicy` allows are used (`NONE`: one try; `FIXED` or unset: one try plus `CYODA_RETRY_FIXED_NUM_RETRIES`). This code is returned when more than one try failed and nothing more could be done — every try was used, or no further compute member appeared within `CYODA_DISPATCH_WAIT_TIMEOUT`, or the time the callout may take ran out.",
  "body": "# errors.CALLOUT_FAILED\n\n## NAME\n\nCALLOUT_FAILED — a processor, criterion or function callout was tried on more than one compute member, and no try produced an answer.\n\n## SYNOPSIS\n\nHTTP: `503` `Service Unavailable`. Retryable: `yes`.\n\n## DESCRIPTION\n\nA callout is tried on one compute member after another: until one answers, until a failure forbids another try, or until the tries its `retryPolicy` allows are used (`NONE`: one try; `FIXED` or unset: one try plus `CYODA_RETRY_FIXED_NUM_RETRIES`). This code is returned when more than one try failed and nothing more could be done — every try was used, or no further compute member appeared within `CYODA_DISPATCH_WAIT_TIMEOUT`, or the time the callout may take ran out.\n\nThe message lists the failed tries:\n\n```\nCALLOUT_FAILED: the callout could not be completed, got 3 failures: [member<5f0c…>: DISPATCH_TIMEOUT: processor dispatch timed out after 30000ms: no response (2 times)], [member<->: DISPATCH_FORWARD_FAILED: forwarding the callout to a peer node failed]\n```\n\n- The count is the number of failed tries. Identical entries are written once, with `(k times)`.\n- `member<id>` is the id of the compute member that was tried — one of the caller's own tenant's connections, the id the member was given when it joined. `member<->` is a try handed over to another cluster node whose answer was lost, so that the member is not known.\n- Each entry carries the error code the try would have had on its own.\n\nWhen exactly one try was made and failed, that try's own code is returned instead (`errors.DISPATCH_TIMEOUT`, `errors.COMPUTE_MEMBER_DISCONNECTED`, `errors.DISPATCH_FORWARD_FAILED`), not this one. When no try could be made at all, the code is `errors.NO_COMPUTE_MEMBER_FOR_TAG`. A compute member that answered with a failure of its own is never replaced by another: that is `errors.WORKFLOW_FAILED`.\n\nA callout reaches a second compute member only where that is safe for Cyoda's own state: always when the work provably never left the node, and after the work was handed to a member only for a criterion, a function, or a processor whose configuration declares `idempotent: true`.\n\nRetryable, and `retryable: true` speaks for Cyoda's state only. With a `SYNC` or `ASYNC_SAME_TX` processor the operation failed and its transaction was rolled back, so running it again starts clean — unless an earlier `COMMIT_BEFORE_DISPATCH` processor of the same request had already committed. With a `COMMIT_BEFORE_DISPATCH` processor the part of the operation before the callout stays committed. A compute member that was handed the work may have carried it out; what it did outside Cyoda is the application's to reconcile.\n\n## SEE ALSO\n\n- errors\n- errors.DISPATCH_TIMEOUT\n- errors.COMPUTE_MEMBER_DISCONNECTED\n- errors.DISPATCH_FORWARD_FAILED\n- errors.NO_COMPUTE_MEMBER_FOR_TAG\n- workflows\n- config.grpc\n",
  "sections": [
    {
      "name": "NAME",
      "body": "CALLOUT_FAILED — a processor, criterion or function callout was tried on more than one compute member, and no try produced an answer."
    },
    {
      "name": "SYNOPSIS",
      "body": "HTTP: `503` `Service Unavailable`. Retryable: `yes`."
    },
    {
      "name": "DESCRIPTION",
      "body": "A callout is tried on one compute member after another: until one answers, until a failure forbids another try, or until the tries its `retryPolicy` allows are used (`NONE`: one try; `FIXED` or unset: one try plus `CYODA_RETRY_FIXED_NUM_RETRIES`). This code is returned when more than one try failed and nothing more could be done — every try was used, or no further compute member appeared within `CYODA_DISPATCH_WAIT_TIMEOUT`, or the time the callout may take ran out.\n\nThe message lists the failed tries:\n\n```\nCALLOUT_FAILED: the callout could not be completed, got 3 failures: [member<5f0c…>: DISPATCH_TIMEOUT: processor dispatch timed out after 30000ms: no response (2 times)], [member<->: DISPATCH_FORWARD_FAILED: forwarding the callout to a peer node failed]\n```\n\n- The count is the number of failed tries. Identical entries are written once, with `(k times)`.\n- `member<id>` is the id of the compute member that was tried — one of the caller's own tenant's connections, the id the member was given when it joined. `member<->` is a try handed over to another cluster node whose answer was lost, so that the member is not known.\n- Each entry carries the error code the try would have had on its own.\n\nWhen exactly one try was made and failed, that try's own code is returned instead (`errors.DISPATCH_TIMEOUT`, `errors.COMPUTE_MEMBER_DISCONNECTED`, `errors.DISPATCH_FORWARD_FAILED`), not this one. When no try could be made at all, the code is `errors.NO_COMPUTE_MEMBER_FOR_TAG`. A compute member that answered with a failure of its own is never replaced by another: that is `errors.WORKFLOW_FAILED`.\n\nA callout reaches a second compute member only where that is safe for Cyoda's own state: always when the work provably never left the node, and after the work was handed to a member only for a criterion, a function, or a processor whose configuration declares `idempotent: true`.\n\nRetryable, and `retryable: true` speaks for Cyoda's state only. With a `SYNC` or `ASYNC_SAME_TX` processor the operation failed and its transaction was rolled back, so running it again starts clean — unless an earlier `COMMIT_BEFORE_DISPATCH` processor of the same request had already committed. With a `COMMIT_BEFORE_DISPATCH` processor the part of the operation before the callout stays committed. A compute member that was handed the work may have carried it out; what it did outside Cyoda is the application's to reconcile."
    },
    {
      "name": "SEE ALSO",
      "body": "- errors\n- errors.DISPATCH_TIMEOUT\n- errors.COMPUTE_MEMBER_DISCONNECTED\n- errors.DISPATCH_FORWARD_FAILED\n- errors.NO_COMPUTE_MEMBER_FOR_TAG\n- workflows\n- config.grpc"
    }
  ],
  "see_also": [
    "errors",
    "errors.DISPATCH_TIMEOUT",
    "errors.COMPUTE_MEMBER_DISCONNECTED",
    "errors.DISPATCH_FORWARD_FAILED",
    "errors.NO_COMPUTE_MEMBER_FOR_TAG",
    "workflows",
    "config.grpc"
  ],
  "stability": "stable",
  "actions": []
}
