Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed malformed error message for MappingException log #3835

Merged
merged 1 commit into from
Aug 1, 2023

Conversation

MDeLuise
Copy link
Contributor

@MDeLuise MDeLuise commented Aug 1, 2023

Brief description of the PR
This PR fix the malformed log while throwing a MappingException.
Considering the log of the following code: throw new InvalidValueMappingException(new Exception("exception message"), "nameArgs", "valueArgs", Date.class)
Before the PR:

Exception in thread "main" org.eclipse.kapua.service.storable.exception.MappingException: The value of mapping arg1 of value arg2 is not compatible with type {2}

After the PR:

The value of mapping nameArgs of value valueArgs is not compatible with type class java.util.Date.

Related Issue
This PR fixes #3834.

Additional notes
In a future PR it should be investigated the following code, since it could still cause the malformed error message log.
https://github.com/eclipse/kapua/blob/055c84b6963e2fe3291b0e9a2643441a5a394052/service/commons/storable/api/src/main/java/org/eclipse/kapua/service/storable/model/utils/MappingUtils.java#L62-L97

@codecov
Copy link

codecov bot commented Aug 1, 2023

Codecov Report

Merging #3835 (71d3790) into develop (9cbe18c) will not change coverage.
Report is 6 commits behind head on develop.
The diff coverage is 0.00%.

❗ Current head 71d3790 differs from pull request most recent head 969a6be. Consider uploading reports for the commit 969a6be to get more accurate results

Impacted file tree graph

@@            Coverage Diff             @@
##             develop    #3835   +/-   ##
==========================================
  Coverage      20.56%   20.56%           
  Complexity         6        6           
==========================================
  Files           1896     1896           
  Lines          40498    40498           
  Branches        3878     3878           
==========================================
  Hits            8327     8327           
  Misses         31759    31759           
  Partials         412      412           
Files Changed Coverage Δ
...resources/v1/resources/DeviceManagementAssets.java 0.00% <ø> (ø)
...s/v1/resources/DeviceManagementConfigurations.java 0.00% <ø> (ø)
...orable/exception/InvalidValueMappingException.java 0.00% <0.00%> (ø)

@Coduz Coduz merged commit be176a2 into eclipse-kapua:develop Aug 1, 2023
@MDeLuise MDeLuise deleted the fix/mapping-exception-msg branch August 1, 2023 13:20
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.

MappingException malformed error message in log
2 participants