Skip to content

gRPC client-streaming loads (InsertStream, InsertBidirectional, GraphBatchLoad, TimeSeriesWriteStream) are not listed in the running-query registry, so no terminate reaches them #9875

Closed

Description

@robfrank

Summary

Sibling of #9838 on the gRPC transport. #9838 made every /ws insert chunk listed in the running-query registry (so list queries sees it and terminate query stops it) whatever its transactionMode. The gRPC client-streaming loads - InsertStream, InsertBidirectional, GraphBatchLoad, TimeSeriesWriteStream - still open no registry entry at all.

GrpcAdmissionInterceptor.isGated requires method.getType().clientSendsOneMessage(), and registration (issue #9689) happens only inside the gated listener, so the same predicate that keeps these RPCs out of the admission gate also keeps them out of the registry. The class javadoc explains why they are not GATED (a refusal between two chunks would have to go through each stream's own error path), but nothing argues they should not be LISTED. grep -n RunningQuery grpcw/src/main/java finds no entry opened in insertStream, insertBidirectional, graphBatchLoad or timeSeriesWriteStream.

Consequence

A gRPC bulk load - which in PER_STREAM-like transaction modes holds one write transaction for the whole stream - is invisible to list queries / SHOW TRANSACTIONS and cannot be stopped by terminate query, the same defect #9838 fixed for /ws.

Suggested fix

Open an entry per stream (or per chunk, bound on the stream's executor thread with RunningQuery.bind()), statement text naming the RPC and its transaction mode; on termination roll back what the stream's mode can still retract and close the call with a terminal status, as /ws now does.

Why not in #9838

Different module (grpcw) and four RPCs with their own per-stream state machines and executors; #9838 is scoped to the /ws insert session.

Activity

  1. added this to the 26.11.1 milestone on Oct 12, 2026
  2. added
    grpcgRPC wire protocol (grpc/grpc-client/grpcw)
    on Oct 12, 2026
  3. self-assigned this
    on Oct 13, 2026
  4. added a commit that references this issue on Oct 13, 2026
  5. robfrank commented on Oct 13, 2026

    @robfrank
    CollaboratorAuthor

    Fixed in #9933. The four gRPC client-streaming loads (InsertStream, InsertBidirectional, GraphBatchLoad, TimeSeriesWriteStream) now appear in list queries from their first chunk to the end of the stream, and terminate query stops them, also while they sit idle between chunks. A terminated load ends with CANCELLED and undoes what its mode allows: an insert rolls back its open transaction or batch (rows already committed under per-row or earlier batches stay), a graph batch drops its buffer, and a time-series stream stops appending. The unary BulkInsert can now also be stopped between rows.

    Still open: ending a terminated load that runs inside a client transaction waits on that transaction's thread with no timeout, as every chunk of such a stream already does.


    ❤️ Thanks for helping make ArcadeDB better! ArcadeDB is free and open source, sustained by its community. If it's useful to you or your company, please consider becoming a sponsor to keep development going.

  6. removed
    in progressThe team is actively working on this issue
    on Oct 13, 2026
  7. added a commit that references this issue on Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

buggrpcgRPC wire protocol (grpc/grpc-client/grpcw)observabilityMetrics, tracing, profilingseverity:minorCosmetic, documentation, edge case, or a workaround exists

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions