Class

org.suecarter.websocket

WebSocketClient

Related Doc: package websocket

Permalink

abstract class WebSocketClient extends WebSocketClientWorker with Stash with WebSocketCommon

Abstract actor that makes an HTTP connection request to the provided location and upgrades to WebSocket when connected.

NOTE: this uses a Stash so needs a dequeue mailbox. The included

.withMailbox("org.suecarter.websocket.high-priority-ack-mailbox")

is highly recommended.

Linear Supertypes
WebSocketCommon, WebSocketClientWorker, ActorLogging, Stash, RequiresMessageQueue[DequeBasedMessageQueueSemantics], UnrestrictedStash, StashSupport, Actor, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. WebSocketClient
  2. WebSocketCommon
  3. WebSocketClientWorker
  4. ActorLogging
  5. Stash
  6. RequiresMessageQueue
  7. UnrestrictedStash
  8. StashSupport
  9. Actor
  10. AnyRef
  11. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Instance Constructors

  1. new WebSocketClient(host: String, port: Int, path: String = "/", ssl: Boolean = false)

    Permalink

Type Members

  1. type Receive = PartialFunction[Any, Unit]

    Permalink
    Definition Classes
    Actor

Abstract Value Members

  1. abstract def websockets: Receive

    Permalink

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val WebSocketUpgradeHeaders: List[HttpHeader with Product with Serializable]

    Permalink
  5. def aroundPostRestart(reason: Throwable): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
  6. def aroundPostStop(): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
  7. def aroundPreRestart(reason: Throwable, message: Option[Any]): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
  8. def aroundPreStart(): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
  9. def aroundReceive(receive: akka.actor.Actor.Receive, msg: Any): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
  10. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  11. final def businessLogic: Receive

    Permalink
    Definition Classes
    WebSocketClientWebSocketClientWorker
  12. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  13. def closeLogic: Receive

    Permalink
    Definition Classes
    WebSocketClientWorker
  14. def connection: ActorRef

    Permalink

    The actor which could receive frame directly.

    The actor which could receive frame directly. ie. by connection ! frame

    Definition Classes
    WebSocketClientWorker
  15. implicit val context: ActorContext

    Permalink
    Definition Classes
    Actor
  16. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  18. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  19. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  20. def handshaking: Receive

    Permalink
    Definition Classes
    WebSocketClientWorker
  21. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  22. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  23. def log: LoggingAdapter

    Permalink
    Definition Classes
    ActorLogging
  24. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  25. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  26. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  27. def postRestart(reason: Throwable): Unit

    Permalink
    Definition Classes
    Actor
    Annotations
    @throws( classOf[java.lang.Exception] )
  28. def postStop(): Unit

    Permalink
    Definition Classes
    UnrestrictedStash → Actor
  29. def preRestart(reason: Throwable, message: Option[Any]): Unit

    Permalink
    Definition Classes
    UnrestrictedStash → Actor
  30. def preStart(): Unit

    Permalink
    Definition Classes
    WebSocketClient → Actor
  31. def receive: PartialFunction[Any, Unit]

    Permalink
    Definition Classes
    WebSocketClientWebSocketClientWorker → Actor
  32. implicit final val self: ActorRef

    Permalink
    Definition Classes
    Actor
  33. def sendWithAck(frame: TextFrame, downstream: ActorRef): Unit

    Permalink

    Wandoulabs' WebSocket implementation doesn't support ack/nack-ing on the CommandFrame level.

    Wandoulabs' WebSocket implementation doesn't support ack/nack-ing on the CommandFrame level. But it is possible to drop down to TCP messages by duplicating their FrameRendering logic in the ServerWorker actor. Here we construct a payload that is ignored by the ConnectionManager which requests an Ack.

    A similar pattern could be applied for non-Text Frames and NACK based writing, in order to skip the FrameRendering logic.

    WARNING: callers should be aware of the implications of changing the state in this method. Multiple calls to this **must not** be made in the same receive block, or the earlier Acks will be missed.

    For more information, see https://groups.google.com/d/msg/akka-user/ckUJ9wlltuc/h37ZRCkAA6cJ

    Definition Classes
    WebSocketCommon
  34. final def sender(): ActorRef

    Permalink
    Definition Classes
    Actor
  35. def stash(): Unit

    Permalink
    Definition Classes
    StashSupport
  36. def stashing: Receive

    Permalink
    Definition Classes
    WebSocketCommon
  37. def supervisorStrategy: SupervisorStrategy

    Permalink
    Definition Classes
    Actor
  38. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  39. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  40. def unhandled(message: Any): Unit

    Permalink
    Definition Classes
    Actor
  41. def unstashAll(): Unit

    Permalink
    Definition Classes
    StashSupport
  42. def upgradeRequest: HttpRequest

    Permalink
    Definition Classes
    WebSocketClientWebSocketClientWorker
  43. def userHeaders: List[HttpHeader]

    Permalink
  44. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  45. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  46. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  47. def waitingForAck(downstream: ActorRef, sending: Frame): Receive

    Permalink
    Definition Classes
    WebSocketCommon
  48. def waitingForRecovery(frame: Frame): Receive

    Permalink
    Definition Classes
    WebSocketCommon

Inherited from WebSocketCommon

Inherited from WebSocketClientWorker

Inherited from ActorLogging

Inherited from Stash

Inherited from RequiresMessageQueue[DequeBasedMessageQueueSemantics]

Inherited from UnrestrictedStash

Inherited from StashSupport

Inherited from Actor

Inherited from AnyRef

Inherited from Any

Ungrouped