How read large flat file?

we are using WebMethods Integration Server version 4.6 on jdk 1.3.
We need to pick up a large flat file (whose size round about 5 MB), parse it and then do the mapping.
when We are using the getFile service, loading as bytes and then subsequently using convertToValues, we are getting “Out of memory” exception.

The WebMethods documentation suggest to load large flat file with the getFile service as stream (setup the input parameter loasdAs with stream). In this scenario the output parameter of the getFile Service contains
a reference to the inputStream of the flat file and I suppose that We should read data from the input stream incrementally

how can we read data from the inputStream?
Which service do it?
we have tried to use the service getNodeIterator but it didn’t work (obviously it for xml document)

I would like to tackle the problem without using a custom java service. Can anyone suggest a solution please?

Another questions: does the package WmFlateFiles run in IS 4.6?
In 4.6 do something similar exists?

Appreciate everyone’s comments on this.


The convertToValues service has the notion of an Iterator for iterating over large files. You can pass the input stream into this service in the input parameter edidata. The parser will return only part of the data at a time. Take a look at the EDI example service sampleServices:Iterator810.