DMN™ Basic Deployment Options in Aletyx Enterprise Build of Kogito and Drools 10.0.0¶
Introduction¶
After creating your DMN model and applying an accelerator to structure your project, the next step is deployment. This guide covers the basics of deploying your decision service to make it accessible to other applications and services in your ecosystem.
We'll focus on the development deployment capabilities of Aletyx Studio to get you started quickly. For production deployments, see our Advanced Deployment Options guide.
Understanding Deployment Concepts¶
Before diving into deployment, let's understand some key concepts:
What is a Decision Service?¶
A decision service is an API-enabled service that:
- Exposes your DMN models as REST endpoints
- Accepts input data in JSON format
- Evaluates decisions based on your models
- Returns results in JSON format
Development vs. Production Deployment¶
It's important to distinguish between:
- Development Deployment: For testing and validation during development
- Production Deployment: For use in actual business operations
This guide focuses on development deployments through Aletyx Studio, which are perfect for initial testing but not intended for production use.
Preparing for Deployment¶
Before deploying, ensure:
- Your DMN model is properly structured and validated
- You've applied the appropriate accelerator
- Your project is synchronized with Git (if you want to preserve changes)
Using Dev Deployments in Aletyx Studio¶
Aletyx Studio provides a simple way to deploy your decision service for development and testing purposes:
Creating a Development Deployment¶
-
In Aletyx Studio with your project open, click the Deploy button in the toolbar
-
If prompted, select the folder containing your project (usually "Untitled Folder" if this is your first deployment)
-
A dialog will appear explaining that this deployment is for development purposes only
- Review the information
- Click Confirm to proceed
-
The deployment process will begin. This typically takes 1-2 minutes for the first deployment as the system pulls the necessary container images
-
You can monitor the progress in the deployment dialog
Accessing Your Deployed Service¶
Once deployment completes:
-
Click the Dev Deployments button in the toolbar
-
You'll see a list of your deployments with their status
- A green checkmark indicates a successful deployment
- Click Refresh if you don't see an updated status
-
Click on the deployment link to access the Swagger UI for your service
-
The Swagger UI provides:
- Documentation of your service's REST API
- The ability to test your endpoints directly in the browser
- Details of the request/response formats
Testing Your Deployed Service¶
To test your deployment using the Swagger UI:
- Locate the POST endpoint for your DMN model
-
It should be named after your model, e.g.,
/vacation-days
-
Click on the endpoint to expand it
-
Click Try it out
-
In the Request Body field, enter a JSON object with your input values:
-
Click Execute
-
Review the response, which should contain all the decisions in your model:
This confirms that your decision service is working correctly!
Understanding the Deployment Architecture¶
The development deployment created by Aletyx Studio has these characteristics:
- Containerized: Packaged as a container
- Isolated: Each deployment runs independently
- Temporary: Not intended for long-term use
- Stateless: Each decision request is processed independently
- REST API: Accessible via HTTP endpoints
Deployment Limitations¶
Be aware of these limitations of Dev Deployments:
- Not for Production: Dev Deployments are for testing only
- Limited Scalability: Cannot be horizontally scaled
- No Health Monitoring: Limited production-ready features
- Isolated Models: Multiple interdependent models may not work as expected
- Temporary: No guaranteed uptime or persistence
Connecting to OpenShift (Optional)¶
For more advanced testing, you can deploy to an Red Hat OpenShift® environment:
-
Click Dev Deployments and select Connect to an account
-
Select the OpenShift tile
-
Complete the connection form with:
- Your namespace
- The OpenShift API URL
- Your authentication token
- Check "Insecurely disable TLS validation" if needed
-
Click Connect
-
After successful connection, click Continue
-
Follow the same deployment steps as before
This deployment will still be for development purposes but will run in your OpenShift environment.
Next Steps After Deployment¶
Once your service is deployed and tested:
- Integration Testing: Test with other applications and services
- Performance Testing: Validate response times and throughput
- Documentation: Create API documentation for consumers
- Feedback Loop: Gather feedback and refine your model
- Production Planning: Prepare for production deployment
Transitioning to Production¶
When you're ready to move to production:
- Follow the Advanced Deployment Options guide
- Implement proper CI/CD pipelines
- Set up monitoring and observability
- Configure appropriate security measures
- Plan for scaling and availability
Troubleshooting Common Deployment Issues¶
If you encounter issues with your deployment:
-
Deployment Fails to Start:
- Check for errors in the deployment logs
- Verify the model name matches the file name
- Ensure your DMN model is valid
-
Incorrect Results:
- Validate your model in the Aletyx Studio testing environment
- Check your input data format
- Review the decision logic for errors
-
Service Unavailable:
- Refresh the deployment status
- Try redeploying the service
- Check your network connection
Conclusion¶
You've now successfully deployed your DMN model as a decision service! This development deployment allows you to test and validate your decision logic in a real service environment.
Remember that this is just the beginning of your deployment journey. For production use, you'll need to implement more robust deployment patterns as covered in the Advanced Deployment Options guide.
In the next section, we'll explore advanced DMN modeling techniques to help you create more sophisticated decision models.