NullPointerException in producer_kafka
aviv-amdocs opened this issue · 1 comments
aviv-amdocs commented
at 77bd026
Trying to run the tests in producer_kafka
fails one of the contracts (validate_shouldSendFoo
) with NPE
$ cd common
$ mvn clean install
...
$ cd ..
$ mvn install -DskipTests=true
...
(there's some errors wrt pact)
$ cd roducer_kafka
$ mvn install test -DtrimStackTrace=false
...
[ERROR] Tests run: 2, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.791 s <<< FAILURE! - in com.example.ContractVerifierTest
[ERROR] validate_shouldSendFoo Time elapsed: 0.078 s <<< ERROR!
java.lang.NullPointerException
at java.base/java.util.Objects.requireNonNull(Objects.java:221)
at java.base/java.util.stream.Collectors.lambda$uniqKeysMapAccumulator$1(Collectors.java:178)
at java.base/java.util.stream.ReduceOps$3ReducingSink.accept(ReduceOps.java:169)
at java.base/java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet.lambda$entryConsumer$0(Collections.java:1576)
at java.base/java.util.HashMap$EntrySpliterator.forEachRemaining(HashMap.java:1746)
at java.base/java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet$UnmodifiableEntrySetSpliterator.forEachRemaining(Collections.java:1601)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578)
at org.springframework.cloud.contract.verifier.messaging.kafka.ContractVerifierKafkaHelper.convertHeaders(ContractVerifierKafkaConfiguration.java:93)
at org.springframework.cloud.contract.verifier.messaging.kafka.ContractVerifierKafkaHelper.convert(ContractVerifierKafkaConfiguration.java:88)
at org.springframework.cloud.contract.verifier.messaging.kafka.ContractVerifierKafkaHelper.convert(ContractVerifierKafkaConfiguration.java:80)
at org.springframework.cloud.contract.verifier.messaging.internal.ContractVerifierMessaging.receive(ContractVerifierMessaging.java:65)
at com.example.ContractVerifierTest.validate_shouldSendFoo(ContractVerifierTest.java:30)
...
marcingrzejszczak commented
That's fixed with the latest snapshots