• Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

#1 2011-12-09 16:11:21

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi,

When a corrupted file is asked to be unarchive, I have an exception like this one.

Code:

Exception in component tFileUnarchive_1
java.io.IOException: Negative seek offset
    at java.io.RandomAccessFile.seek(Native Method)
    at org.apache.tools.zip.ZipFile.positionAtCentralDirectory(ZipFile.java:365)
    at org.apache.tools.zip.ZipFile.populateFromCentralDirectory(ZipFile.java:243)
    at org.apache.tools.zip.ZipFile.<init>(ZipFile.java:142)
    at org.apache.tools.zip.ZipFile.<init>(ZipFile.java:113)
    at proto.perfweb.PERFWEB.tFileList_1Process(PERFWEB.java:237)
    at proto.perfweb.PERFWEB.runJob(PERFWEB.java:413)
    at proto.perfweb.PERFWEB.main(PERFWEB.java:360)

There is a tLogCatcher but the Java trace is on the console (anothers errors are welle catched by tLogCatcher).

Does anyone have an idea, please?

Thank you

Offline

#2 2011-12-12 03:13:36

pedro
Member
Registered: 2011-11-17
Posts: 3682

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi
What's your file type?
The component tFileUnarchive can support '.zip' files.
For other file types, you may use tSystem to call command to unzip files.

Best regards!
Pedro


Only Paranoid Survive.

Offline

#3 2011-12-12 14:07:05

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Thank you Pedro. It's a non-zip file, but I'd predfer that Talend Job wouldn't write a Java Exception in the command line and give me only a ComponentError.

Maybe with "Check the file before unzipp"?

Offline

#4 2011-12-13 04:54:18

pedro
Member
Registered: 2011-11-17
Posts: 3682

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi
A Java Exception will be thrown in console which is hard coded in Talend Java source code.
You can't get rid of it.
Try "Check the integrity before unzip".
Besides, what's your TOS version?

Best regards!
Pedro


Only Paranoid Survive.

Offline

#5 2011-12-13 17:27:49

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi,

Thanks for your answer. Bad news that we can't catch those error. If I check or not this option, I allways have a trace.

The TOS version : 4.2.2

Offline

#6 2011-12-14 03:15:03

pedro
Member
Registered: 2011-11-17
Posts: 3682

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi
It's wierd.
I have reproduced this issue in TOS 4.0.1 and in TOS 5.0.0. tLogCatcher can catch those errors.
Make sure you have checked 'Catch Java Exception'.
If still, please let me know and show me the screenshot of your job.
Or you may try it in TOS 5.0.0.

Best regards!
Pedro


Only Paranoid Survive.

Offline

#7 2012-01-19 17:56:49

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi.

I'm now on 5.0.1 and allways have the same problem.

http://img854.imageshack.us/img854/9452/erreurtalendunarchive.jpg

How to reproduce :
1. take a file (like .jpg) and rename as .zip (It's not a zip file but it's look like)
2. Try to unarchive with tFileUnarchive

There is a Java stack in spite of tLogCatcher who catch those error

Offline

#8 2012-02-22 09:56:26

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Up!

Offline

#9 2012-02-22 10:06:47

pedro
Member
Registered: 2011-11-17
Posts: 3682

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Hi

Sorry for my delay to answer.
As I said in post #4, a Java Exception will be thrown on console which is hard coded in Talend Java source code.
You can't get rid of it.

Regards,
Pedro


Only Paranoid Survive.

Offline

#10 2012-02-22 14:02:08

Jsl1
Member
Company: Hardis
Registered: 2011-07-01
Posts: 11

Re: Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Ok, I undestood it should be corrected in Talend 5.
I hope this will be corrected on next versions.

Thanh.

Offline

  • Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Catch error of Exception in component tFileUnarchive_1 java.io.IOExcep

Board footer

Powered by FluxBB