Reproducing issue #18 was possible. The cause of this issue was a missing record line for a previously recorded host. In consequence, variable unitToModify in CassandraCrawlStatsImporter.update was null in some cases and a NullPointerException was thrown:
Reproducing issue #18 was possible. The cause of this issue was a missing record line for a previously recorded host. In consequence, variable unitToModify in CassandraCrawlStatsImporter.update was null in some cases and a NullPointerException was thrown:
https://github.com/ukwa/monitrix/blob/master/monitrix-webapp/app/uk/bl/monitrix/database/cassandra/ingest/CassandraCrawlStatsImporter.java#L83
The solution was to add an empty record line in this case.
Additionally, several try-catch blocks were added to avoid stack-trace messages in case the cassandra db is currently shut down.
Behaviour of the monitrix webapp was tested with shutdowns in idle and during log file ingest successfully.