Class TableDataServiceFactory
java.lang.Object
io.deephaven.enterprise.tabledataservice.TableDataServiceFactory
- All Implemented Interfaces:
io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin,io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.EndpointResolver
public class TableDataServiceFactory
extends Object
implements io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin
The standard factory for creating
TableDataService instances using a DataRoutingService instance-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classEach top level creation of a TableDataService requires recursive calls with access to a consistent context.Nested classes/interfaces inherited from interface io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin
io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin.DeferredDISEndpointServiceRegistryImpl, io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin.DeferredEndpointServiceRegistryImpl, io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin.DeferredLASEndpointServiceRegistryImpl -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionTableDataServiceFactory(@NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingService routingService, @NotNull SchemaService schemaService, @NotNull ProtocolDriverFactory driverFactory) Create a non-dynamicTableDataServiceFactoryusing theDataRoutingServiceas configuration.TableDataServiceFactory(@NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingService routingService, @NotNull SchemaService schemaService, @NotNull ProtocolDriverFactory driverFactory, boolean dynamic) Create aTableDataServiceFactoryusing theDataRoutingServiceas configuration. -
Method Summary
Modifier and TypeMethodDescription@Nullable TableDataServicecreateTableDataService(@NotNull String tdsName, boolean allowIOMessageFlush, boolean forProducer) Create aTableDataServiceby name, starting by getting the named configuration from theDataRoutingService.Make TableDataServices for testing - do not make remote connections, and ignore the "RTDS" aspect of composing TDSs (i.e.protected io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingServiceprotected RemoteTableDataServicemakeRemoteTableDataService(@NotNull String serviceName, @NotNull RemoteTableDataServiceDescriptor rtdsDescriptor) Create a newRemoteTableDataService, allowing for subclass overrides for testing.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.endpoint.DynamicResolverMixin
resolveLogAggregatorEndpoint, resolveTableDataEndpoint, resolveTailerEndpoint
-
Field Details
-
DEFAULT_TABLE_DATA_SERVICE_REQUEST_TIMEOUT
-
-
Constructor Details
-
TableDataServiceFactory
public TableDataServiceFactory(@NotNull @NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingService routingService, @NotNull @NotNull SchemaService schemaService, @NotNull @NotNull ProtocolDriverFactory driverFactory, boolean dynamic) Create aTableDataServiceFactoryusing theDataRoutingServiceas configuration.- Parameters:
routingService- theDataRoutingServiceschemaService- theSchemaServicedriverFactory- theProtocolDriverFactorydynamic- if true, listen for changes to the routing service and update dynamic TableDataServices
-
TableDataServiceFactory
public TableDataServiceFactory(@NotNull @NotNull io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingService routingService, @NotNull @NotNull SchemaService schemaService, @NotNull @NotNull ProtocolDriverFactory driverFactory) Create a non-dynamicTableDataServiceFactoryusing theDataRoutingServiceas configuration.- Parameters:
routingService- theDataRoutingServiceschemaService- theSchemaServicedriverFactory- theProtocolDriverFactory
-
-
Method Details
-
getLocalRoutingService
protected io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingService getLocalRoutingService() -
createTableDataService
@Nullable public @Nullable TableDataService createTableDataService(@NotNull @NotNull String tdsName, boolean allowIOMessageFlush, boolean forProducer) throws IOException Create aTableDataServiceby name, starting by getting the named configuration from theDataRoutingService.- Parameters:
tdsName- the name of theTableDataServiceto createallowIOMessageFlush- boolean to be passed to Remote TDS. Should be false for queries (because interruptions are expected).forProducer- the caller is a producer if true, else consumer. Consumers just connect to the config, producers connect to the embedded services and provide a remote TDS endpoint.- Returns:
- a
TableDataServiceas configured - Throws:
io.deephaven.shadow.enterprise.com.illumon.iris.db.v2.routing.DataRoutingConfigurationException- if the configuration is invalidIOException- if there is an error connecting to a remote service
-
makeRemoteTableDataService
protected RemoteTableDataService makeRemoteTableDataService(@NotNull @NotNull String serviceName, @NotNull @NotNull RemoteTableDataServiceDescriptor rtdsDescriptor) throws IOException Create a newRemoteTableDataService, allowing for subclass overrides for testing. This override assumes some of the parameters needed to construct aRemoteTableDataService. Connect to the remote service if not in test mode.- Parameters:
serviceName- the name to give the remote servicertdsDescriptor- all information required to configure and connect this RTDS- Returns:
- a new, possibly connected,
RemoteTableDataService - Throws:
IOException
-
forTesting
Make TableDataServices for testing - do not make remote connections, and ignore the "RTDS" aspect of composing TDSs (i.e. TDCP). For Deephaven internal use only.- Returns:
- this, for chaining
-