refactoring code. Last test showed problems. Needs to be checked.
shortest path algorithm for testing with Rexster input format current implementation