انتقل إلى المحتوى الرئيسي

Function: assertRegistered()

assertRegistered(subject): ResolvedContract

Defined in: packages/contracts/src/registry.ts:368

Asserts a subject is registered. A producer calls this for every subject it will publish, at start, and does not start if it throws (chapter 29: "every subject has a registered schema; a producer without one fails to start").

Parameters​

subject​

string

A concrete subject or a registry key.

Returns​

ResolvedContract

The registration.

Throws​

There is no schema for the subject.