Apply Best Practices for Code Implementation
In this document you can find some best practice code samples that might be helpful while writing code for Java domain service projects.
In this document you can find some best practice code samples that might be helpful while writing code for Java domain service projects.
You want to consume an Event from a Service that has already been published so that you can implement logic that is executed when the Event is triggered.
I have a Domain Service project with Event publishing inside and I want to debug e.g. the event-publishing Command. How can I debug my Command and see whether my Event was published correctly?
When working with Domain services mapping between api namespace and domain namespace is often needed, for example :
When working with Domain services, mapping between api namespace and domain namespace is often needed, for example :
You already have an existing Java Domain service, you want to include unit testing for that service.
You want to write unit tests without having access to all of the infrastructure which can be achieved by mocking which is described here in this How-To.
You want to disable security checks for REST endpoints or even the entire service in your project for a specific reason.
You have designed API operations with more than just one resoponse to cover both the success and error case. In your implementation code you want to return a specific response body if an error happens.
Set up a WebSocket server in your Domain Java service using Java Stack 2.0 to enable real-time bidirectional communication.
You have implemented changes in your Service and want to release them so that the new version could be used in an Application.
Use Case for the Training Courses
In this course you will learn how to set up your domain service project for the implementation on your local machine using the Solution CLI.
In this course you will learn how to implement Factory and Instance Commands of a root entity using your local IDE.
In this course you will learn how to implement a service within the domain namespace using your local IDE.
In this course you will learn how to implement an agent within the domain namespace using your local IDE.
In this course you will learn how to implement services in integration namespaces and how to call the Rest API of another microservice using your local IDE.
In this course you will learn how to implement API operations in the using your local machine.
In this course you will learn how to use the built-in pipeline functionality of the to build and deploy your Domain Service project using the .
In this course you will learn about the different types of entities within a domain namespace. You will also practice how to design entites with their properties using the .
In this course you will learn about the different types of commands within a domain namespace. You will also practice how to design commands with their input, business events and business errors using the .
In this course you will learn about the basics of API namespaces and how to create one.
In this course you will learn about API Schemas and how they can be reused in an API namespace.
In this course you will learn about paths and operations within an API namespace. You will also practice how to design them using the .
You have a Domain Service Java project and want to do local debugging.
You want to create robust data models that reflect the structure of relational databases using the .
An External Entity is considered a proxy of an entity that is managed by another microservice. Normally, the external entity contains only the most important data that is regularly needed in the context of the aggregate to which the external entity belongs. Because of these specifics, it is handled differently than a usual Entity.
Your have a service that only offers async communication, but you need to call it synchronously.
You want to design transaction-like behaviour using the SAGA pattern support in your Java Domain Service based project.
Goal: Enable and configure distributed tracing for REST calls, MongoDB operations, and Kafka events in Java stack 2.0 applications using OpenTelemetry with Jaeger.