Documentation ¶
Index ¶
- Constants
- func CreateFile(content []byte, name string, path string) (string, error)
- func RemoveFile(path string) error
- type Client
- func (c *Client) SchemaCreate(subject string, schema string, schemaType string, environment string) (string, error)
- func (c *Client) SchemaDelete(subject string, version string, permanent bool, environment string) (string, error)
- func (c *Client) SchemaDescribe(subject string, version string, environment string) (SchemaDescribeResponse, error)
- func (c *Client) SchemaSubjectUpdateCommand(subject string, compatibility string, environment string) (string, error)
- type Config
- type IClient
- type SchemaDescribeResponse
Constants ¶
View Source
const ( ErrNotFound = "schema not found" ErrNotCompatible = "schema not compatible" ErrInvalidCompatibility = "invalid compatibility level" )
Errors for schemaregistry
Variables ¶
This section is empty.
Functions ¶
func CreateFile ¶
CreateFile creates a file at a given location with the supplied content
Types ¶
type Client ¶
type Client struct {
Config Config
}
Client is a struct for schemaregistry client
func (*Client) SchemaCreate ¶
func (c *Client) SchemaCreate(subject string, schema string, schemaType string, environment string) (string, error)
SchemaCreate creates a schema in the schemaregistry
func (*Client) SchemaDelete ¶
func (c *Client) SchemaDelete(subject string, version string, permanent bool, environment string) (string, error)
SchemaDelete deletes a schema in the schemaregistry
func (*Client) SchemaDescribe ¶
func (c *Client) SchemaDescribe(subject string, version string, environment string) (SchemaDescribeResponse, error)
SchemaDescribe gets a schema in the schemaregistry
type Config ¶
type Config struct { APICredentials clients.APICredentials SchemaPath string }
Config is a configuration element for the schema registry client
type IClient ¶
type IClient interface { SchemaCreate(subject string, schema string, schemaType string, environment string) (string, error) SchemaDelete(subject string, version string, permanent bool, environment string) (string, error) SchemaDescribe(subject string, version string, environment string) (SchemaDescribeResponse, error) SchemaSubjectUpdateCommand(subject string, compatibility string, environment string) (string, error) }
IClient interface for schemaregistry client
type SchemaDescribeResponse ¶
type SchemaDescribeResponse struct { Type string `json:"type"` Name string `json:"name"` Namespace string `json:"namespace"` Doc string `json:"doc"` Fields []struct { Name string `json:"name"` Type string `json:"type"` Doc string `json:"doc"` } `json:"fields"` }
SchemaDescribeResponse is a struct for a response from the schemaregistry in confluent cloud
Click to show internal directories.
Click to hide internal directories.