Class ServiceInfo

    • Constructor Detail

      • ServiceInfo

        public ServiceInfo​(@NotNull
                           @NotNull UUID originNodeId,
                           @NotNull
                           @NotNull IgniteUuid srvcId,
                           @NotNull
                           @NotNull LazyServiceConfiguration cfg)
        Parameters:
        originNodeId - Initiating node id.
        srvcId - Service id.
        cfg - Service configuration.
      • ServiceInfo

        public ServiceInfo​(@NotNull
                           @NotNull UUID originNodeId,
                           @NotNull
                           @NotNull IgniteUuid srvcId,
                           @NotNull
                           @NotNull LazyServiceConfiguration cfg,
                           boolean staticCfg)
        Parameters:
        originNodeId - Initiating node id.
        srvcId - Service id.
        cfg - Service configuration.
        staticCfg - Statically configured flag.
    • Method Detail

      • context

        public void context​(GridKernalContext ctx)
        Sets kernal context.
        Parameters:
        ctx - Context.
      • topologySnapshot

        public void topologySnapshot​(@NotNull
                                     @NotNull Map<UUID,​Integer> top)
        Sets service's new topology snapshot.
        Parameters:
        top - Topology snapshot.
      • configuration

        public LazyServiceConfiguration configuration()
        Returns service's configuration.
        Returns:
        Service configuration.
      • staticallyConfigured

        public boolean staticallyConfigured()
        Returns:
        true if statically configured.
      • serviceId

        public IgniteUuid serviceId()
        Rerurns services id.
        Returns:
        Service id.
      • totalCount

        public int totalCount()
        Gets maximum allowed total number of deployed services in the grid, 0 for unlimited.
        Specified by:
        totalCount in interface ServiceDescriptor
        Returns:
        Maximum allowed total number of deployed services in the grid, 0 for unlimited.
      • maxPerNodeCount

        public int maxPerNodeCount()
        Gets maximum allowed number of deployed services on each node, 0 for unlimited.
        Specified by:
        maxPerNodeCount in interface ServiceDescriptor
        Returns:
        Maximum allowed total number of deployed services on each node, 0 for unlimited.
      • cacheName

        @Nullable
        public @Nullable String cacheName()
        Gets cache name used for key-to-node affinity calculation. This parameter is optional and is set only when key-affinity service was deployed.
        Specified by:
        cacheName in interface ServiceDescriptor
        Returns:
        Cache name, possibly null.
      • affinityKey

        @Nullable
        public <K> K affinityKey()
        Gets affinity key used for key-to-node affinity calculation. This parameter is optional and is set only when key-affinity service was deployed.
        Specified by:
        affinityKey in interface ServiceDescriptor
        Type Parameters:
        K - Affinity key type.
        Returns:
        Affinity key, possibly null.
      • originNodeId

        public UUID originNodeId()
        Gets ID of grid node that initiated the service deployment.
        Specified by:
        originNodeId in interface ServiceDescriptor
        Returns:
        ID of grid node that initiated the service deployment.
      • topologySnapshot

        public Map<UUID,​Integer> topologySnapshot()
        Gets service deployment topology snapshot. Service topology snapshot is represented by number of service instances deployed on a node mapped to node ID.
        Specified by:
        topologySnapshot in interface ServiceDescriptor
        Returns:
        Map of number of service instances per node ID.
      • topologyInitialized

        public boolean topologyInitialized()
        Whether service topology was initialized.
        Returns:
        True if service topology was initialized.