UNPKG

@aneoconsultingfr/armonik.api

Version:

gRPC API to interact with ArmoniK built for the web

48 lines (45 loc) 2.07 kB
import { Observable } from 'rxjs'; import { EventSubscriptionRequest, EventSubscriptionResponse } from './events_common.mjs'; import './results_filters.mjs'; import './filters_common.mjs'; import 'protobufjs/minimal.js'; import './google/protobuf/duration.mjs'; import './results_fields.mjs'; import './result_status.mjs'; import './tasks_filters.mjs'; import './tasks_fields.mjs'; import './task_status.mjs'; declare const protobufPackage = "armonik.api.grpc.v1.events"; /** * Events subscription related methods within a service. * * This service can be used to receive events related to the update of tasks * and results whithin a session. * The endpoint can be called to listen to the modifications of multiple sessions * if needed. * * Note: As for now, all the events of a session will be sent whithout filtering. * It is possible that the API will evolve to a more refined way to filter the events * to be received. */ /** Service for subscribing to events representing modifications to ArmoniK result and task data */ interface Events { /** Get events that represents updates of result and tasks data. */ GetEvents(request: EventSubscriptionRequest): Observable<EventSubscriptionResponse>; } declare const EventsServiceName = "armonik.api.grpc.v1.events.Events"; declare class EventsClientImpl implements Events { private readonly rpc; private readonly service; constructor(rpc: Rpc, opts?: { service?: string; }); GetEvents(request: EventSubscriptionRequest): Observable<EventSubscriptionResponse>; } interface Rpc { request(service: string, method: string, data: Uint8Array): Promise<Uint8Array>; clientStreamingRequest(service: string, method: string, data: Observable<Uint8Array>): Promise<Uint8Array>; serverStreamingRequest(service: string, method: string, data: Uint8Array): Observable<Uint8Array>; bidirectionalStreamingRequest(service: string, method: string, data: Observable<Uint8Array>): Observable<Uint8Array>; } export { Events, EventsClientImpl, EventsServiceName, protobufPackage };