Class MockSchemaRegistry
java.lang.Object
org.apache.nifi.components.AbstractConfigurableComponent
org.apache.nifi.controller.AbstractControllerService
org.apache.nifi.serialization.record.MockSchemaRegistry
- All Implemented Interfaces:
org.apache.nifi.components.ConfigurableComponent,org.apache.nifi.controller.ControllerService,SchemaRegistry
public class MockSchemaRegistry
extends org.apache.nifi.controller.AbstractControllerService
implements SchemaRegistry
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ConcurrentMap<Tuple<Long, Integer>, RecordSchema> private final ConcurrentMap<Triple<String, String, Integer>, RecordSchema> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddSchema(String name, Integer version, RecordSchema schema) voidaddSchema(String name, String branch, Integer version, RecordSchema schema) voidaddSchema(String name, String branch, RecordSchema schema) voidaddSchema(String name, RecordSchema schema) retrieveSchema(SchemaIdentifier schemaIdentifier) private RecordSchemaretrieveSchemaByIdAndVersion(SchemaIdentifier schemaIdentifier) (package private) RecordSchemaretrieveSchemaByName(SchemaIdentifier schemaIdentifier) Methods inherited from class org.apache.nifi.controller.AbstractControllerService
abstractClearConfigContext, abstractStoreConfigContext, disabled, enabled, getConfigurationContext, getControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, getProperty, getStateManager, init, initialize, isEnabledMethods inherited from class org.apache.nifi.components.AbstractConfigurableComponent
customValidate, equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, getSupportedPropertyDescriptors, hashCode, onPropertyModified, toString, validateMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.nifi.components.ConfigurableComponent
getIdentifier, getPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validateMethods inherited from interface org.apache.nifi.controller.ControllerService
initialize, isStateful, migratePropertiesMethods inherited from interface org.apache.nifi.schemaregistry.services.SchemaRegistry
isSchemaDefinitionAccessSupported, retrieveSchemaDefinition
-
Field Details
-
schemaNameMap
-
schemaIdVersionMap
-
-
Constructor Details
-
MockSchemaRegistry
public MockSchemaRegistry()
-
-
Method Details
-
addSchema
-
addSchema
-
addSchema
-
addSchema
-
retrieveSchemaByName
- Throws:
SchemaNotFoundException
-
retrieveSchemaByIdAndVersion
private RecordSchema retrieveSchemaByIdAndVersion(SchemaIdentifier schemaIdentifier) throws SchemaNotFoundException - Throws:
SchemaNotFoundException
-
retrieveSchema
public RecordSchema retrieveSchema(SchemaIdentifier schemaIdentifier) throws SchemaNotFoundException - Specified by:
retrieveSchemain interfaceSchemaRegistry- Throws:
SchemaNotFoundException
-
getSuppliedSchemaFields
- Specified by:
getSuppliedSchemaFieldsin interfaceSchemaRegistry
-