Schemas

Introduction

IBM Industry Solutions Workbench offers the possibility to define schemas, which will be stored in a central Schema Registry. Those schemas will be used to describe the payload structure of events published on your message broker. When modelling events in a Domain Service Project, one of the shared schemas in the registry can be chosen and assigned to the event easily. This way you can ensure that the payload is handled correctly while producing and consuming events even across multiple services.

About the Schema Registry

When using events in your services, a Schema Registry is helpful to ensure governance while dealing with the event payloads. It is a shared repository which holds the definitions of the possible payload structures, which are used and therefore help to define a reliable contract between event producers and consumers. Additionally, the schema registry gives the possibility to create new versions of a schema, so that it can evolve over time while ensuring compatiblity with older versions.

Currently, IBM Industry Solutions Workbench supports

  • Apicurio as Schema Registry
  • schemas in the format of JSON Schema 2019-09

Modelling Schemas in Solution Designer

The Solution Designer of IBM Industry Solutions Workbench is connected to a Schema Registry and provides multiple capabilities to model new schemas and create new versions of existing schemas. To find out more about modelling schemas in IBM Industry Solutions Workbench, please see Modelling Schemas.

Use Schemas within events in Domain Service Projects

Within Domain Service Projects, schemas are used as event payloads. To learn more about this, please check Define event payload

Configure your k5-project to use Schema Registry

To find out more about configuring your k5-project please check the article about k5-project configuration.

Migrate Events prior to 4.0.5 version

For events created prior to the 4.0.5 version of IBM Industry Solutions Workbench, entities where used to describe the payload of events. To learn how to migrate those events to use schemas from the Schema Registry, please checkout Upgrading from 4.0.x to 4.0.5.