Improved returned error messages

This commit is contained in:
Luca Frosini 2021-03-12 18:21:48 +01:00
parent 5ca0bbf023
commit d0eb17812b
3 changed files with 4 additions and 3 deletions

View File

@ -2,10 +2,11 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
# Changelog for gCube Catalogue (gCat) Service
## [v1.4.5]
## [v1.4.5-SNAPSHOT]
- Removed 'owner_org' field from result when reading an item #20919
- Dirty patched item validator [#20965]
- Improved error message return with message got from CKAN [#19516]
## [v1.4.4]

View File

@ -12,7 +12,7 @@
<groupId>org.gcube.data-publishing</groupId>
<artifactId>gcat</artifactId>
<packaging>war</packaging>
<version>1.4.5</version>
<version>1.4.5-SNAPSHOT</version>
<name>gCube Catalogue (gCat) Service</name>
<description>
This service allows any client to publish on the gCube Catalogue.

View File

@ -51,7 +51,7 @@ public class HTTPUtility {
InputStream inputStream = httpURLConnection.getErrorStream();
StringBuilder result = getStringBuilder(inputStream);
logger.trace(result.toString());
throw new WebApplicationException(status);
throw new WebApplicationException(result.toString(), status);
}
InputStream inputStream = httpURLConnection.getInputStream();
String ret = getStringBuilder(inputStream).toString();