Merged
Conversation
Moved channel mappers to an 'impl' subpackage and updated imports accordingly. Introduced ChannelMapper and updated ProjectMapper method naming. Added TaskStatus domain model improvements, TaskStatusService, and related API/controller classes. Enhanced Task and Channel service layers with get/getOrThrow methods. Updated TaskCreateRequest and TaskCreateResponse to include relevant fields.
Introduces TaskMapper and TaskCreateMapper interfaces for mapping between domain and API models using MapStruct. Adds TaskResponseContent DTO and TaskResponseContentMapping annotation to standardize task response mapping.
Introduced a new POST endpoint at /channels/{channelId}/tasks to create a task within a specific channel. Added OpenAPI documentation, organization header, and integrated TaskCreateMapper and TaskCreateUseCase for request handling and response mapping. The endpoint now returns a 201 status with a success message upon task creation.
Introduced TaskPatchMapper and TaskFetchMapper for mapping patch and fetch operations. Updated TaskController to support PATCH and GET endpoints for tasks, including request/response models. Refactored TaskCreateRequest and TaskPatchRequest to use Lombok annotations for consistency. Also added @DisplayPatchOperations annotation to relevant endpoints for better documentation.
Introduces endpoints and mappers for batch fetching tasks and retrieving tasks by channel. Refactors task batch fetch classes and response/request objects to use consistent pluralized naming. Adds delete task endpoint and related use case wiring. Minor improvements to channel controller and response classes.
Implemented TaskStatusController with endpoints for fetching single and multiple task statuses. Added request and response models for batch fetch, and refactored TaskStatusContent to TaskStatusResponseContent. Updated ChannelMapper and TasksBatchFetchResponse for improved type consistency.
Updated task request and response DTOs to use Instant for timestamps and UUID for statusId, replacing previous Long and String types. Adjusted related mapping annotations, command objects, and use cases to align with the new field types and naming conventions. Also updated test method names and usages to reflect changes in the mapper interface.
Improved OpenAPI documentation for patch endpoints by adding descriptions and @DisplayPatchOperations annotations. Changed batch-fetch for tasks to POST. Added @tag annotations for Task and TaskStatus controllers. Registered TaskPatchUseCase as a Spring service. Updated Maven POM files to use a static 'dev-local-version' instead of timestamp-based versioning.
Collaborator
Author
|
Dzisiaj to mnie całkowicie z kapci wywaliło... Tak błądziłem po tym DVD, że szkoda gadać, totalnie wyczerpany kognitywnie XD |
NikodemCyrzan
approved these changes
Dec 27, 2025
scraft-official
added a commit
that referenced
this pull request
Jan 4, 2026
* Refactor mappers and add task status support
Moved channel mappers to an 'impl' subpackage and updated imports accordingly. Introduced ChannelMapper and updated ProjectMapper method naming. Added TaskStatus domain model improvements, TaskStatusService, and related API/controller classes. Enhanced Task and Channel service layers with get/getOrThrow methods. Updated TaskCreateRequest and TaskCreateResponse to include relevant fields.
* Add task mapping and response content classes
Introduces TaskMapper and TaskCreateMapper interfaces for mapping between domain and API models using MapStruct. Adds TaskResponseContent DTO and TaskResponseContentMapping annotation to standardize task response mapping.
* Add endpoint to create task in specific channel
Introduced a new POST endpoint at /channels/{channelId}/tasks to create a task within a specific channel. Added OpenAPI documentation, organization header, and integrated TaskCreateMapper and TaskCreateUseCase for request handling and response mapping. The endpoint now returns a 201 status with a success message upon task creation.
* Add patch and fetch endpoints for tasks
Introduced TaskPatchMapper and TaskFetchMapper for mapping patch and fetch operations. Updated TaskController to support PATCH and GET endpoints for tasks, including request/response models. Refactored TaskCreateRequest and TaskPatchRequest to use Lombok annotations for consistency. Also added @DisplayPatchOperations annotation to relevant endpoints for better documentation.
* Add batch fetch and channel task endpoints, refactor naming
Introduces endpoints and mappers for batch fetching tasks and retrieving tasks by channel. Refactors task batch fetch classes and response/request objects to use consistent pluralized naming. Adds delete task endpoint and related use case wiring. Minor improvements to channel controller and response classes.
* Add task status batch fetch API and related models
Implemented TaskStatusController with endpoints for fetching single and multiple task statuses. Added request and response models for batch fetch, and refactored TaskStatusContent to TaskStatusResponseContent. Updated ChannelMapper and TasksBatchFetchResponse for improved type consistency.
* Refactor task timestamp and status fields to use Instant and UUID
Updated task request and response DTOs to use Instant for timestamps and UUID for statusId, replacing previous Long and String types. Adjusted related mapping annotations, command objects, and use cases to align with the new field types and naming conventions. Also updated test method names and usages to reflect changes in the mapper interface.
* Enhance API docs and update Maven versioning
Improved OpenAPI documentation for patch endpoints by adding descriptions and @DisplayPatchOperations annotations. Changed batch-fetch for tasks to POST. Added @tag annotations for Task and TaskStatus controllers. Registered TaskPatchUseCase as a Spring service. Updated Maven POM files to use a static 'dev-local-version' instead of timestamp-based versioning.
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.
This pull request introduces several improvements and refactorings to the channel and organization controller layers, focusing on code organization, response models, and API documentation. The changes streamline the structure of mappers, enhance API documentation for PATCH operations, and update response models for better clarity and maintainability.
Key changes include:
Refactoring and Organization of Mapper Classes
ChannelCreateMapper,ChannelFetchMapper,ChannelPatchMapper,ChannelsBatchFetchMapper,ChannelsInProjectMapper) have been moved from themapperpackage to a newmapper.implpackage, and their imports have been updated accordingly. This improves code organization and aligns with best practices for separating interface definitions and implementations. [1] [2] [3] [4] [5] [6]ChannelMapperinterface has been introduced to mapChanneldomain objects toChannelResponseContent, leveraging MapStruct for mapping logic.ProjectMapperhas been standardized fromtoResponseContenttomapfor consistency.API Documentation and PATCH Operation Improvements
@DisplayPatchOperationsannotation has been added to PATCH endpoints in bothChannelControllerandOrganizationController, referencing their respective operation enums. This enhances API documentation by clearly listing supported PATCH operations in generated OpenAPI specs. [1] [2] [3] [4] [5]Response Model Updates
ChannelCreateResponsenow extendsBaseResponseand includes achannelIdfield, removing status/message properties and inheritance fromChannelResponseContentfor a clearer, more focused response model.ChannelsListResponsenow includes a@Getterannotation for easier property access.Minor API and Dependency Updates
getChannelstogetChannelsInProjectfor improved clarity.pom.xmlhas been changed from a timestamp-based version to a staticdev-local-versionfor local development consistency.