Increase BGL flow security
I would like multiple threads to use the dijkstra_shortest_paths and astar_search BGL functions and then read the property maps of the resulting vertices and edges.
I'm wondering if I should be using mutexes for thread safety.
So here are my questions:
1. Are the dijkstra_shortest_paths and astar_search functions of Boost.Graph safe?
2. If I'm only trying to read chart property maps from multiple threads, do I need to worry about thread safety?
a source to share
I'm not entirely sure about question 1, but BGL data structures have the same thread safety as STL containers (i.e. separate containers cannot share data structures on unsafe threads, but operations on the same container need to be synchronized) ... As for question 2, read-only property access is multi-thread safe as long as at least with BGL property property types.
a source to share