INT-4344: AbstRemoteFileOutGw: Add assert for NPE
JIRA: https://jira.spring.io/browse/INT-4344 The `FtpOutboundGateway` provides ctors without expression for remote path. In this case it is treated as a `working directory` but only for the `LS`, `NLST`, `PUT` and `MPUT` commands. * Add assertion in the `AbstractRemoteFileOutboundGateway` to discard configuration for all other commands when `expression` is `null` **Cherry-pick to 4.3.x** Conflicts: spring-integration-file/src/main/java/org/springframework/integration/file/remote/gateway/AbstractRemoteFileOutboundGateway.java Resolved.
This commit is contained in:
committed by
Gary Russell
parent
6ec34c114c
commit
7d24b8ec67
@@ -86,8 +86,8 @@ public class FtpOutboundGateway extends AbstractRemoteFileOutboundGateway<FTPFil
|
||||
}
|
||||
|
||||
/**
|
||||
* Construct an instance with the supplied session factory, a command ('ls', 'get'
|
||||
* etc).
|
||||
* Construct an instance with the supplied session factory
|
||||
* and command ('ls', 'nlst', 'put' or 'mput').
|
||||
* <p> The {@code remoteDirectory} expression is {@code null} assuming to use
|
||||
* the {@code workingDirectory} from the FTP Client.
|
||||
* @param sessionFactory the session factory.
|
||||
@@ -99,8 +99,8 @@ public class FtpOutboundGateway extends AbstractRemoteFileOutboundGateway<FTPFil
|
||||
}
|
||||
|
||||
/**
|
||||
* Construct an instance with the supplied remote file template, a command ('ls',
|
||||
* 'get' etc).
|
||||
* Construct an instance with the supplied remote file template
|
||||
* and command ('ls', 'nlst', 'put' or 'mput').
|
||||
* <p> The {@code remoteDirectory} expression is {@code null} assuming to use
|
||||
* the {@code workingDirectory} from the FTP Client.
|
||||
* @param remoteFileTemplate the remote file template.
|
||||
|
||||
Reference in New Issue
Block a user