Class SchemasResourceBase

Direct Known Subclasses:
SchemasResource, SchemasResource

public class SchemasResourceBase extends AdminResource
  • Constructor Details

    • SchemasResourceBase

      public SchemasResourceBase()
    • SchemasResourceBase

      public SchemasResourceBase(Clock clock)
  • Method Details

    • getLongSchemaVersion

      protected static long getLongSchemaVersion(org.apache.pulsar.common.protocol.schema.SchemaVersion schemaVersion)
    • getSchema

      public void getSchema(boolean authoritative, javax.ws.rs.container.AsyncResponse response)
    • getSchemaAsync

      public CompletableFuture<SchemaRegistry.SchemaAndMetadata> getSchemaAsync(boolean authoritative)
    • getSchema

      public void getSchema(boolean authoritative, String version, javax.ws.rs.container.AsyncResponse response)
    • getSchemaAsync

      public CompletableFuture<SchemaRegistry.SchemaAndMetadata> getSchemaAsync(boolean authoritative, String version)
    • getAllSchemas

      public void getAllSchemas(boolean authoritative, javax.ws.rs.container.AsyncResponse response)
    • getAllSchemasAsync

      public CompletableFuture<List<SchemaRegistry.SchemaAndMetadata>> getAllSchemasAsync(boolean authoritative)
    • deleteSchema

      public void deleteSchema(boolean authoritative, javax.ws.rs.container.AsyncResponse response, boolean force)
    • deleteSchemaAsync

      public CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> deleteSchemaAsync(boolean authoritative, boolean force)
    • postSchema

      public void postSchema(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative, javax.ws.rs.container.AsyncResponse response)
    • postSchemaAsync

      public CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> postSchemaAsync(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative)
    • testCompatibility

      public void testCompatibility(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative, javax.ws.rs.container.AsyncResponse response)
    • testCompatibilityAsync

      public CompletableFuture<org.apache.commons.lang3.tuple.Pair<Boolean,org.apache.pulsar.common.policies.data.SchemaCompatibilityStrategy>> testCompatibilityAsync(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative)
    • getVersionBySchema

      public void getVersionBySchema(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative, javax.ws.rs.container.AsyncResponse response)
    • getVersionBySchemaAsync

      public CompletableFuture<Long> getVersionBySchemaAsync(org.apache.pulsar.common.protocol.schema.PostSchemaPayload payload, boolean authoritative)
    • domain

      protected String domain()
      Description copied from class: AdminResource
      Get the domain of the topic (whether it's persistent or non-persistent).
      Overrides:
      domain in class AdminResource
    • handleGetSchemaResponse

      protected static void handleGetSchemaResponse(javax.ws.rs.container.AsyncResponse response, SchemaRegistry.SchemaAndMetadata schema, Throwable error)
    • convertToSchemaResponse

      protected org.apache.pulsar.common.protocol.schema.GetSchemaResponse convertToSchemaResponse(SchemaRegistry.SchemaAndMetadata schema)
    • convertToAllVersionsSchemaResponse

      protected org.apache.pulsar.common.protocol.schema.GetAllVersionsSchemaResponse convertToAllVersionsSchemaResponse(List<SchemaRegistry.SchemaAndMetadata> schemas)
    • shouldPrintErrorLog

      protected boolean shouldPrintErrorLog(Throwable ex)