- I have an application that is monitoring numerous topics, tables, and other things on top of MapR-DB and MapR-Streams.
- Each of the health or progress checks is in its own thread and is executed at a given interval (e.g. 5 minutes).
- Eventually, I get an error where some of the health checks that use MapRDB.getTable(tablePath) from MapR's API never return.
- I have logging directly before and after that MapRDB.getTable() call. It clearly starts it and never gets past it, and my monitoring kills it off after waiting 5 minutes.
- The code definitely works; I run multiple copies of the application and only one hits this every so often, sometimes after days.
This seems very strange to me; I can't really picture the MapR API having issues with this basic usage.
- Is this API possibly not thread safe?
- Alternatively, could multiple applications trying to look up the same table at the same time (separate processes) cause an issue?
- Has anyone else seen a hang when looking up MapR tables?
- Is there a way to "reset" the MapRDB java object when things get in a bad state to mitigate this?
- (+edit) I noticed I wasn't calling close() on the table even though I was doing getTable() every cycle. Could this cause the issue noted, or is it a red-herring?