public final class SchemaRegistryService extends Object
| Constructor and Description |
|---|
SchemaRegistryService(RegistryCenterRepository repository) |
| Modifier and Type | Method and Description |
|---|---|
void |
delete(String schemaName)
Delete schema.
|
Optional<org.apache.shardingsphere.infra.metadata.schema.ShardingSphereSchema> |
load(String schemaName)
Load schema.
|
Collection<String> |
loadAllNames()
Load all schema names.
|
void |
persist(String schemaName,
org.apache.shardingsphere.infra.metadata.schema.ShardingSphereSchema schema)
Persist schema.
|
void |
update(DatabaseCreatedSQLNotificationEvent event)
Update when database created.
|
void |
update(DatabaseDroppedSQLNotificationEvent event)
Update when database dropped.
|
void |
update(org.apache.shardingsphere.infra.metadata.schema.refresher.event.SchemaAlteredEvent event)
Update when meta data altered.
|
public SchemaRegistryService(RegistryCenterRepository repository)
public void persist(String schemaName, org.apache.shardingsphere.infra.metadata.schema.ShardingSphereSchema schema)
schemaName - schema name to be persistedschema - schema to be persistedpublic void delete(String schemaName)
schemaName - schema name to be deletedpublic Optional<org.apache.shardingsphere.infra.metadata.schema.ShardingSphereSchema> load(String schemaName)
schemaName - schema name to be loadedpublic Collection<String> loadAllNames()
public void update(DatabaseCreatedSQLNotificationEvent event)
event - database created SQL notification eventpublic void update(org.apache.shardingsphere.infra.metadata.schema.refresher.event.SchemaAlteredEvent event)
event - schema altered eventpublic void update(DatabaseDroppedSQLNotificationEvent event)
event - database dropped SQL notification eventCopyright © 2021 The Apache Software Foundation. All rights reserved.