title: Improve performance of in() out() and both()
body: <p>Consider we have Vertex User, Post and Edge FriendsWith, HasPost. FriendsWith can be in both directions out and in (usually it is either out or in between 2 users). User is owner of Post.</p>
  
  <p>We got 600000 users and 75 million of Posts</p>
  
  <p>I use to get user friends following query:</p>
  
  <p><code>
  SELECT both('FriendsWith') FROM #12:1
  </code></p>
  
  <p>and to get friend posts</p>
  
  <p><code>
  SELECT both('FriendsWith').out('HasPost') FROM #12:1 LIMIT 50
  </code></p>
  
  <p>but if a user got many friends (~1000) the performance is not the best (~ 400 ms for getting friends and 1-5 sec on getting posts)</p>
  
  <p>Is there any way to improve this queries ?  </p>
  
  <p>Thank you. </p>
  
  <p><strong>UPDATE</strong></p>
  
  <p><code>
  select from (select expand(both('FriendsWith').out('HasPost')) from #12:1) LIMIT 50
  </code>
  50 item(s) found. Query executed in 7.08 sec(s).</p>