fix circular dependency
This commit is contained in:
parent
ed3a6d31f0
commit
88db266d26
1 changed files with 1 additions and 8 deletions
|
|
@ -5,7 +5,6 @@ import java.util.List;
|
|||
import com.jcraft.jsch.ChannelSftp;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.Profile;
|
||||
|
|
@ -27,15 +26,9 @@ import ru.spcex.clearing.dbf.importer.config.settings.ImportDBFServiceSettings;
|
|||
@Configuration
|
||||
public class SFTPConfig {
|
||||
private final Logger log = LoggerFactory.getLogger(getClass());
|
||||
private final ImportDBFServiceSettings settings;
|
||||
|
||||
@Autowired
|
||||
public SFTPConfig(ImportDBFServiceSettings settings) {
|
||||
this.settings = settings;
|
||||
}
|
||||
|
||||
@Bean
|
||||
public SessionFactory<ChannelSftp.LsEntry> sftpSessionFactory() {
|
||||
public SessionFactory<ChannelSftp.LsEntry> sftpSessionFactory(ImportDBFServiceSettings settings) {
|
||||
DefaultSftpSessionFactory factory = new DefaultSftpSessionFactory(true);
|
||||
factory.setHost(settings.getStore().getSftpIn().getServerIp());
|
||||
factory.setPort(settings.getStore().getSftpIn().getServerPort());
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue