Class BaseGrpcScheme<T extends com.tangosol.internal.net.grpc.DefaultRemoteGrpcServiceDependencies,S extends Service>
- java.lang.Object
-
- com.tangosol.coherence.config.scheme.AbstractScheme
-
- com.tangosol.coherence.config.scheme.AbstractServiceScheme<D>
-
- com.tangosol.coherence.config.scheme.AbstractCachingScheme<T>
-
- com.tangosol.coherence.config.scheme.BaseGrpcScheme<T,S>
-
- All Implemented Interfaces:
BackingMapManagerBuilder
,MapBuilder
,NamedCacheBuilder
,ServiceBuilder
,CachingScheme
,ObservableCachingScheme
,Scheme
,ServiceScheme
- Direct Known Subclasses:
BaseGrpcCacheScheme
public abstract class BaseGrpcScheme<T extends com.tangosol.internal.net.grpc.DefaultRemoteGrpcServiceDependencies,S extends Service> extends AbstractCachingScheme<T>
TheBaseGrpcScheme
is responsible for building a remote gRPC service.This class is sub-classed in the Coherence Java gRPC client module and that subclass does all the actual work. This allows the grpc remote scheme to be added to a cache configuration file even if the gRPC client is not on the class path and nothing will break.
- Since:
- 23.03
- Author:
- Jonathan Knight 2023.02.02
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.tangosol.coherence.config.builder.MapBuilder
MapBuilder.Dependencies
-
-
Field Summary
-
Fields inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
m_serviceDependencies
-
Fields inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
DELIM_APPLICATION_SCOPE, DELIM_DOMAIN_PARTITION
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
BaseGrpcScheme(T deps)
Constructs aBaseGrpcScheme
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ClusterDependencies.ServiceProvider
getServiceProvider()
Returns theClusterDependencies.ServiceProvider
instance to use to create new instances of the service.boolean
isRunningClusterNeeded()
Return true if a running cluster is needed before using a service.void
setRemoteScopeName(String sName)
Set the scope name to use to access resources on the remote cluster.-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractCachingScheme
establishMapListeners, getDefaultParameterResolver, getListenerBuilder, realizeBackingMapManager, realizeCache, realizeMap, setListenerBuilder, validate
-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
ensureService, getDefaultServiceName, getEventInterceptorBuilders, getScopedServiceName, getScopeName, getServiceBuilder, getServiceDependencies, getServiceName, getXml, injectScopeNameIntoService, isAutoStart, realizeService, setAutoStart, setScopeName, setServiceDependencies, setServiceName, setXml
-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractScheme
getSchemeName, isAnonymous, setSchemeName, validate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.tangosol.coherence.config.scheme.Scheme
getSchemeName, isAnonymous
-
Methods inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
getEventInterceptorBuilders, getScopedServiceName, getServiceBuilder, getServiceName, getServiceType, isAutoStart
-
-
-
-
Constructor Detail
-
BaseGrpcScheme
protected BaseGrpcScheme(T deps)
Constructs aBaseGrpcScheme
.
-
-
Method Detail
-
setRemoteScopeName
@Injectable public void setRemoteScopeName(String sName)
Set the scope name to use to access resources on the remote cluster.- Parameters:
sName
- the scope name to use to access resources on the remote cluster
-
isRunningClusterNeeded
public boolean isRunningClusterNeeded()
Description copied from class:AbstractServiceScheme
Return true if a running cluster is needed before using a service.- Specified by:
isRunningClusterNeeded
in interfaceServiceBuilder
- Specified by:
isRunningClusterNeeded
in classAbstractServiceScheme<T extends com.tangosol.internal.net.grpc.DefaultRemoteGrpcServiceDependencies>
- Returns:
true
if a running cluster is needed before using a service
-
getServiceProvider
protected ClusterDependencies.ServiceProvider getServiceProvider()
Returns theClusterDependencies.ServiceProvider
instance to use to create new instances of the service.- Returns:
- the
ClusterDependencies.ServiceProvider
instance to use to create new instances of the service
-
-