mirror of https://github.com/jenkinsci/jenkins.git
				
				
				
			Restore JCasC compatibility for `JNLPLauncher.tunnel` (#8793)
* Restore JCasC compatibility for `JNLPLauncher.tunnel` * Also removing `@Deprecated` on fields & getters
This commit is contained in:
		
							parent
							
								
									f60c1b4872
								
							
						
					
					
						commit
						df03159afe
					
				|  | @ -53,11 +53,11 @@ import org.kohsuke.stapler.DataBoundSetter; | ||||||
|  * @author Stephen Connolly |  * @author Stephen Connolly | ||||||
|  * @author Kohsuke Kawaguchi |  * @author Kohsuke Kawaguchi | ||||||
| */ | */ | ||||||
|  | @SuppressWarnings("deprecation") // see comments about CasC | ||||||
| public class JNLPLauncher extends ComputerLauncher { | public class JNLPLauncher extends ComputerLauncher { | ||||||
|     /** |     /** | ||||||
|      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. |      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. | ||||||
|      */ |      */ | ||||||
|     @DataBoundSetter |  | ||||||
|     @CheckForNull |     @CheckForNull | ||||||
|     public String tunnel; |     public String tunnel; | ||||||
| 
 | 
 | ||||||
|  | @ -67,11 +67,9 @@ public class JNLPLauncher extends ComputerLauncher { | ||||||
|     @Deprecated |     @Deprecated | ||||||
|     public final transient String vmargs = null; |     public final transient String vmargs = null; | ||||||
| 
 | 
 | ||||||
|     @Deprecated |  | ||||||
|     @NonNull |     @NonNull | ||||||
|     private RemotingWorkDirSettings workDirSettings = RemotingWorkDirSettings.getEnabledDefaults(); |     private RemotingWorkDirSettings workDirSettings = RemotingWorkDirSettings.getEnabledDefaults(); | ||||||
| 
 | 
 | ||||||
|     @Deprecated |  | ||||||
|     private boolean webSocket; |     private boolean webSocket; | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | @ -131,7 +129,9 @@ public class JNLPLauncher extends ComputerLauncher { | ||||||
|         return this; |         return this; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     @Deprecated |     /** | ||||||
|  |      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. | ||||||
|  |      */ | ||||||
|     public RemotingWorkDirSettings getWorkDirSettings() { |     public RemotingWorkDirSettings getWorkDirSettings() { | ||||||
|         return workDirSettings; |         return workDirSettings; | ||||||
|     } |     } | ||||||
|  | @ -149,7 +149,9 @@ public class JNLPLauncher extends ComputerLauncher { | ||||||
|         return false; |         return false; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     @Deprecated |     /** | ||||||
|  |      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. | ||||||
|  |      */ | ||||||
|     public boolean isWebSocket() { |     public boolean isWebSocket() { | ||||||
|         return webSocket; |         return webSocket; | ||||||
|     } |     } | ||||||
|  | @ -162,6 +164,21 @@ public class JNLPLauncher extends ComputerLauncher { | ||||||
|         this.webSocket = webSocket; |         this.webSocket = webSocket; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|  |     /** | ||||||
|  |      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. | ||||||
|  |      */ | ||||||
|  |     public String getTunnel() { | ||||||
|  |         return tunnel; | ||||||
|  |     } | ||||||
|  | 
 | ||||||
|  |     /** | ||||||
|  |      * Deprecated (only used with deprecated {@code -jnlpUrl} mode), but cannot mark it as such without breaking CasC. | ||||||
|  |      */ | ||||||
|  |     @DataBoundSetter | ||||||
|  |     public void setTunnel(String tunnel) { | ||||||
|  |         this.tunnel = tunnel; | ||||||
|  |     } | ||||||
|  | 
 | ||||||
|     @Override |     @Override | ||||||
|     public void launch(SlaveComputer computer, TaskListener listener) { |     public void launch(SlaveComputer computer, TaskListener listener) { | ||||||
|         // do nothing as we cannot self start |         // do nothing as we cannot self start | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue