Class ServiceRegistrationHandler

java.lang.Object
ai.pipestream.registration.handlers.ServiceRegistrationHandler

@ApplicationScoped public class ServiceRegistrationHandler extends Object
Handles service registration operations.

Blocking — registration streams RegistrationEvents to the supplied sink as each step completes on the caller's virtual thread.

  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates the handler bean.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    registerService(ai.pipestream.platform.registration.v1.RegisterRequest request, Consumer<ai.pipestream.platform.registration.v1.RegistrationEvent> sink)
    Register a service with streaming status updates.
    ai.pipestream.platform.registration.v1.UnregisterResponse
    unregisterService(ai.pipestream.platform.registration.v1.UnregisterRequest request)
    Unregister a service using the unified UnregisterRequest.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ServiceRegistrationHandler

      public ServiceRegistrationHandler()
      Creates the handler bean. Its collaborators (Consul, health checker, OpenSearch producer, Apicurio client) are supplied by CDI field injection.
  • Method Details

    • registerService

      public void registerService(ai.pipestream.platform.registration.v1.RegisterRequest request, Consumer<ai.pipestream.platform.registration.v1.RegistrationEvent> sink)
      Register a service with streaming status updates. Expects RegisterRequest with type=SERVICE_TYPE_SERVICE. Emits each RegistrationEvent to sink as the flow progresses.
      Parameters:
      request - the service registration request
      sink - consumer that receives each RegistrationEvent as the flow progresses
    • unregisterService

      public ai.pipestream.platform.registration.v1.UnregisterResponse unregisterService(ai.pipestream.platform.registration.v1.UnregisterRequest request)
      Unregister a service using the unified UnregisterRequest.
      Parameters:
      request - the unregister request identifying the service by name, host, and port
      Returns:
      the unregister response indicating success and a status message