Exporting schemas using Schema Registry API

One of the methods of exporting schemas registered in Schema Registry into a JSON file is using the Schema Registry API. The file that you export can be used to import the exported schemas into a different Schema Registry. You can also export schemas using curl through the command line.

The following steps walk you through how you can export schemas by using the Schema Registry Swagger UI.

  • Ensure that the cluster, its hosts, and all its services are healthy.
  • Ensure that Schema Registry is commissioned and running.
  • Ensure that you have access to all credentials that are required to access and use Schema Registry.
  • If you are using the Swagger UI on a Kerberos enabled Schema Registry service, ensure that the browser you are using is configured to use Kerberos.
  • Ensure that you are logged in as a user with access to the CDP environment containing the cluster with Schema Registry.
  1. In Management Console, go to Data Hub clusters.
  2. Find and select the Data Hub cluster you want to export schemas from.
  3. Under Services, click Schema Registry.
    The Schema Registry web UI opens in a new tab.
  4. In the tab that has the Schema Registry web UI open, replace /ui/# at the end of the URL with /swagger.
  5. Select GET /api/v1/schemaregistry/schemas/aggregated.
  6. Click Try it out.
  7. Click Execute.
  8. Click Download found at the bottom right of the Response body pane to download the exported schemas.
All schemas stored in the Schema Registry server are exported to a JSON file.