Class CompositeTableDataService
java.lang.Object
com.illumon.iris.db.v2.tabledataservice.AbstractTableDataService
com.illumon.iris.db.v2.tabledataservice.CompositeTableDataService
- All Implemented Interfaces:
TableDataService
,NamedImplementation
Routing TableDataService that applies a selector function to pick service(s) for each request.
It is assumed that each service will provide access to a non-overlapping set of table locations for any table key.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface com.illumon.iris.db.v2.tabledataservice.TableDataService
TableDataService.Null
-
Constructor Summary
ConstructorsConstructorDescriptionCompositeTableDataService
(String name, CompositeTableDataService.ServiceSelector serviceSelector) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Authenticate the TableDataService usingAuthenticationClientManager.getDefault()
describe()
Like toString, but with more detail.protected TableLocationProvider
makeTableLocationProvider
(TableKey tableKey) void
reset()
Forget all state for future requests.void
Forget all state for a single table.toString()
Methods inherited from class com.illumon.iris.db.v2.tabledataservice.AbstractTableDataService
getKey, getKnownLocationProviders, getName, getTableLocationProvider
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.illumon.util.type.NamedImplementation
getImplementationName
Methods inherited from interface com.illumon.iris.db.v2.tabledataservice.TableDataService
getTableLocationProvider, shutdown
-
Constructor Details
-
CompositeTableDataService
public CompositeTableDataService(@NotNull String name, @NotNull CompositeTableDataService.ServiceSelector serviceSelector) - Parameters:
name
- optional name for this serviceserviceSelector
- Function to map a table key to a set of services that should be queried.
-
-
Method Details
-
authenticate
public void authenticate()Description copied from interface:TableDataService
Authenticate the TableDataService usingAuthenticationClientManager.getDefault()
-
reset
public void reset()Description copied from interface:TableDataService
Forget all state for future requests.- Specified by:
reset
in interfaceTableDataService
- Overrides:
reset
in classAbstractTableDataService
-
reset
Description copied from interface:TableDataService
Forget all state for a single table.- Specified by:
reset
in interfaceTableDataService
- Overrides:
reset
in classAbstractTableDataService
- Parameters:
key
- forget state for this TableKey
-
makeTableLocationProvider
- Specified by:
makeTableLocationProvider
in classAbstractTableDataService
-
toString
- Overrides:
toString
in classAbstractTableDataService
-
describe
Description copied from interface:TableDataService
Like toString, but with more detail.- Returns:
- a description string
-