ismop / dap

3 stars 0 forks source link

Read water height from "pogodynka" #158

Closed mkasztelnik closed 8 years ago

mkasztelnik commented 8 years ago

Create dedicate flume sink which in defined period of time read water height from Czernichow (http://monitor.pogodynka.pl/api/station/hydro/?id=149190230). Perfect solution would be to allow sink to be defined in flume configuration (where pogodynka id and read interval is given).

bwilk commented 8 years ago

Implemented in https://github.com/ismop/flume-pogodynka-source Needs integration testing and deployment

bwilk commented 8 years ago

Deployed on development infrastructure. There are some bugs in parsing time zone: pl.cyfronet.ismop.flume.PogodynkaParseException: java.time.format.DateTimeParseException: Text '2016-09-20T07:40:00Z' could not be parsed: Unable to obtain ZonedDateTime from TemporalAccessor: {InstantSeconds=1474357200, NanoOfSecond=0},ISO of type java.time.format.Parsed at pl.cyfronet.ismop.flume.Pogodynka.parsePogodynkaResponse(Pogodynka.java:70) at pl.cyfronet.ismop.flume.Pogodynka.nextReading(Pogodynka.java:48) at pl.cyfronet.ismop.flume.PogodynkaSource.process(PogodynkaSource.java:91) at org.apache.flume.source.PollableSourceRunner$PollingRunner.run(PollableSourceRunner.java:139) at java.lang.Thread.run(Thread.java:744)

bwilk commented 8 years ago

This is strange because it works on my local machine with java 1.8.0_101-b13 and does not work with 1.8.0-b132 on the target development server

mpawlik commented 8 years ago

Quick google search suggests, that we really need to update java on the server: https://bugs.openjdk.java.net/browse/JDK-8041360t

mkasztelnik commented 8 years ago

I just installed newest java 1.8.0_101 - please check if this helped.

mkasztelnik commented 8 years ago

Aaa flume and flume-dev was already restarted using upstart

bwilk commented 8 years ago

Ok - problems fixed. The source is deployed on dev and prod infrastructures