Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface Schema

Package version

Schema definition with its unique ID, version, and location. Interface representing a Schema.

Hierarchy

Index

Properties

content

content: string

String representation of schema.

id

id: string

ID that uniquely identifies a schema in the registry namespace.

location

location: string

URL of schema by group and name.

locationById

locationById: string

URL of schema by ID.

serializationType

serializationType: string

Serialization type of schema. Currently only 'avro' is supported, but this is subject to change.

version

version: number

Automatically incremented version number of the schema.

Methods

getById

queryIdByContent

  • Gets the ID referencing an existing schema within the specified schema group, as matched by schema content comparison.

    Parameters

    • groupName: string

      Schema group under which schema is registered. Group's serialization type should match the serialization type specified in the request.

    • schemaName: string

      Name of the registered schema.

    • serializationType: SerializationType

      Serialization type for the schema being registered.

    • schemaContent: string

      String representation (UTF-8) of the registered schema.

    • Optional options: SchemaQueryIdByContentOptionalParams

      The options parameters.

    Returns Promise<SchemaQueryIdByContentResponse>

register

  • Register new schema. If schema of specified name does not exist in specified group, schema is created at version 1. If schema of specified name exists already in specified group, schema is created at latest version + 1.

    Parameters

    • groupName: string

      Schema group under which schema should be registered. Group's serialization type should match the serialization type specified in the request.

    • schemaName: string

      Name of schema being registered.

    • serializationType: SerializationType

      Serialization type for the schema being registered.

    • schemaContent: string

      String representation (UTF-8) of the schema being registered.

    • Optional options: SchemaRegisterOptionalParams

      The options parameters.

    Returns Promise<SchemaRegisterResponse>

Generated using TypeDoc