Class ServiceMetadata

java.lang.Object
dev.restate.admin.model.ServiceMetadata

public class ServiceMetadata extends Object
ServiceMetadata
  • Field Details

  • Constructor Details

    • ServiceMetadata

      public ServiceMetadata()
  • Method Details

    • name

      public ServiceMetadata name(@Nonnull String name)
    • getName

      @Nonnull public String getName()
      Fully qualified name of the service
      Returns:
      name
    • setName

      public void setName(@Nonnull String name)
    • handlers

      public ServiceMetadata handlers(@Nonnull List<HandlerMetadata> handlers)
    • addHandlersItem

      public ServiceMetadata addHandlersItem(HandlerMetadata handlersItem)
    • getHandlers

      @Nonnull public List<HandlerMetadata> getHandlers()
      Get handlers
      Returns:
      handlers
    • setHandlers

      public void setHandlers(@Nonnull List<HandlerMetadata> handlers)
    • ty

      public ServiceMetadata ty(@Nonnull ServiceType ty)
    • getTy

      @Nonnull public ServiceType getTy()
      Get ty
      Returns:
      ty
    • setTy

      public void setTy(@Nonnull ServiceType ty)
    • documentation

      public ServiceMetadata documentation(@Nullable String documentation)
    • getDocumentation

      @Nullable public String getDocumentation()
      Documentation of the service, as propagated by the SDKs.
      Returns:
      documentation
    • setDocumentation

      public void setDocumentation(@Nullable String documentation)
    • metadata

      public ServiceMetadata metadata(@Nullable Map<String,String> metadata)
    • putMetadataItem

      public ServiceMetadata putMetadataItem(String key, String metadataItem)
    • getMetadata

      @Nullable public Map<String,String> getMetadata()
      Additional service metadata, as propagated by the SDKs.
      Returns:
      metadata
    • setMetadata

      public void setMetadata(@Nullable Map<String,String> metadata)
    • deploymentId

      public ServiceMetadata deploymentId(@Nonnull String deploymentId)
    • getDeploymentId

      @Nonnull public String getDeploymentId()
      Deployment exposing the latest revision of the service.
      Returns:
      deploymentId
    • setDeploymentId

      public void setDeploymentId(@Nonnull String deploymentId)
    • revision

      public ServiceMetadata revision(@Nonnull Integer revision)
    • getRevision

      @Nonnull public Integer getRevision()
      Latest revision of the service. minimum: 0
      Returns:
      revision
    • setRevision

      public void setRevision(@Nonnull Integer revision)
    • _public

      public ServiceMetadata _public(@Nonnull Boolean _public)
    • getPublic

      @Nonnull public Boolean getPublic()
      If true, the service can be invoked through the ingress. If false, the service can be invoked only from another Restate service.
      Returns:
      _public
    • setPublic

      public void setPublic(@Nonnull Boolean _public)
    • idempotencyRetention

      public ServiceMetadata idempotencyRetention(@Nonnull String idempotencyRetention)
    • getIdempotencyRetention

      @Nonnull public String getIdempotencyRetention()
      The retention duration of idempotent requests for this service.
      Returns:
      idempotencyRetention
    • setIdempotencyRetention

      public void setIdempotencyRetention(@Nonnull String idempotencyRetention)
    • workflowCompletionRetention

      public ServiceMetadata workflowCompletionRetention(@Nullable String workflowCompletionRetention)
    • getWorkflowCompletionRetention

      @Nullable public String getWorkflowCompletionRetention()
      The retention duration of workflows. Only available on workflow services.
      Returns:
      workflowCompletionRetention
    • setWorkflowCompletionRetention

      public void setWorkflowCompletionRetention(@Nullable String workflowCompletionRetention)
    • inactivityTimeout

      public ServiceMetadata inactivityTimeout(@Nullable String inactivityTimeout)
    • getInactivityTimeout

      @Nullable public String getInactivityTimeout()
      This timer guards against stalled service/handler invocations. Once it expires, Restate triggers a graceful termination by asking the service invocation to suspend (which preserves intermediate progress). The 'abort timeout' is used to abort the invocation, in case it doesn't react to the request to suspend. Can be configured using the [`humantime`](https://docs.rs/humantime/latest/humantime/fn.parse_duration.html) format. This overrides the default inactivity timeout set in invoker options.
      Returns:
      inactivityTimeout
    • setInactivityTimeout

      public void setInactivityTimeout(@Nullable String inactivityTimeout)
    • abortTimeout

      public ServiceMetadata abortTimeout(@Nullable String abortTimeout)
    • getAbortTimeout

      @Nullable public String getAbortTimeout()
      This timer guards against stalled service/handler invocations that are supposed to terminate. The abort timeout is started after the 'inactivity timeout' has expired and the service/handler invocation has been asked to gracefully terminate. Once the timer expires, it will abort the service/handler invocation. This timer potentially **interrupts** user code. If the user code needs longer to gracefully terminate, then this value needs to be set accordingly. Can be configured using the [`humantime`](https://docs.rs/humantime/latest/humantime/fn.parse_duration.html) format. This overrides the default abort timeout set in invoker options.
      Returns:
      abortTimeout
    • setAbortTimeout

      public void setAbortTimeout(@Nullable String abortTimeout)
    • equals

      public boolean equals(Object o)
      Return true if this ServiceMetadata object is equal to o.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toUrlQueryString

      public String toUrlQueryString()
      Convert the instance into URL query string.
      Returns:
      URL query string
    • toUrlQueryString

      public String toUrlQueryString(String prefix)
      Convert the instance into URL query string.
      Parameters:
      prefix - prefix of the query string
      Returns:
      URL query string