Age | Commit message (Collapse) | Author | Files | Lines |
|
- Refactor MsgClient: Not a Singleton anymore. Use MsgClientFactory to
make a client. Make request and config private fields.
- Add configuration parameters to application.yaml.
- Init SSL client auth testcase, but dont include in testsuite because
it aint working yet.
|
|
|
|
- Reason: All three classes opertate with the same data type, have
the same clients, and have the same reasons for change.
- Makes code in client more readable as it reduces number of
dependencies.
|
|
Refactor
- Add Builder to ConfigProfileGenerator. Reason: Constructor had too
many arguments.
- Move Conversion from Map to Config from ConfigProfileGenerator into
dedicated 'ConvertMapToConfig' Class; Reason: I expect additional
configuration properties and I don't want those changes to affect
the ConfigProfileGenerator (or it's test cases)
- Move Access to Spring's env into facade to simplify ConfigProfileGenerator.
|
|
|
|
ConfigProfileGenerator:
- Cancel startup if default Config profile is incomplete.
- Add property flag
'verify-completeness-of-default-delivery-request-configuration',
which allows admin to disable completeness check. In that case, just
log a warning if the default profile is incomplete.
Augmenter:
- Ensure that after merging the config is complete (or throw an
exception otherwise).
- Refactor: Move ConfigProfileValidator from ConfigProfileGenerator to
dedicated "ConfigProfileValidator" class; Reason: Augmenter needs to
check completness of at-runtime-compiled configuration.
- Refactor: Rewrote code for better readability.
Others
- NPE Fix in ConfigProfileMerger: If FallbackConfigProfile/Server is
empty, use PrimaryProfile/Server.
|
|
Config Profile Integration:
- Merge generated Configs from ConfigProfileGenerator with the default
Config; Reason: Merging profile Configs with default Config asap
ensures that profile Configs are "as complete as possible" while
allowing profile Configs to "on-demand"-override values from the
default Config.
- Adapt Augmenter to work with Config profiles: Select a Config on the
basis of on msg:DeliveryRequest/Config/ProfileId, fall back to 'default'
Config.
- Schema change: Make ProfileID optional.
Refactoring:
- Move Config-merging code from Augmenter into dedicated
'ConfigProfileMerger' class.
- ConfigProfileGenerator: Clarify stream pipeline and comply with
coding standard w.r.t. constant members.
- Add Augmenter test cases for profile selection.
|
|
Augmenter
- Replace default Config Profile with map of Config Profiles. Now,
Augmenter can choose a config profile at runtime and augment it.
- Move Augmenter to sub package.
WIP
- Implement ConfigProfileGenerator, which retrieves Config profiles
from Spring Environment and returns an easy-to-use map with
profiles that is keyed with profile id's.
- Replace application.properties with application.yaml.
- Remove Augmenter test cases: They need to be adapted.
|
|
|
|
- Rewrite DeliveryRequestAugmenter to allow per-field-overriding of
configuration parameters and add test suite.
- Mzs schema change: Move DeliveryRequest/Server into
DeliveryRequest/Config; Reason: DeliveryRequest/Config contains all
parameters exclusively needed by moazs to execute the delivery
request. The msg's server url belongs to this set of parameters.
- WIP: Add prototype implementation of MsgClient and move MsgClient to
dedicated package.
- Refactor: move TnvzClient to dedicated package.
|
|
- Refactor: Move TnvzClient in sub package
- Autowire all parameters instead of each parameter individually
|
|
|
|
- Relax Validation for now by only validating incoming requests.
|
|
Problem: Apache CXF does not validate incoming mzs:DeliveryRequests
automatically. Per default, validation is off (performs better).
However, (1) we need to validate incoming requests, and (2)
automated CXF validation requires less maintenance and is
expected to be more stable than manual validation.
Solution:
- Add @SchemaValidation annotation to @Service.
- Endpoint Configuration: set WsdlLocation and ServiceName (needed
to prevent parser errors; see [1]).
Without those, CXF validates against generated classes and not
against the WSDL spec, and generated classes do not contain format
restrictions.
Add a testcase with an invalid delivery request ("rejectBothProfile-
AndCorporateBody") to ensure that the validator works.
[1] https://stackoverflow.com/questions/2231779/cxf-and-validation-schema-restrictions-ignored
|
|
|
|
|
|
- Reason: Converter does not perform validation
|
|
|
|
- Implement own NamespacePrefixMapper that maps prefixes depending on
whether a msg or a mzs object is being marshaled.
- Namespaces are not hardcoded but extracted from jaxb's generated
sources (somewhat indirect, can be considered a hack, but there's no
public API to extract namespaces)
|
|
- Implement and test conversion from mzs:DeliveryRequest to
msg:DeliveryRequest with the "convert-pojos-by-hand"-strategy.
Reason: The chosen strategy benefits from JAXB's strong typing,
which is useful in this scenario: Differences between msg and mzs
are nuanced and easy to overlook. The chosen strategy is,
unfortunately, verbose and could become expensive to maintain.
- Update SameThreadDeliveryPipeline: Integrate tnvz query, conversion,
and msg query.
- Add MsgClient stub.
tnvz:
- Change TnvzClient stub interface.
- Implement mimetype mismatch check from tnvz Response.
- Put p:Identification from tnvz response into msg:DeliveryRequest.
MZS Schema changes:
- Replace DeliveryRequest/Sender/Person with CorporateBody (because
thats the only sender that is allowed by zusemsg) and add a
SenderProfile choice.
- Add ID Attribute to DeliveryRequest/Sender because
msg/DeliveryRequest/Sender/AbstractSenderPersonType also has an id
attribute.
- Remove PersonDataType because it's dead code.
|
|
- Reason: Improves readability and makes import statetemens shorter
and more consistent
|
|
- App2MZS Server: Instead of generating a DeliveryRequestStatus/Error
Message, we throw an exception. This will generate a SoapFault
(including a 500 http status code), which is more appropriate.
- Fix possible NPE of deliveryRequest.getMetadata().getAppDeliveryID()
by moving appDeliveryID initialization into the TimeOutException catch block
- pom.xml: Remove hamcrest dependency, as not needed for now.
|
|
Add Optional "Config" to MZS Schema:
- Add mzs:DeliveryRequest/Config Element with a
"PerformQueryPersonRequest" node
- The config element contains parameters that are interpreted by
moa-zs and not forwarded to the ZD
- The boolean PerformQueryPersonRequest tells moa-zs if moa-zs should
perform a QueryPersonRequest towards the TNVZ.
- If config is missing, moa-zs augments the delivery request with
parameters from the app's configuartion or the default configuartion
Other Changes:
- Validate and augment incoming requests with the
DeliveryPreprocessor.
- Add stub for TlnvzClient.
- Remove some leftover ObjectFactory imports (because of the builder
they are not needed anymore)
Fixes
- Fixed incorrect API usage of Messageformat.format: format string
needs an index.
pom.xml
- Add Hamcrest Dependency (for writing more expressive tests)
- Add copy constructor to JAXB Builder
Testing
- Test validation of incoming request
- Refactor testcases to improve readability
|
|
- Use Immutable-XJC from https://github.com/sabomichal/immutable-xjc
- Update existing JAXB-object manipulations to use the Builder
- Remove jaxbMarshallerTest (as it relies on mutable JAXB interfaces)
Reason for making JAXB objects immutable: I put JAXB objects in the
repository. Depending on the configuration, the repository can be a
simple hashmap; in that case I might end up sharing JAXB objects
between threads. Immutable shared object should make life a little
simpler.
|
|
- Reason: App2MzsServiceTests only run through the app2mzs front end
without doing any pipeline work.
|
|
- Change app2mzs interface: output message from
app2mzs:DeliveryRequest was app2mzs:DeliveryResponse, now its
msg:DeliveryRequestStatus. Reason: ZD returns
msg:DeliveryRequestStatus which is signed. Moazs does not convert
msg:DeliveryRequestStatus into app2mzs:DeliveryResponse because the
conversion woudl break the signature.
- App2MzsService: Make beans final and inject them with constructor;
Refactor DeliveryRequestHandler into App2MZSService.
- DeliveryPipeline: Add Interface and a "SameThreadImplementation"
that executes the pipeline in the same threat and can be used in
single mode.
- DeliveryRepository: Augment interface for storing and retrieving
request status objects; Add in-memory-implementation for status objects.
- Utils: Add helper function for coalescing multiple values
|
|
|
|
- Add Target to CorporateBodyType
- Remove Authority
- make DateOfBirth optional
|
|
- Important Fix: I forgot to annotate App2MzsService with @Service and
autowire the App2MzsService object when creating the endpoint
bean. For this reason, Spring did not autowire the dependencies in
App2MzsService and I ended up with NullPointerExceptions in the
testsuite.
- Updated some more namespaces
- Add objectFactory bean. objectfactory is autogenerated via the
cxf-code-generation plugin, so i cannot annotate it with @Component
or @Service. Alternative: create the @Bean by myself
- Update the validDeliveryRequest SOAP Message to match the mzs 2.0.0
scheme.
|
|
|
|
- Unit test makes a http request to the service
- Fix NPE by adding endpoint.setAdress("/")
- Choose better name for App2MzsService
|