daemon.stores.containers module

class daemon.stores.containers.ContainerStore[source]

Bases: daemon.stores.base.BaseStore, abc.ABC

A Store of Containers spawned by daemon

  • abstract async add_in_partial(uri, envs, \args, **kwargs*)[source]

    Implements jina object creation in partial-daemon

  • abstract async delete_in_partial(uri, \args, **kwargs*)[source]

    Implements jina object termination in partial-daemon

  • async ready(uri)[source]

    Check if the container with partial-daemon is alive

    • Parameters

      uri – uri of partial-daemon

      Return type

      bool

      Returns

      True if partial-daemon is ready

  • add(\args, **kwargs*)

    Add a new element to the store. This method needs to be overridden by the subclass

  • delete(\args, **kwargs*)

    Deletes an element from the store. This method needs to be overridden by the subclass

  • async clear(\*kwargs*)[source]

    Delete all the objects in the store

    • Parameters

      kwargs – keyward args

      Return type

      None