Codota Logo
MuxPhysicalConnectionException.getMuxDropChannel
Code IndexAdd Codota to your IDE (free)

How to use
getMuxDropChannel
method
in
org.eclipse.jetty.websocket.common.extensions.mux.MuxPhysicalConnectionException

Best Java code snippets using org.eclipse.jetty.websocket.common.extensions.mux.MuxPhysicalConnectionException.getMuxDropChannel (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Point p =
  • Codota Iconnew Point(x, y)
  • Codota Iconnew Point()
  • Codota IconMouseEvent e;e.getPoint()
  • Smart code suggestions by Codota
}
origin: com.ovea.tajin.servers/tajin-server-jetty9

/**
 * Per spec, the physical connection must be failed.
 * <p>
 * <a href="https://tools.ietf.org/html/draft-ietf-hybi-websocket-multiplexing-08#section-18">Section 18. Fail the Physical Connection.</a>
 * 
 * <blockquote> To _Fail the Physical Connection_, an endpoint MUST send a DropChannel multiplex control block with objective channel ID of 0 and drop
 * reason code in the range of 2000-2999, and then _Fail the WebSocket Connection_ on the physical connection with status code of 1011. </blockquote>
 */
private void mustFailPhysicalConnection(MuxPhysicalConnectionException muxe)
{
  // TODO: stop muxer from receiving incoming sub-channel traffic.
  MuxDropChannel drop = muxe.getMuxDropChannel();
  LOG.warn(muxe);
  try
  {
    generator.generate(null,drop);
  }
  catch (IOException ioe)
  {
    LOG.warn("Unable to send mux DropChannel",ioe);
  }
  String reason = "Mux[MUST FAIL]" + drop.getPhrase();
  reason = StringUtil.truncate(reason,WebSocketFrame.MAX_CONTROL_PAYLOAD);
  this.physicalConnection.close(StatusCode.SERVER_ERROR,reason);
  // TODO: trigger abnormal close for all sub-channels.
}
origin: com.ovea.tajin.server/tajin-server-jetty9

/**
 * Per spec, the physical connection must be failed.
 * <p>
 * <a href="https://tools.ietf.org/html/draft-ietf-hybi-websocket-multiplexing-08#section-18">Section 18. Fail the Physical Connection.</a>
 * 
 * <blockquote> To _Fail the Physical Connection_, an endpoint MUST send a DropChannel multiplex control block with objective channel ID of 0 and drop
 * reason code in the range of 2000-2999, and then _Fail the WebSocket Connection_ on the physical connection with status code of 1011. </blockquote>
 */
private void mustFailPhysicalConnection(MuxPhysicalConnectionException muxe)
{
  // TODO: stop muxer from receiving incoming sub-channel traffic.
  MuxDropChannel drop = muxe.getMuxDropChannel();
  LOG.warn(muxe);
  try
  {
    generator.generate(null,drop);
  }
  catch (IOException ioe)
  {
    LOG.warn("Unable to send mux DropChannel",ioe);
  }
  String reason = "Mux[MUST FAIL]" + drop.getPhrase();
  reason = StringUtil.truncate(reason,WebSocketFrame.MAX_CONTROL_PAYLOAD);
  this.physicalConnection.close(StatusCode.SERVER_ERROR,reason);
  // TODO: trigger abnormal close for all sub-channels.
}
org.eclipse.jetty.websocket.common.extensions.muxMuxPhysicalConnectionExceptiongetMuxDropChannel

Popular methods of MuxPhysicalConnectionException

  • <init>

Popular in Java

  • Start an intent from android
  • getSharedPreferences (Context)
  • findViewById (Activity)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • IOException (java.io)
    Signals that an I/O exception of some sort has occurred. This class is the general class of exceptio
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now