├── .gitignore ├── .vscode ├── launch.json └── settings.json ├── CODE_OF_CONDUCT.md ├── LICENSE ├── README.md ├── images ├── architecture_fail.JPG ├── architecture_happy_path.JPG └── architecture_overview.JPG └── src └── order ├── .project ├── .settings └── org.eclipse.buildship.core.prefs ├── Dockerfile ├── build.gradle ├── common ├── .classpath ├── .project ├── .settings │ └── org.eclipse.buildship.core.prefs ├── build.gradle ├── build │ └── tmp │ │ └── jar │ │ └── MANIFEST.MF └── src │ └── main │ └── java │ └── example │ ├── commondomain │ ├── Money.java │ ├── OrderDetails.java │ ├── OrderState.java │ └── ResultWithEvents.java │ └── events │ ├── CustomerCreatedEvent.java │ ├── CustomerCreditReservationFailedEvent.java │ ├── CustomerCreditReservedEvent.java │ ├── DomainEvent.java │ ├── OrderApprovedEvent.java │ ├── OrderCreatedEvent.java │ └── OrderRejectedEvent.java ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── order-api ├── .classpath ├── .project ├── .settings │ └── org.eclipse.buildship.core.prefs ├── Dockerfile ├── build.gradle ├── build │ └── tmp │ │ └── bootJar │ │ └── MANIFEST.MF ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties └── src │ └── main │ └── java │ └── samples │ ├── Application.java │ ├── controllers │ └── OrderController.java │ └── models │ ├── config │ ├── OrderWebConfig.java │ └── SwaggerConfig.java │ └── order │ ├── CreateOrderRequest.java │ ├── CreateOrderResponse.java │ └── OrderConfiguration.java ├── order-service ├── .classpath ├── .project ├── .settings │ └── org.eclipse.buildship.core.prefs ├── build.gradle ├── build │ └── tmp │ │ └── jar │ │ └── MANIFEST.MF └── src │ └── main │ └── java │ └── samples │ ├── models │ └── OrderMock.java │ ├── repositories │ ├── CrudRepository.java │ └── OrderRepositoryMock.java │ └── services │ └── OrderServiceMock.java └── settings.gradle /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/.gitignore -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/.vscode/launch.json -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/.vscode/settings.json -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/CODE_OF_CONDUCT.md -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/README.md -------------------------------------------------------------------------------- /images/architecture_fail.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/images/architecture_fail.JPG -------------------------------------------------------------------------------- /images/architecture_happy_path.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/images/architecture_happy_path.JPG -------------------------------------------------------------------------------- /images/architecture_overview.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/images/architecture_overview.JPG -------------------------------------------------------------------------------- /src/order/.project: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/.project -------------------------------------------------------------------------------- /src/order/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/.settings/org.eclipse.buildship.core.prefs -------------------------------------------------------------------------------- /src/order/Dockerfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/Dockerfile -------------------------------------------------------------------------------- /src/order/build.gradle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/build.gradle -------------------------------------------------------------------------------- /src/order/common/.classpath: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/.classpath -------------------------------------------------------------------------------- /src/order/common/.project: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/.project -------------------------------------------------------------------------------- /src/order/common/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/.settings/org.eclipse.buildship.core.prefs -------------------------------------------------------------------------------- /src/order/common/build.gradle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/build.gradle -------------------------------------------------------------------------------- /src/order/common/build/tmp/jar/MANIFEST.MF: -------------------------------------------------------------------------------- 1 | Manifest-Version: 1.0 2 | 3 | -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/commondomain/Money.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/commondomain/Money.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/commondomain/OrderDetails.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/commondomain/OrderDetails.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/commondomain/OrderState.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/commondomain/OrderState.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/commondomain/ResultWithEvents.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/commondomain/ResultWithEvents.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/CustomerCreatedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/CustomerCreatedEvent.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/CustomerCreditReservationFailedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/CustomerCreditReservationFailedEvent.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/CustomerCreditReservedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/CustomerCreditReservedEvent.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/DomainEvent.java: -------------------------------------------------------------------------------- 1 | package example.events; 2 | 3 | public interface DomainEvent { 4 | } 5 | -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/OrderApprovedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/OrderApprovedEvent.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/OrderCreatedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/OrderCreatedEvent.java -------------------------------------------------------------------------------- /src/order/common/src/main/java/example/events/OrderRejectedEvent.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/common/src/main/java/example/events/OrderRejectedEvent.java -------------------------------------------------------------------------------- /src/order/gradle.properties: -------------------------------------------------------------------------------- 1 | springBootVersion=2.1.0.RELEASE 2 | -------------------------------------------------------------------------------- /src/order/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /src/order/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/gradle/wrapper/gradle-wrapper.properties -------------------------------------------------------------------------------- /src/order/gradlew: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/gradlew -------------------------------------------------------------------------------- /src/order/gradlew.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/gradlew.bat -------------------------------------------------------------------------------- /src/order/order-api/.classpath: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/.classpath -------------------------------------------------------------------------------- /src/order/order-api/.project: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/.project -------------------------------------------------------------------------------- /src/order/order-api/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/.settings/org.eclipse.buildship.core.prefs -------------------------------------------------------------------------------- /src/order/order-api/Dockerfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/Dockerfile -------------------------------------------------------------------------------- /src/order/order-api/build.gradle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/build.gradle -------------------------------------------------------------------------------- /src/order/order-api/build/tmp/bootJar/MANIFEST.MF: -------------------------------------------------------------------------------- 1 | Manifest-Version: 1.0 2 | 3 | -------------------------------------------------------------------------------- /src/order/order-api/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /src/order/order-api/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/gradle/wrapper/gradle-wrapper.properties -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/Application.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/Application.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/controllers/OrderController.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/controllers/OrderController.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/models/config/OrderWebConfig.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/models/config/OrderWebConfig.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/models/config/SwaggerConfig.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/models/config/SwaggerConfig.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/models/order/CreateOrderRequest.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/models/order/CreateOrderRequest.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/models/order/CreateOrderResponse.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/models/order/CreateOrderResponse.java -------------------------------------------------------------------------------- /src/order/order-api/src/main/java/samples/models/order/OrderConfiguration.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-api/src/main/java/samples/models/order/OrderConfiguration.java -------------------------------------------------------------------------------- /src/order/order-service/.classpath: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/.classpath -------------------------------------------------------------------------------- /src/order/order-service/.project: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/.project -------------------------------------------------------------------------------- /src/order/order-service/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/.settings/org.eclipse.buildship.core.prefs -------------------------------------------------------------------------------- /src/order/order-service/build.gradle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/build.gradle -------------------------------------------------------------------------------- /src/order/order-service/build/tmp/jar/MANIFEST.MF: -------------------------------------------------------------------------------- 1 | Manifest-Version: 1.0 2 | 3 | -------------------------------------------------------------------------------- /src/order/order-service/src/main/java/samples/models/OrderMock.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/src/main/java/samples/models/OrderMock.java -------------------------------------------------------------------------------- /src/order/order-service/src/main/java/samples/repositories/CrudRepository.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/src/main/java/samples/repositories/CrudRepository.java -------------------------------------------------------------------------------- /src/order/order-service/src/main/java/samples/repositories/OrderRepositoryMock.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/src/main/java/samples/repositories/OrderRepositoryMock.java -------------------------------------------------------------------------------- /src/order/order-service/src/main/java/samples/services/OrderServiceMock.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/order-service/src/main/java/samples/services/OrderServiceMock.java -------------------------------------------------------------------------------- /src/order/settings.gradle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fedeoliv/microservices-transactions/HEAD/src/order/settings.gradle --------------------------------------------------------------------------------