The morphir-dapr project is a Morphir sub-project dedicated to enabling the Microsoft Dapr platform as a target for Morphir Application Models.
Morphir Application Modeling imagines development as:
- You code just pure business logic.
- That code is guaranteed to be free of exceptions.
- Merging your code triggers full SDLC automation through to deployment.
- Your application automatically conforms to firm standards now and in the future.
- Your users have transparency into how your application behaves and why.
- You retain full control to modify any of the above.
In general, the flow for application modeling is:
- Model your application with one of the languages supported by morphir (we've provided a few samples here and here.
- Invoke the morphir-dapr build to generate the Dapr application. This generates the following:
- DaprElmMain.elm - The elm model that captures the count business logic
- DaprElmMain.js - The output of
elm make DaprElmMain.elm --optimize --output=DaprElmMain.js
- app.js - Express app that interacts with Dapr side-car
- Dockerfile - Dockerfile that containerizes app.js
- [Note] - Usually we'd transpile from the Morphir IR to a Dapr-supported language like JavaScript. We took a shortcut since Elm already has a top-notch Elm-to-JavaScript compiler.
- Setup your SDLC pipeline to deploy.
A few important notes:
- This is a work-in-progress. Community participation will be key to making it production grade.
- While we used Elm in our examples, Bosque is another powerful application modeling language that we're excited about. Keep an eye out for more on this.