Skip to content

ContinuousQueries.update() cannot send the fields the server now requires #4

Open

Description

@xe-nvdk

ContinuousQueries.update() and its async twin build the PUT body from only the kwargs passed, and the signature has no database, no source_measurement and no destination_measurement parameter at all:

  • src/arc_client/management/continuous_query.py:96-125
  • src/arc_client/management/async_continuous_query.py:96-106

PUT /api/v1/continuous_queries/:id replaces the whole definition, and Arc now requires a complete body:

Anything the body omits was previously written to the row as a blank, which is why the server closed it: a partial PUT silently wiped the stored definition.

What the fix needs

Three new parameters, and a read-modify-write rather than a sparse body: get(query_id), overlay the caller's kwargs, send the full definition. Worth noting the fields that are not required but are still overwritten — description, tag_columns, retention_days, delete_source_after_days, is_active — so a sparse body zeroes them; omitting is_active sets it False and stops the continuous query. Read-modify-write handles all of that in one go.

The documented example shows the already-broken partial call and needs the same change: docs.basekick.net/content/docs/arc/sdks/python/data-management.md:243-246 (and the enterprise copy at :237-241).

arcli is unaffected — it already does read-modify-write.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions