Details

    • Type: New Feature New Feature
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0-b08
    • Fix Version/s: 1.0-rc1
    • Component/s: None
    • Labels:
      None

      Description

      I think the "publishServer" method parameter in TyrusServerContainer class should be modified:
      instead of receiving a "class", wouldn't it be more useful now to receive a ServerEndpointConfiguration instance object?

      i.e:

      Supposing it had the following method's signature:

      public void publishServer(ServerEndpointConfiguration config)
      throws DeploymentException;

      Then, it could be possible to register the same endpoint type with many different configurations.

      i.e:

      tyrusServerContainer.publishServer(new MyChatRoomServerEndpointConfiguration("/room1"));

      tyrusServerContainer.publishServer(new MyChatRoomServerEndpointConfiguration("/room2"));

        Activity

        Hide
        Pavel Bucek added a comment -

        publishServer method was declared in API class ServerContainer which was merged with ClientContainer and renamed to WebSocketContainer and does not longer contain this method. So it will be most likely removed..

        Show
        Pavel Bucek added a comment - publishServer method was declared in API class ServerContainer which was merged with ClientContainer and renamed to WebSocketContainer and does not longer contain this method. So it will be most likely removed..
        Hide
        jmarine added a comment -

        What a pity!

        Anyway, public draft (spec v011) also says in "6.3 Application Deployment in standalone websocket server containers":
        "...standalone websocket server containers may employ other implementation techniques to deploy endpoints if they wish."

        The actual websocket endpoint deployment support in "Server" class is too much static (only at server startup).
        So, I think TyrusServerContainer should keep a public method to allow dynamic deployment of websocket services in standalone applications (without JavaEE container requirements), as other languages have (.NET, NodeJS, Python,...).

        Also, it will be useful to have a public method in the "Server" class to dynamically deploy websocket endpoints.

        Show
        jmarine added a comment - What a pity! Anyway, public draft (spec v011) also says in "6.3 Application Deployment in standalone websocket server containers": "...standalone websocket server containers may employ other implementation techniques to deploy endpoints if they wish." The actual websocket endpoint deployment support in "Server" class is too much static (only at server startup). So, I think TyrusServerContainer should keep a public method to allow dynamic deployment of websocket services in standalone applications (without JavaEE container requirements), as other languages have (.NET, NodeJS, Python,...). Also, it will be useful to have a public method in the "Server" class to dynamically deploy websocket endpoints.
        Hide
        Pavel Bucek added a comment -

        well, this is something we might include in final version, but (given that there are some things to solve when enabling this kind of dynamic deployment) now our primary goal is to be spec compliant.

        moving to backlog for now, adjusting issue title.

        Show
        Pavel Bucek added a comment - well, this is something we might include in final version, but (given that there are some things to solve when enabling this kind of dynamic deployment) now our primary goal is to be spec compliant. moving to backlog for now, adjusting issue title.
        Hide
        Pavel Bucek added a comment -

        See ServerContainer class (WebSocket api), and test/dynamic-deploy module in tyrus trunk.

        Show
        Pavel Bucek added a comment - See ServerContainer class (WebSocket api), and test/dynamic-deploy module in tyrus trunk.
        Hide
        jmarine added a comment -

        Could TyrusServerContainer class extend ServerContainer? (instead of WebSocketContainer)
        It may be easier for JavaSE environments to create a TyrusServerContainer, addEndpoint configurations, and start the container (instead of having to cache all configurations, to construct the TyrusServerContainer with the dynamicallyAddedEndpointConfigs parameter).

        Show
        jmarine added a comment - Could TyrusServerContainer class extend ServerContainer? (instead of WebSocketContainer) It may be easier for JavaSE environments to create a TyrusServerContainer, addEndpoint configurations, and start the container (instead of having to cache all configurations, to construct the TyrusServerContainer with the dynamicallyAddedEndpointConfigs parameter).

          People

          • Assignee:
            Pavel Bucek
            Reporter:
            jmarine
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: