lshift/diffa — Issue #2: RangeConstraint serialization does not take empty bounds into consideration
Author: 0x6e6562
Created: 2011-11-21 16:29:48+00:00
State: open

When half- or completely open bounds are configured, the following NPE occurs when a scan is kicked off:

```
00:00:02.339 [akka:event-driven:dispatcher:global-1] ERROR PairActor:398 - Upstream scan failed: diffa/Staging7-Transactions
java.lang.NullPointerException: null
at net.lshift.diffa.participant.scanning.DateRangeConstraint.getEndText(DateRangeConstraint.java:73) ~[participant-support-1.0.1.jar:na]
at net.lshift.diffa.messaging.json.ScanningParticipantRestClient$$anonfun$scan$1.apply(ScanningParticipantRestClient.scala:43) ~[diffa-json-messaging-1.0.1.jar:na]
at net.lshift.diffa.messaging.json.ScanningParticipantRestClient$$anonfun$scan$1.apply(ScanningParticipantRestClient.scala:38) ~[diffa-json-messaging-1.0.1.jar:na]
at scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:59) ~[scala-library-2.9.1.jar:na]
at scala.collection.immutable.List.foreach(List.scala:45) ~[scala-library-2.9.1.jar:na]
at net.lshift.diffa.messaging.json.ScanningParticipantRestClient.scan(ScanningParticipantRestClient.scala:38) ~[diffa-json-messaging-1.0.1.jar:na]
at net.lshift.diffa.kernel.participants.ParticipantFactory$CompositeParticipant.scan(ParticipantFactory.scala:75) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$ScanStrategy.scanEntities(BaseScanningVersionPolicy.scala:196) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$ScanStrategy.scanParticipant(BaseScanningVersionPolicy.scala:139) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$$anonfun$scanUpstream$1$$anonfun$apply$mcV$sp$1.apply(BaseScanningVersionPolicy.scala:97) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$$anonfun$scanUpstream$1$$anonfun$apply$mcV$sp$1.apply(BaseScanningVersionPolicy.scala:97) ~[diffa-kernel-1.0.1.jar:na]
at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:60) ~[scala-library-2.9.1.jar:na]
at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:44) ~[scala-library-2.9.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$$anonfun$scanUpstream$1.apply$mcV$sp(BaseScanningVersionPolicy.scala:96) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$$anonfun$scanUpstream$1.apply(BaseScanningVersionPolicy.scala:94) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy$$anonfun$scanUpstream$1.apply(BaseScanningVersionPolicy.scala:94) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy.benchmark(BaseScanningVersionPolicy.scala:84) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.differencing.BaseScanningVersionPolicy.scanUpstream(BaseScanningVersionPolicy.scala:94) ~[diffa-kernel-1.0.1.jar:na]
at net.lshift.diffa.kernel.actors.PairActor$$anonfun$handleScanMessage$1.apply$mcV$sp(PairActor.scala:389) ~[diffa-kernel-1.0.1.jar:na]
at akka.actor.Actor$$anonfun$spawn$1$$anon$1$$anonfun$receive$1.apply(Actor.scala:280) [akka-actor-1.2.jar:na]
at akka.actor.Actor$$anonfun$spawn$1$$anon$1$$anonfun$receive$1.apply(Actor.scala:279) [akka-actor-1.2.jar:na]
at akka.actor.Actor$class.apply(Actor.scala:545) [akka-actor-1.2.jar:na]
at akka.actor.Actor$$anonfun$spawn$1$$anon$1.apply(Actor.scala:277) [akka-actor-1.2.jar:na]
at akka.actor.LocalActorRef.invoke(ActorRef.scala:905) [akka-actor-1.2.jar:na]
at akka.dispatch.MessageInvocation.invoke(MessageHandling.scala:25) [akka-actor-1.2.jar:na]
at akka.dispatch.ExecutableMailbox$class.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:216) [akka-actor-1.2.jar:na]
at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.processMailbox(ExecutorBasedEventDrivenDispatcher.scala:122) [akka-actor-1.2.jar:na]
at akka.dispatch.ExecutableMailbox$class.run(ExecutorBasedEventDrivenDispatcher.scala:188) [akka-actor-1.2.jar:na]
at akka.dispatch.ExecutorBasedEventDrivenDispatcher$$anon$4.run(ExecutorBasedEventDrivenDispatcher.scala:122) [akka-actor-1.2.jar:na]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [na:1.6.0_16]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [na:1.6.0_16]
at java.lang.Thread.run(Thread.java:619) [na:1.6.0_16]
at akka.dispatch.MonitorableThread.run(ThreadPoolBuilder.scala:184) [akka-actor-1.2.jar:na]
```