public class MockSchemaRegistryClient extends Object implements SchemaRegistryClient
| Constructor and Description |
|---|
MockSchemaRegistryClient() |
MockSchemaRegistryClient(List<SchemaProvider> providers) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclose, deleteCompatibility, deleteConfig, deleteMode, deleteSchemaVersion, deleteSchemaVersion, deleteSubject, deleteSubject, getAllSubjects, getAllVersions, getById, getByID, getBySubjectAndId, getBySubjectAndID, getCompatibility, getId, getVersion, parseSchema, register, register, registerWithResponse, tenant, testCompatibility, testCompatibilityVerbose, ticker, updateCompatibilitypublic MockSchemaRegistryClient()
public MockSchemaRegistryClient(List<SchemaProvider> providers)
public Optional<ParsedSchema> parseSchema(String schemaType, String schemaString, List<SchemaReference> references)
parseSchema in interface SchemaRegistryClientpublic Optional<ParsedSchema> parseSchema(Schema schema)
parseSchema in interface SchemaRegistryClientpublic int register(String subject, ParsedSchema schema) throws IOException, RestClientException
register in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int register(String subject, ParsedSchema schema, boolean normalize) throws IOException, RestClientException
register in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int register(String subject, ParsedSchema schema, int version, int id) throws IOException, RestClientException
register in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic RegisterSchemaResponse registerWithResponse(String subject, ParsedSchema schema, boolean normalize, boolean propagateSchemaTags) throws RestClientException
registerWithResponse in interface SchemaRegistryClientRestClientExceptionpublic ParsedSchema getSchemaById(int id) throws IOException, RestClientException
getSchemaById in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic ParsedSchema getSchemaBySubjectAndId(String subject, int id) throws IOException, RestClientException
getSchemaBySubjectAndId in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic List<ParsedSchema> getSchemas(String subjectPrefix, boolean lookupDeletedSchema, boolean latestOnly) throws IOException, RestClientException
getSchemas in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Collection<String> getAllSubjectsById(int id)
getAllSubjectsById in interface SchemaRegistryClientpublic Collection<SubjectVersion> getAllVersionsById(int id)
getAllVersionsById in interface SchemaRegistryClientpublic Schema getByVersion(String subject, int version, boolean lookupDeletedSchema)
getByVersion in interface SchemaRegistryClientgetByVersion in interface SchemaVersionFetcherpublic SchemaMetadata getSchemaMetadata(String subject, int version) throws IOException, RestClientException
getSchemaMetadata in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic SchemaMetadata getSchemaMetadata(String subject, int version, boolean lookupDeletedSchema) throws RestClientException
getSchemaMetadata in interface SchemaRegistryClientRestClientExceptionpublic SchemaMetadata getLatestSchemaMetadata(String subject) throws IOException, RestClientException
getLatestSchemaMetadata in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic SchemaMetadata getLatestWithMetadata(String subject, Map<String,String> metadata, boolean lookupDeletedSchema) throws IOException, RestClientException
getLatestWithMetadata in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int getVersion(String subject, ParsedSchema schema) throws IOException, RestClientException
getVersion in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int getVersion(String subject, ParsedSchema schema, boolean normalize) throws IOException, RestClientException
getVersion in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic List<Integer> getAllVersions(String subject) throws IOException, RestClientException
getAllVersions in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic boolean testCompatibility(String subject, ParsedSchema newSchema) throws IOException, RestClientException
testCompatibility in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int getId(String subject, ParsedSchema schema) throws IOException, RestClientException
getId in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic int getId(String subject, ParsedSchema schema, boolean normalize) throws IOException, RestClientException
getId in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic List<Integer> deleteSubject(String subject, boolean isPermanent) throws IOException, RestClientException
deleteSubject in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic List<Integer> deleteSubject(Map<String,String> requestProperties, String subject, boolean isPermanent) throws IOException, RestClientException
deleteSubject in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Integer deleteSchemaVersion(String subject, String version, boolean isPermanent) throws IOException, RestClientException
deleteSchemaVersion in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Integer deleteSchemaVersion(Map<String,String> requestProperties, String subject, String version, boolean isPermanent) throws IOException, RestClientException
deleteSchemaVersion in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic List<String> testCompatibilityVerbose(String subject, ParsedSchema newSchema) throws IOException, RestClientException
testCompatibilityVerbose in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Config updateConfig(String subject, Config config) throws IOException, RestClientException
updateConfig in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Config getConfig(String subject) throws IOException, RestClientException
getConfig in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic String setMode(String mode) throws IOException, RestClientException
setMode in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic String setMode(String mode, String subject) throws IOException, RestClientException
setMode in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic String setMode(String mode, String subject, boolean force) throws IOException, RestClientException
setMode in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic String getMode() throws IOException, RestClientException
getMode in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic String getMode(String subject) throws IOException, RestClientException
getMode in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Collection<String> getAllContexts() throws IOException, RestClientException
getAllContexts in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Collection<String> getAllSubjects() throws IOException, RestClientException
getAllSubjects in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic Collection<String> getAllSubjectsByPrefix(String subjectPrefix) throws IOException, RestClientException
getAllSubjectsByPrefix in interface SchemaRegistryClientIOExceptionRestClientExceptionpublic void reset()
reset in interface SchemaRegistryClientCopyright © 2025 Confluent, Inc.. All rights reserved.