Announcement Announcement Module
Collapse
No announcement yet.
Scala DSL - using PublishSubscribe Channels Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Scala DSL - using PublishSubscribe Channels

    Hallo everyone,

    I test the Scala DSL and I also have some problems doing so. Perhaps I have problems with this scala DSL, because the DSL is looking like scala and I am no scala expert. But nevertheless I have problems with a test method I have copied from https://github.com/SpringSource/spri...emoTests.scala

    def demoSendWithExplicitPubSubChannelMultipleSubscribe r = {
    val messageFlow =
    PubSubChannel("direct") --> (
    transform { m: Message[String] => m.getPayload().toUpperCase() } -->
    handle { m: Message[_] => println("Subscriber-1 - " + m) },
    transform { m: Message[String] => m.getPayload().toUpperCase() } -->
    handle { m: Message[_] => println("Subscriber-2 - " + m) })

    messageFlow.send("hello")
    println("done")
    }

    I think that theString "hello", which is send to this channel will be transformed to "HELLO". But it's not.

    What is happening?

    Thanks for any answer!

    Andi
Working...
X