asyncapi-3-channel-servers
asyncapi-3-channel-servers checks that channel servers entries point to named root-level servers. Channels should not point at missing servers or component server definitions.
Why did this violation appear?
A channel server reference points somewhere other than #/servers/<name> or names a root server that does not exist.
Bad example
asyncapi: 3.1.0
servers:
production:
host: events.example.com
protocol: mqtt
channels:
userEvents:
address: users
servers:
- $ref: '#/components/servers/production'
Good example
asyncapi: 3.1.0
servers:
production:
host: events.example.com
protocol: mqtt
channels:
userEvents:
address: users
servers:
- $ref: '#/servers/production'
How do I fix this violation?
Reference root servers with #/servers/<serverName> and make sure each named server exists.
