aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at
diff options
context:
space:
mode:
authorChristof Rabensteiner <christof.rabensteiner@iaik.tugraz.at>2019-06-19 13:35:14 +0200
committerChristof Rabensteiner <christof.rabensteiner@iaik.tugraz.at>2019-06-19 13:35:14 +0200
commit97aadc426ca2f61dccd58a05f37d065b2752ef6d (patch)
treeae53ae7bf447545ad23e2efcad8c9a1662ffd4cb /src/main/java/at
parent6044145569bdc0e86d2c1831fa50051227822864 (diff)
downloadmoa-zs-97aadc426ca2f61dccd58a05f37d065b2752ef6d.tar.gz
moa-zs-97aadc426ca2f61dccd58a05f37d065b2752ef6d.tar.bz2
moa-zs-97aadc426ca2f61dccd58a05f37d065b2752ef6d.zip
Unify AppDeliveryID Spelling
Diffstat (limited to 'src/main/java/at')
-rw-r--r--src/main/java/at/gv/egiz/moazs/msg/StoreSOAPBodyBinaryInRepositoryInterceptor.java6
-rw-r--r--src/main/java/at/gv/egiz/moazs/pipeline/SameThreadDeliveryPipeline.java8
-rw-r--r--src/main/java/at/gv/egiz/moazs/repository/RedisDeliveryRepository.java2
3 files changed, 8 insertions, 8 deletions
diff --git a/src/main/java/at/gv/egiz/moazs/msg/StoreSOAPBodyBinaryInRepositoryInterceptor.java b/src/main/java/at/gv/egiz/moazs/msg/StoreSOAPBodyBinaryInRepositoryInterceptor.java
index c78c44b..d007286 100644
--- a/src/main/java/at/gv/egiz/moazs/msg/StoreSOAPBodyBinaryInRepositoryInterceptor.java
+++ b/src/main/java/at/gv/egiz/moazs/msg/StoreSOAPBodyBinaryInRepositoryInterceptor.java
@@ -44,9 +44,9 @@ public class StoreSOAPBodyBinaryInRepositoryInterceptor extends AbstractPhaseInt
if(content.length > 0) {
Element document = soapUtils.toDOM(content);
byte[] status = soapUtils.unwrapSoapEnvelope(document);
- String appDeliveryId = soapUtils.getAppDeliveryIDFrom(document);
- repository.addSignedDeliveryRequestStatus(status, appDeliveryId);
- log.info("Store binary DeliveryRequestStatus with AppDeliveryId={}", appDeliveryId);
+ String appDeliveryID = soapUtils.getAppDeliveryIDFrom(document);
+ repository.addSignedDeliveryRequestStatus(status, appDeliveryID);
+ log.info("Store binary DeliveryRequestStatus with AppDeliveryID={}", appDeliveryID);
}
} catch (ParserConfigurationException | SAXException | IOException | NullPointerException e) {
throw moaZSExceptionBuilder("Could not extract signed data from message.")
diff --git a/src/main/java/at/gv/egiz/moazs/pipeline/SameThreadDeliveryPipeline.java b/src/main/java/at/gv/egiz/moazs/pipeline/SameThreadDeliveryPipeline.java
index f264e52..ae8286f 100644
--- a/src/main/java/at/gv/egiz/moazs/pipeline/SameThreadDeliveryPipeline.java
+++ b/src/main/java/at/gv/egiz/moazs/pipeline/SameThreadDeliveryPipeline.java
@@ -83,13 +83,13 @@ public class SameThreadDeliveryPipeline implements DeliveryPipeline {
var status = msgClientFactory.create(msgRequest, mzsRequest.getConfig(), interceptor).send();
exceptionBuilder.withMsgResult(status);
- verifyStatus(appDeliveryId, exceptionBuilder);
+ verifySignedStatus(appDeliveryId, exceptionBuilder);
repository.add(status);
} catch (MoaZSException exception) {
- log.error(format("An error occured while processing the DeliveryRequest with AppDeliveryID = %s. ",
+ log.error(format("An error occured while processing the DeliveryRequest with AppDeliveryID=%s. ",
appDeliveryId), exception);
var errorStatus = generateErrorStatus(exception, appDeliveryId);
@@ -97,13 +97,13 @@ public class SameThreadDeliveryPipeline implements DeliveryPipeline {
}
}
- private void verifyStatus(String appDeliveryId, MoaZSException.Builder exceptionBuilder) throws MoaZSException {
+ private void verifySignedStatus(String appDeliveryId, MoaZSException.Builder exceptionBuilder) throws MoaZSException {
try {
var signedStatus = repository.getSignedDeliveryRequestStatus(appDeliveryId).get();
verifier.verify(signedStatus);
} catch (Exception ex) {
- throw exceptionBuilder.withMessage(format("Signature of DeliveryRequestStatus with AppDeliveryId={} " +
+ throw exceptionBuilder.withMessage(format("Signature of DeliveryRequestStatus with AppDeliveryID=%s " +
" is not valid.", appDeliveryId))
.withErrorCode(MoaZSException.ERROR_MOASP_SIGNATURE_INVALID)
.withCause(ex)
diff --git a/src/main/java/at/gv/egiz/moazs/repository/RedisDeliveryRepository.java b/src/main/java/at/gv/egiz/moazs/repository/RedisDeliveryRepository.java
index 27b780f..9b7aefd 100644
--- a/src/main/java/at/gv/egiz/moazs/repository/RedisDeliveryRepository.java
+++ b/src/main/java/at/gv/egiz/moazs/repository/RedisDeliveryRepository.java
@@ -44,7 +44,7 @@ public class RedisDeliveryRepository implements DeliveryRepository {
var hashKey = request.getMetaData().getAppDeliveryID();
var serializedRequest = marshaller.marshallXml(factory.createDeliveryRequest(request));
- logger.info("Save DeliveryRequest with AppDeliveryId = {} to redis.", hashKey);
+ logger.info("Save DeliveryRequest with AppDeliveryID={} to redis.", hashKey);
hashOperations.put(KEY, hashKey, serializedRequest);
}