Add testcontainer configuration fixes for task #12#31
Open
DmitriyChernyakSetronica wants to merge 34 commits intomainfrom
Open
Add testcontainer configuration fixes for task #12#31DmitriyChernyakSetronica wants to merge 34 commits intomainfrom
DmitriyChernyakSetronica wants to merge 34 commits intomainfrom
Conversation
… write tests to validate API
…er is a non-negative integer Declare a RestControllerAdvice class to handle API exceptions and return proper responses. Write tests to check the validation
- Create ServiceUtil for service discovery - Implement ProductCompositeIntegration and update ProductCompositeService with aggregated responses - Update tests to check updated behavior
…them all together
- Configure JPA with MySQL for persistence - Add `ReviewEntity` and `ReviewRepository` for database operations - Declare and implement CRUD operations for the 'ReviewService' API endpoint - Configure MySQL in 'docker-compose.yml' - Update application properties for local and Docker profiles - Add integration tests with Testcontainers for API and persistence layer
- Add `spring-boot-starter-validation` dependency to enable bean validation - Annotate fields in `ReviewEntity` with validation constraints - Introduce `ReviewValidationTests` to validate `ReviewEntity` constraints
- Add Flyway dependencies to manage DB schema migrations - Add 'V1__' migration script to create 'reviews' table with constraints - Add `ReviewDbMigrationTest` to validate Flyway migrations
- Extend `ReviewEntity` with a non-null `date` field - Update database schema with Flyway migration 'V2__' - Modify API contract and record `Review` to include `date` - Adjust validation rules and tests for new field - Add `LocalDateConverter` for proper `LocalDate` serialization/deserialization
…ayer - Configure MongoDB Docker container - Update `docker-compose.yml` to include a MongoDB service with health checks - Add CRUD operations for recommendation - Write integration tests with Testcontainers
- Add 'spring-boot-starter-validation' dependency to enable bean validation - Introduce 'MongoDbValidationConfig' to integrate validation with MongoDB - Update 'RecommendationEntity' with validation annotations for fields - Modify tests to include validation scenarios - Add 'RecommendationValidationTests' to validate entity constraints
… layer - Configure PostgreSQL in 'docker-compose.yml' and application configurations - Add 'ProductEntity' and 'ProductRepository' for database operations - Implement CRUD operations in 'ProductServiceImpl' - Add API endpoints for product CRUD operations - Write test cases using Testcontainers for persistence and API integration
…ize schema - Add Liquibase dependency and initial changelog with 'products' table creation - Update application configuration to use Liquibase for schema management - Replace SQL-based initialization with Liquibase - Add 'ProductMigrationTest' to verify Liquibase migrations with Testcontainers
…delete composite products - Implement CRUD operations for composite products in `ProductCompositeService` - Add new endpoints with OpenAPI documentation: POST, DELETE for composite products - Enhance service layer with integration methods and logging - Refactor product, recommendations, and reviews retrieval logic - Update tests with comprehensive cases for new operations
- Remove `MappingUtils` and its usages - Introduce `ReviewMapper` interface using MapStruct for mapping logic - Add MapStruct dependency and configuration in `build.gradle` - Update `ReviewServiceImpl` to use `ReviewMapper` for mapping operations - Add `ReviewMapperTest` to verify mapping functionality
- Remove `MappingUtils` and its usages - Introduce `RecommendationMapper` interface using MapStruct for mapping logic - Add MapStruct dependency and configuration in `build.gradle` - Update `RecommendationServiceImpl` to use `RecommendationMapper` for mapping operations - Add `RecommendationMapperTest` to verify mapping functionality
- Remove `MapperUtils` and its usages - Introduce `ProductMapper` interface using MapStruct for mapping logic - Add MapStruct dependency and configuration in `build.gradle` - Update `ProductServiceImpl` to use `ProductMapper` for mapping operations - Add `ProductMapperTest` to verify mapping functionality
- Replace synchronous RestTemplate with WebClient across microservices - Refactor repositories to use reactive CRUD operations - Update service implementations and test cases accordingly - Transition from traditional MVC to WebFlux stack for all APIs and testing frameworks - Remove unused synchronous methods, libraries, and dependencies
- Add messaging support across microservices using Spring Cloud Stream with RabbitMQ - Replace HTTP-based communication with event-driven messaging for create and delete operations - Add event models and processing logic in `api` module - Update `ProductCompositeIntegration` to publish and consume events - Refactor tests and add message-driven test cases for all event-processing scenarios - Integrate Health Checks for underlying services using Actuator
…tion - Add Eureka Server module with Spring Cloud Netflix Eureka - Integrate Eureka client in all microservices for service discovery - Replace hardcoded service URLs with dynamic resolution through Eureka - Update WebClient configuration to support load balancing with Eureka - Refactor configuration files to include Eureka settings - Modify Docker Compose to include Eureka Server - Enhance logging and error handling in `ProductCompositeIntegration` for service calls - Add tests for Eureka Server and client integration
- Introduce 'NotFoundException' - Update 'ProductServiceImpl' to throw 'NotFoundException' when no product is found - Modify 'ProductCompositeIntegration' logic to handle `NotFoundException` from downstream services - Add 'GlobalControllerExceptionHandler' to process `NotFoundException` responses with proper HTTP status
…management-20250726184713 Add workflow: pr-label-management.yml
…250726184418 Add workflow: gradle.yml
- Adjust the DTO and the entity to handle the new field - Add validation for the new field and update tests - Generate Flyway update scripts - Update test cases across all services to include and validate the new field
- Update API contracts to define the new '/product-composite/reviews/{productId}' endpoint
- Update OpenAPI documentation to describe the new endpoint
- Include test cases to validate reviews retrieval logic
… associated recommendations and reviews - Update API contracts to define the new '/product-composite' endpoint - Implement service method in 'ProductCompositeService' to aggregate product details - Update 'ProductCompositeIntegration' to call downstream 'ProductService' for all products - Extend 'ProductService' with a new method and corresponding implementation in 'ProductServiceImpl' - Add test cases to verify 'getAllProducts' functionality end-to-end
- Introduce constraints for the 'productId,' 'name,' and 'weight' fields - Update 'ProductServiceImpl' to validate Product entity during save - Add test cases to verify validation logic in 'ProductValidationTests' - Enhance API tests to cover invalid Product save scenarios
Product Service: Introduce PostgreSQL integration and persistence layer #12 - Configure PostgreSQL in 'docker-compose.yml' and application configurations - Add 'ProductEntity' and 'ProductRepository' for database operations - Implement CRUD operations in 'ProductServiceImpl' - Add API endpoints for product CRUD operations - Write test cases using Testcontainers for persistence and API integration FAIL_TO_PASS: shop.microservices.core.product.PersistenceTests, shop.microservices.core.product.ProductServiceApiTests
8cab292 to
fd3c4b7
Compare
Author
|
green validation result https://github.com/dpai-benchmark/infrastructure/actions/runs/18779466599 |
b421067 to
fd3c4b7
Compare
c8fd93f to
d6f4f80
Compare
bd00aca to
a04bfd8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The original task description below contains a logical typo means reviews instead of product:
This leads to distorted information about the analysis results.
We don't need to touch the review service and anything related to it.
so task description should be:
Add testcontainer configuration fixes for
Product Service: Introduce PostgreSQL integration and persistence layer #12
FAIL_TO_PASS: shop.microservices.core.product.PersistenceTests, shop.microservices.core.product.ProductServiceApiTests