Reviewing the steps
Let's quickly recap what are the step needed to create a new project using Gallifrey Rules.
-
Create a new Typescript/Node.Js application.
-
Include
gallifrey-rules
from npm.npm i gallifrey-rules
-
Create a folder under your project just for your
modules
. -
Create the entry point to your application and create the Gallifrey Rules Engine instance.
-
Prepare your Namespace Schema. You will need
- The path to your modules folder.
- Your list of consumers, with their event dispatcher providers.
- Decide on your entities/events and the rules that will run.
-
Initialize the engine with your schema and call
startConsumers()
. -
Dockerize your app, provide the proper environment variables needed to get your started. At the very least you will need a Kafka setup.
You can always check the sample app for more details.