From: Steven Blimkie Date: Wed, 28 Mar 2018 14:14:51 +0000 (+0000) Subject: Merge "Catch IllegalArgumentException for error message" X-Git-Tag: v1.2.2~18 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=533b090aa92f5eaa6c674fd63940fcacf4dc811e;hp=-c;p=aai%2Fchamp.git Merge "Catch IllegalArgumentException for error message" --- 533b090aa92f5eaa6c674fd63940fcacf4dc811e diff --combined champ-lib/pom.xml index 921e733,5e441e0..43fa296 --- a/champ-lib/pom.xml +++ b/champ-lib/pom.xml @@@ -1,23 -1,3 +1,23 @@@ + 4.0.0 @@@ -27,12 -7,6 +27,12 @@@ pom 1.2.0-SNAPSHOT + + org.onap.aai + champ + 1.2.0-SNAPSHOT + + champ-core champ-titan @@@ -41,7 -15,7 +41,7 @@@ UTF-8 - 1.2.0 + 1.2.1 @@@ -55,21 -29,21 +55,21 @@@ - - org.onap.aai.event-client - event-client-api - ${event.client.version} - - - org.onap.aai.event-client - event-client-dmaap - ${event.client.version} - - - org.onap.aai.event-client - event-client-kafka - ${event.client.version} - + + org.onap.aai.event-client + event-client-api + ${event.client.version} + + + org.onap.aai.event-client + event-client-dmaap + ${event.client.version} + + + org.onap.aai.event-client + event-client-kafka + ${event.client.version} + @@@ -271,14 -245,6 +271,14 @@@ + + org.apache.maven.plugins + maven-deploy-plugin + + true + + + diff --combined champ-service/pom.xml index 2168783,c5c90f4..b0dbf46 --- a/champ-service/pom.xml +++ b/champ-service/pom.xml @@@ -1,23 -1,4 +1,23 @@@ - + @@@ -32,7 -13,6 +32,7 @@@ org.onap.aai champ-service 1.2.0-SNAPSHOT + champ ${basedir}/target/swm/package/nix/dist_files${distFilesRoot} @@@ -48,11 -28,8 +48,11 @@@ /appl/${project.artifactId}/${project.version} org.onap.aai.logging-service - 1.2.0 + 1.2.2 4.5.2 + + ${basedir}/target + https://nexus.onap.org @@@ -62,13 -39,13 +62,13 @@@ 1.18.6 - dom4j dom4j 1.6.1 provided + com.att.aft dme2 @@@ -76,6 -53,7 +76,6 @@@ provided - org.json json @@@ -124,6 -102,7 +124,6 @@@ ${org.apache.httpcomponents.httpclient.version} - org.onap.aai champ-core @@@ -138,19 -117,6 +138,19 @@@ + + + ecomp-releases + ECOMP Release Repository + ${onap.nexus.url}/content/repositories/releases/ + + + ecomp-snapshots + ECOMP Snapshot Repository + ${onap.nexus.url}/content/repositories/snapshots/ + + + ${project.artifactId} @@@ -179,25 -145,12 +179,25 @@@ ${basedir}/src/main/bin/ + + ../champ-service-deps-janus/target/ + + + ../champ-service-deps-titan/target/ + - + + org.apache.maven.plugins + maven-deploy-plugin + + true + + + com.spotify docker-maven-plugin @@@ -225,7 -178,7 +225,7 @@@ true docker-hub - ${docker.push.registry}/onap/${project.artifactId} + ${docker.push.registry}/onap/${project.name} ${docker.location} latest @@@ -233,6 -186,7 +233,6 @@@ true - org.jacoco jacoco-maven-plugin diff --combined champ-service/src/main/java/org/onap/champ/ChampRESTAPI.java index 08b602a,577dbc9..b75ba53 --- a/champ-service/src/main/java/org/onap/champ/ChampRESTAPI.java +++ b/champ-service/src/main/java/org/onap/champ/ChampRESTAPI.java @@@ -2,14 -2,14 +2,14 @@@ * ============LICENSE_START========================================== * org.onap.aai * =================================================================== - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. - * Copyright © 2017 Amdocs + * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017-2018 Amdocs * =================================================================== * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@@ -17,6 -17,7 +17,6 @@@ * See the License for the specific language governing permissions and * limitations under the License. * ============LICENSE_END============================================ - * ECOMP is a trademark and service mark of AT&T Intellectual Property. */ package org.onap.champ; @@@ -204,6 -205,8 +204,8 @@@ public class ChampRESTAPI response = Response.status(Status.BAD_REQUEST).entity("Unable to parse the payload").build(); } catch (ChampServiceException ce) { response = Response.status(ce.getHttpStatus()).entity(ce.getMessage()).build(); + } catch (IllegalArgumentException e) { + response = Response.status(Status.BAD_REQUEST).entity(e.getMessage()).build(); } catch (Exception e) { response = Response.status(Status.INTERNAL_SERVER_ERROR).entity(e.getMessage()).build(); LoggingUtil.logInternalError(logger, e); @@@ -242,6 -245,8 +244,8 @@@ response = Response.status(Status.BAD_REQUEST).entity("Unable to parse the payload").build(); } catch (ChampServiceException ce) { response = Response.status(ce.getHttpStatus()).entity(ce.getMessage()).build(); + } catch (IllegalArgumentException e) { + response = Response.status(Status.BAD_REQUEST).entity(e.getMessage()).build(); } catch (Exception e) { response = Response.status(Status.INTERNAL_SERVER_ERROR).entity(e.getMessage()).build(); LoggingUtil.logInternalError(logger, e); @@@ -386,6 -391,8 +390,8 @@@ response = Response.status(Status.BAD_REQUEST).entity("Unable to parse the payload").build(); } catch (ChampServiceException ce) { response = Response.status(ce.getHttpStatus()).entity(ce.getMessage()).build(); + } catch (IllegalArgumentException e) { + response = Response.status(Status.BAD_REQUEST).entity(e.getMessage()).build(); } catch (Exception e) { response = Response.status(Status.INTERNAL_SERVER_ERROR).entity(e.getMessage()).build(); LoggingUtil.logInternalError(logger, e); @@@ -422,6 -429,8 +428,8 @@@ response = Response.status(Status.BAD_REQUEST).entity("Unable to parse the payload").build(); } catch (ChampServiceException ce) { response = Response.status(ce.getHttpStatus()).entity(ce.getMessage()).build(); + } catch (IllegalArgumentException e) { + response = Response.status(Status.BAD_REQUEST).entity(e.getMessage()).build(); } catch (Exception e) { response = Response.status(Status.INTERNAL_SERVER_ERROR).entity(e.getMessage()).build(); LoggingUtil.logInternalError(logger, e);