Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-51551

Allow CommandTransport and its sub-classes to be sub-typed from outside

    XMLWordPrintable

Details

    Description

      While working on the design for JENKINS-51413, I need to implement a new command transport to support Kafka communication. However, CommandTransport and SynchronousCommandTransport are not allowed to be sub-typed outside of the package because some of the fields, methods were made package-private. The proposed solution to this is to change them to protected access level.

      Attachments

        Issue Links

          Activity

            Code changed in jenkins
            User: Pham Vu Tuan
            Path:
            src/main/java/hudson/remoting/CommandTransport.java
            src/main/java/hudson/remoting/JarCache.java
            src/main/java/hudson/remoting/SynchronousCommandTransport.java
            http://jenkins-ci.org/commit/remoting/bed0a07a1b62ffa195ce330a35906f098e7b1e51
            Log:
            JENKINS-51551 Allow CommandTransport and its sub-classes to be sub-typed from outside (#272)

            • Change some CommandTransport methods from package-private to protected
            • Change read() and write() access to public
            • Make fields public to implement remoting-kafka-agent

            *NOTE:* This service been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/

            Functionality will be removed from GitHub.com on January 31st, 2019.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Pham Vu Tuan Path: src/main/java/hudson/remoting/CommandTransport.java src/main/java/hudson/remoting/JarCache.java src/main/java/hudson/remoting/SynchronousCommandTransport.java http://jenkins-ci.org/commit/remoting/bed0a07a1b62ffa195ce330a35906f098e7b1e51 Log: JENKINS-51551 Allow CommandTransport and its sub-classes to be sub-typed from outside (#272) Change some CommandTransport methods from package-private to protected Change read() and write() access to public Make fields public to implement remoting-kafka-agent * NOTE: * This service been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/ Functionality will be removed from GitHub.com on January 31st, 2019.

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            core/src/main/java/hudson/slaves/SlaveComputer.java
            pom.xml
            http://jenkins-ci.org/commit/jenkins/c405ae701c4bca18f7b4edc6e5cd3bc053b7ee60
            Log:
            [JENKINS-51541,JENKINS-51551,...] - Remoting 3.21 + Allow passing custom CommandTransport implementations to SlaveComputer from ComputerLauncher (#3455)

            • JENKINS-51541 - Introduce new SlaveComputer#setChannel() method which takes custom ChannelBuilder and CommandTransport
            • JENKINS-51541 - Listener is nullable according to the documentation
            • [JENKINS-51551,JENKINS-51223,JENKINS-50965] - Update Remoting to 3.21
            • JENKINS-51541 - Restrict SlaveComputer#setChannel(ChannelBuilder cb, …) to Beta-use only

            *NOTE:* This service been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/

            Functionality will be removed from GitHub.com on January 31st, 2019.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: core/src/main/java/hudson/slaves/SlaveComputer.java pom.xml http://jenkins-ci.org/commit/jenkins/c405ae701c4bca18f7b4edc6e5cd3bc053b7ee60 Log: [JENKINS-51541,JENKINS-51551,...] - Remoting 3.21 + Allow passing custom CommandTransport implementations to SlaveComputer from ComputerLauncher (#3455) JENKINS-51541 - Introduce new SlaveComputer#setChannel() method which takes custom ChannelBuilder and CommandTransport JENKINS-51551 - Pick Remoting version with the API patch JENKINS-51541 - Listener is nullable according to the documentation [JENKINS-51551,JENKINS-51223,JENKINS-50965] - Update Remoting to 3.21 JENKINS-51541 - Restrict SlaveComputer#setChannel(ChannelBuilder cb, …) to Beta-use only * NOTE: * This service been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/ Functionality will be removed from GitHub.com on January 31st, 2019.
            oleg_nenashev Oleg Nenashev added a comment -

            Fixed in Remoting 3.21 and Jenkins 2.127

            oleg_nenashev Oleg Nenashev added a comment - Fixed in Remoting 3.21 and Jenkins 2.127

            People

              pvtuan10 Pham Vu Tuan
              pvtuan10 Pham Vu Tuan
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: