websocket-spec
  1. websocket-spec
  2. WEBSOCKET_SPEC-170

Add examples to spec to clarify URI-template matching precendence

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None

      Description

      (from Jan)

      @ServerEndpoint(value = "/different/

      {param1}/{param2}")
      public class WS2DifferentPathParamsServer {
      @OnMessage
      public String param(@PathParam("param1") boolean b1,
      @PathParam("param2") char p2, String content) { return String.valueOf(b1) + String.valueOf(p2); }
      }

      @ServerEndpoint(value = "/{param1}

      ")
      public class WSDirectStringPathParamServer {
      @OnMessage
      public String param(@PathParam("param1") String p1, String content)

      { return p1; }

      }

      When I try:
      ws://localhost:8080/ws/different/true/0, the second endpoint is matched.

        Activity

          People

          • Assignee:
            dannycoward
            Reporter:
            dannycoward
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: