public class TableProviderManager extends Object
Modifier and Type | Field and Description |
---|---|
static boolean |
restartIsOK |
protected PriorityBlockingQueue<TableProviderControlImpl> |
restartQueue |
protected Map<String,TableProviderControlImpl> |
tableProviderMap |
Modifier and Type | Method and Description |
---|---|
void |
addDependentTable(CatalogedTable baseTable,
String dependentTableName)
It adds the dependent table name to the dependents maps that every table provider has.
|
void |
addTableProvider(com.streambase.liveview.internal.protocol.jaxb.ExternalServerConnectionType externalServer,
int retryCount)
Connect to a TableProvider, which then allows for remote connections as if they were LiveView Tables
|
Map<String,AbstractConfigObject> |
compileLVConfs(List<File> tableFiles,
boolean buildYaml) |
void |
createTable(String name,
LiveviewConfiguration conf,
boolean saveInProject) |
void |
deleteTable(CatalogedTable catalogedTable) |
void |
dropTables(List<String> tables) |
static TableProviderManager |
get() |
LiveViewServerConfig |
getConfig() |
File |
getCreateTableDir(boolean create) |
static String |
getJavaClassname(com.streambase.liveview.internal.protocol.jaxb.ExternalServerConnectionType externalServer) |
File |
getProjectBin()
Get the projectBin, which is the writable base directory where all stuff that we write should go.
|
TablesTable |
getTablesTable() |
static boolean |
hasDangerousConnection(AbstractConfigObject configObject) |
static void |
initialize(LiveViewServer lvServer) |
static void |
initialize(TablesTable tt,
TableColumnsTable tct,
LiveViewServerConfig conf,
StreamBaseConnectionPool sbConnPool) |
CatalogedTable |
registerFilteredTableAlias(CatalogedTable baseCatalogTable,
String predicateFilter,
String tableNameFormatter)
The method is used to register filtered tables from the base table
|
void |
registerNewTable(String name,
DataTable dataTable,
Table.TableStatus initialStatus,
String statusMessage) |
void |
removeTableProvider(String id)
Disconnect a previously-connected TableProvider.
|
void |
saveLVConf(String name,
LiveviewConfiguration conf,
boolean saveInProject) |
void |
shutdown() |
void |
startTables(List<String> tables) |
void |
validateTablesContainers() |
public static boolean restartIsOK
protected Map<String,TableProviderControlImpl> tableProviderMap
protected PriorityBlockingQueue<TableProviderControlImpl> restartQueue
public static TableProviderManager get()
public static void initialize(LiveViewServer lvServer)
public static void initialize(TablesTable tt, TableColumnsTable tct, LiveViewServerConfig conf, StreamBaseConnectionPool sbConnPool)
public void validateTablesContainers()
public TablesTable getTablesTable()
public LiveViewServerConfig getConfig()
public void addTableProvider(com.streambase.liveview.internal.protocol.jaxb.ExternalServerConnectionType externalServer, int retryCount) throws LiveViewException
externalServer
- id must be uniqueretryCount
- The number of failed tries we've already made.LiveViewException
public static String getJavaClassname(com.streambase.liveview.internal.protocol.jaxb.ExternalServerConnectionType externalServer)
public void removeTableProvider(String id) throws LiveViewException
id
- LiveViewException
public void shutdown() throws LiveViewException
LiveViewException
public void dropTables(List<String> tables) throws LiveViewException, TupleException, StreamBaseException
tables
- LiveViewException
TupleException
StreamBaseException
public void startTables(List<String> tables) throws LiveViewException, StreamBaseException, ConfigException, TupleException, NullValueException
tables
- LiveViewException
StreamBaseException
ConfigException
TupleException
NullValueException
public Map<String,AbstractConfigObject> compileLVConfs(List<File> tableFiles, boolean buildYaml) throws LiveViewException, StreamBaseException
LiveViewException
StreamBaseException
public File getCreateTableDir(boolean create)
public File getProjectBin()
public void deleteTable(CatalogedTable catalogedTable) throws TupleException, StreamBaseException
TupleException
StreamBaseException
public void createTable(String name, LiveviewConfiguration conf, boolean saveInProject) throws JAXBException, StreamBaseException
conf
- saveInProject
- TODOJAXBException
StreamBaseException
public void saveLVConf(String name, LiveviewConfiguration conf, boolean saveInProject) throws JAXBException, LiveViewException
JAXBException
LiveViewException
public void registerNewTable(String name, DataTable dataTable, Table.TableStatus initialStatus, String statusMessage) throws LiveViewException
LiveViewException
public CatalogedTable registerFilteredTableAlias(CatalogedTable baseCatalogTable, String predicateFilter, String tableNameFormatter) throws LiveViewException
baseCatalogTable
- predicateFilter
- tableNameFormatter
- LiveViewException
public static boolean hasDangerousConnection(AbstractConfigObject configObject)
public void addDependentTable(CatalogedTable baseTable, String dependentTableName)
baseTable
- dependentTableName
-