1. websocket-spec

API Usability: Consider API renaming, minor refactorizations for usability


    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:


      In particular, Session and FrameBuilder, configurations.


      Annotations have long names.

      Session is perhaps too general. Session/WebSocketSession/Connection/Conversation.

      Feedback: I think the Session class would be more intuitively served by calling Connection because that's what it seems to captures between the two peers. There is no message bag to store properties (no need to have it) to make this class look like a session. All other methods on this class seem more like properties of a connection rather than a session.

      Split RemoteEndpoint send functionality into a handful of specialized RemoteEndpoints, each with a different mode:-

      one for basic whole message sending
      one for streaming message sending
      one for async message sending
      one for batching, which could be optional.

      DefaultServerConfiguration should be DefaultServerEndpointConfiguration
      ditto client config class.

      private static String CLIENT_CLASSNAME_PROPERTYNAME = "websocket.clientcontainer.classname"; and WebSocketContainer.getClientContainer(). Should not need to be client specific -> getContainer() ?

      IOException on client connect APIs for IO errors, deployment error would then only be for badly formed endpoints.

      Annotation names: too long ? Need WebSocket in all of them ? Better distinction between client and server annotations ?

      Refactor standard handshake header names into one separate util class.

      ServerApplicationConfiguration should be renamed: According to the spec, there may be more than one ServerApplicationConfiguration classes in the application. In that case ServerApplicationConfiguration should be renamed to something else, as it is not application configuration. We need a name that distinguishes it from endpoint configurations, yet there may be some confusion with the name Application causing people to think there can only be one per application package, which is not true.


        No work has yet been logged on this issue.


          • Assignee:
          • Votes:
            0 Vote for this issue
            0 Start watching this issue


            • Created: