azavea / osmesa

OSMesa is an OpenStreetMap processing stack based on GeoTrellis and Apache Spark
Apache License 2.0
79 stars 26 forks source link

Print emails to console in dev #166

Closed CloudNiner closed 4 years ago

CloudNiner commented 4 years ago

Print notification message for unimplemented sending in staging/production environments.

Fixup startBeginSequence, it now properly upserts via postgresql ON CONFLICT syntax available starting in postgresql 9.5.

Demo

Some sample output from CLI:

[info] 09:16:20 AOIMonitorUtils:                                                                                                          
[info]  Running stream process from:                                                                                                      
[info]    3757399 (2019-11-04 09:14:00.0)                                                                                                 
[info]  to:                                                                                                                               
[info]    3758839 (2019-11-05 09:14:00.0)                                                                                                 
[info]  in replication stream                       
...
[info] 09:16:55 AOIMonitorUtils: Sending Notification for 416a8a93-6808-40c6-955a-2b28fa1b45ee:                   
[info]  AOI Notification for: Test One                                                                                                     
[info]  There were:                                                                                                                       
[info]    - 337 edits                                                                                                                     
[info]    - 15 changesets                                                                                                                 
[info]  for the daily interval from 2019-11-04 09:14:00.0 to 2019-11-05 09:14:00.0.                                                       
[error] [Stage 2:======================================================>(199 + 1) / 200]                                      
[error]                                                                                                                                   
[info] 09:16:55 AOIMonitorUtils: Setting end checkpoint_interval (daily, 3758839)                                             
[info] 09:16:55 AbstractConnector: Stopped Spark@65d3652f{HTTP/1.1,[http/1.1]}{0.0.0.0:4040}