关于ftpreader的getinputstream的异常
- Dominant language
- Java
- Stars
- 17.4k
- Forks
- 5.7k
- PR merge metrics
- No merged PRs in 30d
Description
我的写法:
1、在配置文件中追加了索引文件
2、在task的prepare进行索引读取
3、在recordsender进行数据文件的读取。
目前问题在于ftpHelper.getInputStream(fileName) 有缺陷。
会导致在步骤3中。
```
Description:[出现运行时异常, 请联系我们]. - 运行时错误, 请联系我们 - java.lang.NullPointerException
at java.io.Reader.(Reader.java:78)
at java.io.InputStreamReader.(InputStreamReader.java:97)
at com.alibaba.datax.plugin.unstructuredstorage.reader.UnstructuredStorageReaderUtil.readIndexFromStream(UnstructuredStorageReaderUtil.java:262)
at com.alibaba.datax.plugin.reader.ftpreader.FtpReader$Task.startRead(FtpReader.java:266)
at com.alibaba.datax.core.taskgroup.runner.ReaderRunner.run(ReaderRunner.java:57)
at java.lang.Thread.run(Thread.java:748)
```
sftp不受影响。
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with ftpreader/FtpReader.java at the startRead path and UnstructuredStorageReaderUtil.java around readIndexFromStream line 262. Trace ftpHelper.getInputStream(fileName) for the index-file and data-file sequence described in the issue, then use the reported stack trace to reproduce the failure. Done means the FTP path no longer produces the reported NullPointerException while SFTP remains unaffected.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- data-engineering
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100