|
|
|
@ -207,7 +207,7 @@ public class SFTPFileService implements FileService {
|
|
|
|
|
Set<PosixFilePermission> filePermissions,
|
|
|
|
|
CopyOption... copyOptions) throws IOException {
|
|
|
|
|
performWithContext(ctx -> {
|
|
|
|
|
upload(ctx, Files.newByteChannel(source), ctx.fileSystem.getPath(target),
|
|
|
|
|
doUpload(ctx, Files.newByteChannel(source), ctx.fileSystem.getPath(target),
|
|
|
|
|
dirPermissions, filePermissions, copyOptions);
|
|
|
|
|
return null;
|
|
|
|
|
});
|
|
|
|
@ -227,7 +227,7 @@ public class SFTPFileService implements FileService {
|
|
|
|
|
Set<PosixFilePermission> filePermissions,
|
|
|
|
|
CopyOption... copyOptions) throws IOException {
|
|
|
|
|
performWithContext(ctx -> {
|
|
|
|
|
upload(ctx, Files.newByteChannel(source), target, dirPermissions, filePermissions, copyOptions);
|
|
|
|
|
doUpload(ctx, Files.newByteChannel(source), target, dirPermissions, filePermissions, copyOptions);
|
|
|
|
|
return null;
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
@ -337,7 +337,7 @@ public class SFTPFileService implements FileService {
|
|
|
|
|
Set<PosixFilePermission> filePermissions,
|
|
|
|
|
CopyOption... copyOptions) throws IOException {
|
|
|
|
|
performWithContext(ctx -> {
|
|
|
|
|
upload(ctx, Channels.newChannel(source), target,
|
|
|
|
|
doUpload(ctx, Channels.newChannel(source), target,
|
|
|
|
|
dirPermissions, filePermissions, copyOptions);
|
|
|
|
|
return null;
|
|
|
|
|
});
|
|
|
|
@ -350,13 +350,13 @@ public class SFTPFileService implements FileService {
|
|
|
|
|
Set<PosixFilePermission> filePermissions,
|
|
|
|
|
CopyOption... copyOptions) throws IOException {
|
|
|
|
|
performWithContext(ctx -> {
|
|
|
|
|
upload(ctx, Channels.newChannel(source), ctx.fileSystem.getPath(target),
|
|
|
|
|
doUpload(ctx, Channels.newChannel(source), ctx.fileSystem.getPath(target),
|
|
|
|
|
dirPermissions, filePermissions, copyOptions);
|
|
|
|
|
return null;
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void upload(SFTPContext ctx,
|
|
|
|
|
private void doUpload(SFTPContext ctx,
|
|
|
|
|
ReadableByteChannel source,
|
|
|
|
|
Path target,
|
|
|
|
|
Set<PosixFilePermission> dirPerms,
|
|
|
|
|