title: Neo4j traversal for subgraph
body: <p>I want to extract the subgraph from Neo4j graph database.The input will be two nodes. we need to find all the one-hop neighbors from both nodes and form the union of nodes(let's call it closure). Now we have to get all the relationships in this closure (union of nodes including input nodes). how to approach this problem in neo4j with java "efficiently". please suggest.</p>