Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/boyney123/cdk-schema-watcher
Allow your consumers to listen to schema changes with Amazon EventBridge
https://github.com/boyney123/cdk-schema-watcher
Last synced: about 2 months ago
JSON representation
Allow your consumers to listen to schema changes with Amazon EventBridge
- Host: GitHub
- URL: https://github.com/boyney123/cdk-schema-watcher
- Owner: boyney123
- Created: 2022-11-04T11:03:34.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2022-11-04T17:17:18.000Z (about 2 years ago)
- Last Synced: 2024-05-01T14:14:35.090Z (8 months ago)
- Language: JavaScript
- Homepage: cdk-schema-watcher.vercel.app
- Size: 13.4 MB
- Stars: 32
- Watchers: 6
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-eventbridge - EventBridge Schema Watcher - Simple CDK construct with plugin support that allows you to listen for schema changes on eventbridge. For example, send messages directly into Slack when schemas change, perfect for downstream consumers! (Tools)
README
🔍 EventBridge SchemaWatcher
EventBridge CDK construct that will notify your downstream consumers of schema changes (with plugin support).>
[![PRs Welcome][prs-badge]][prs]
[![Watch on GitHub][github-watch-badge]][github-watch]
[![Star on GitHub][github-star-badge]][github-star]
Features: Notify downstream consumers of schema changes with EventBridge, Plugin architecture, Setup in minutes...
[Read the Docs](https://cdk-schema-watcher.vercel.app/) | [Edit the Docs](https://github.com/boyney123/cdk-schema-watcher) | [View Example](#example-using-schemawatcher-cdk-construct-with-the-slack-plugin)
# Core Features
- 🔎 Consumers sign up to any changes to events
- 🔔 Get notified anywhere you want
- 📊 Plugin architecture
- ⭐ Setup in minutes**All powered by CDK**
# Why use SchemaWatcher?
SchemaWatcher is a CDK construct that can help you scale your event-driven architecture by allowing event consumers to subscribe to schema changes.
Amazon EventBridge is a serverless event bus that lets you receive, filter, transform, route, and deliver events, you can write custom event producers and listen to them downstream with custom rules and consumers.
Amazon EventBridge also offers a Schema Registry. EventBridge provides schemas for all events that are generated by AWS services and when you turn on schema discovery it will automatically detect and provide schemas for your custom events (OpenAPI and JSON Schemas).
When producers make changes to events or raise new events onto your EventBridge bus, EventBridge will automatically picks up these changes (with schema discovery turned on), and either make new schemas or update schemas for you.
Consumers can use these schemas to validate events, understand what is in the payload of events or even document their event-driven architecture using tools like EventCatalog.
As time goes on your event-driven architectures will grow, keeping on top of producer and consumer relationships can be hard, we are often told that “producers should not know about consumers”. Technically there is an element of truth to this, but you will often find this leads to some problems…
So, what if we could notify consumers of incoming breaking changes in our schema’s? Notifying consumers could help us manage our event-driven architectures and scale them as our organisations scale.
**SchemaWatcher was designed to help developers manage their event-driven architecture. Notifying consumers of any changes to event structures can help catch issues before you see them in production.**
[Read more on the website](https://cdk-schema-watcher.vercel.app/)
# Getting Started
You should be able to get setup within minutes if you head over to our documentation to get started 👇
➡️ [Get Started](https://cdk-schema-watcher.vercel.app/docs/installation)
Or run this command to install the cdk construct
```
npm i cdk-schema-watcher
```## Example using SchemaWatcher CDK construct with the Slack Plugin
Configure the construct with the Slack Plugin.
```js
import { SchemaWatcher } from 'cdk-schema-watcher';
import { SlackNotifier } from 'cdk-schema-watcher/plugins';new SchemaWatcher(this, 'MyTeam', {
type: 'All',
sources: ['myapp.users', 'myapp.orders'],
plugins: [
new SlackNotifier({
API_KEY: process.env.SLACK_API_KEY,
CHANNEL_ID: process.env.SLACK_CHANNEL_ID,
}),
],
});
```## Example outputs
New version of schema found.
![alt](./website/static/img/slack-example1.png)New event found
![alt](./website/static/img/slack-example2.png)# Contributing
If you have any questions, features or issues please raise any issue or pull requests you like. We will try my best to get back to you.
[license-badge]: https://img.shields.io/github/license/boyney123/cdk-schema-watcher.svg?color=yellow
[license]: https://github.com/boyney123/cdk-schema-watcher/blob/master/LICENCE
[prs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square
[prs]: http://makeapullrequest.com
[github-watch-badge]: https://img.shields.io/github/watchers/boyney123/cdk-schema-watcher.svg?style=social
[github-watch]: https://github.com/boyney123/cdk-schema-watcher/watchers
[github-star-badge]: https://img.shields.io/github/stars/boyney123/cdk-schema-watcher.svg?style=social
[github-star]: https://github.com/boyney123/cdk-schema-watcher/stargazers# License
MIT.