[webservices] Problem in Java-WS library WaveformService stream method

Yazan Suleiman yazan at iris.washington.edu
Fri Sep 5 07:54:06 PDT 2014


Thank you Benjamin for the report.  We will be releasing a new version very soon (early next week) and will address this bug for sure.  Yazan



On Sep 5, 2014, at 2:36 AM, Benjamin Sick <benjamin.sick at geophys.uni-stuttgart.de> wrote:

> Hello,
> 
> there seems to be a bug in the WaveformService stream method.
> 
> Extending the waveform reading example from the tutorial to save the
> response in a miniseed file results in a NullPointerException:
> 
> WaveformService waveFormService = serviceUtil.getWaveformService();
> WaveformCriteria criteria = new WaveformCriteria();
> criteria.add(network, station, location, channel, startDate, endDate);
> FileOutputStream os = new FileOutputStream("test.mseed");
> waveFormService.stream(os, criteria);
> os.close();
> 
> The attached diff fixes the problem. However it looks like there is
> unnecessary code duplication in the library. A preferable solution
> IMHO would be to merge the methods fetch and stream.
> 
> Best Regards,
> Benjamin Sick
> 
> -- 
> Dipl.-Ing. Benjamin Sick
> Institut für Geophysik
> Universität Stuttgart
> 
> Email: benjamin.sick at geophys.uni-stuttgart.de
> Website: http://www.geophys.uni-stuttgart.de/mitarbeiter/sick_benjamin.html
> Phone: +49 711 685-87422
> Fax: +49 711 685-87401
> <iris_java_ws_waveformservice_fix.diff>_______________________________________________
> webservices mailing list
> webservices at iris.washington.edu
> http://www.iris.washington.edu/mailman/listinfo/webservices




More information about the webservices mailing list