Skip to content

Refactor component creation and retrieval logic; enhance error handli…#17

Merged
angelmp01 merged 10 commits intodevelopfrom
chore/component-api-error-handling
Apr 21, 2026
Merged

Refactor component creation and retrieval logic; enhance error handli…#17
angelmp01 merged 10 commits intodevelopfrom
chore/component-api-error-handling

Conversation

@angelmp01
Copy link
Copy Markdown
Contributor

…ng and response mapping

@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

@angelmp01 angelmp01 marked this pull request as ready for review April 20, 2026 07:35
@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

1 similar comment
@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

- DEV
- QA
- PROD
EnvironmentsStatusDTO:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not the status of the environment, it is the status of the Component / Project provisioning

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

type: string No newline at end of file
description: Additional parameters (key-value pairs)
additionalProperties: true
EnvironmentsTypeDTO:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check if it is needed for the new Markeplace 2.0

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

OK("000", "Success"),
ACCESS_DENIED("002", "Forbidden"),
INTERNAL_ERROR("003", "Internal error"),
INVALID_PARAMETERS("006", badRequest()),
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check how is done in the project api with ErrorKeys to use the number + message

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


return createComponentRequest.getParams().entrySet().stream()
.map(entry -> new CreateComponentParameter(entry.getKey(), "string", entry.getValue()))
.map(this::toCreateComponentParameter)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use the mapper

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

ONCE_PER_PROJECT("009", ErrorMessage.FORBIDDEN),
COMPONENT_PARAM_NOT_MEET_REGEX("010", ErrorMessage.BAD_REQUEST),
INVALID_LOCATION("011", ErrorMessage.BAD_REQUEST),
INVALID_LOCATION("011", "Incorrect location. Valid locations are:"),
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the message to the errormessage class

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Copy Markdown
Contributor

@jorge-romero jorge-romero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please review the comments.

@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

…o EnvironmentsDTO and EnvironmentsStatusDTO to ComponentsStatusDTO for consistency
@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

@angelmp01 angelmp01 requested a review from jorge-romero April 20, 2026 12:56
@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown

📊 Static Analysis Summary

🔍 Code Quality Checks

  • ✅ JaCoCo coverage report generated

📦 Download detailed reports from the workflow artifacts.

Copy link
Copy Markdown

@valituguran valituguran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@angelmp01 angelmp01 merged commit 60c5067 into develop Apr 21, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants