add ActorRef.noSender() for the Java API, see #3429

- Actor.noSender is not accessible from Java, but it was in 2.1 so don’t
  remove
- replaced all “null” in doc tests with ActorRef.noSender()
This commit is contained in:
Roland Kuhn 2013-06-05 16:59:25 +02:00
parent 6c96485b26
commit a2a646af4e
24 changed files with 92 additions and 79 deletions

View file

@ -17,7 +17,8 @@ public class ProducerTestBase {
ActorSystem system = ActorSystem.create("some-system");
Props props = Props.create(Orders.class);
ActorRef producer = system.actorOf(props, "jmsproducer");
producer.tell("<order amount=\"100\" currency=\"PLN\" itemId=\"12345\"/>", null);
producer.tell("<order amount=\"100\" currency=\"PLN\" itemId=\"12345\"/>",
ActorRef.noSender());
//#TellProducer
JavaTestKit.shutdownActorSystem(system);
}
@ -42,7 +43,7 @@ public class ProducerTestBase {
Map<String,Object> headers = new HashMap<String, Object>();
headers.put(CamelMessage.MessageExchangeId(),"123");
producer.tell(new CamelMessage("<order amount=\"100\" currency=\"PLN\" " +
"itemId=\"12345\"/>",headers), null);
"itemId=\"12345\"/>",headers), ActorRef.noSender());
//#Correlate
system.stop(producer);
JavaTestKit.shutdownActorSystem(system);