Repository: atlas Updated Branches: refs/heads/master 511370530 -> 97e47d24d
ATLAS-2304: fix query used during export to work TinkerPop3 (#2) Signed-off-by: Madhan Neethiraj <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/atlas/repo Commit: http://git-wip-us.apache.org/repos/asf/atlas/commit/97e47d24 Tree: http://git-wip-us.apache.org/repos/asf/atlas/tree/97e47d24 Diff: http://git-wip-us.apache.org/repos/asf/atlas/diff/97e47d24 Branch: refs/heads/master Commit: 97e47d24d99456b621b7f8962c47c5e16a5559b1 Parents: 5113705 Author: Ashutosh Mestry <[email protected]> Authored: Fri Jan 12 23:27:19 2018 -0800 Committer: Madhan Neethiraj <[email protected]> Committed: Sat Jan 13 22:47:00 2018 -0800 ---------------------------------------------------------------------- .../java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/atlas/blob/97e47d24/repository/src/main/java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java ---------------------------------------------------------------------- diff --git a/repository/src/main/java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java b/repository/src/main/java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java index 22afd32..1fda241 100644 --- a/repository/src/main/java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java +++ b/repository/src/main/java/org/apache/atlas/util/AtlasGremlin3QueryProvider.java @@ -38,7 +38,7 @@ public class AtlasGremlin3QueryProvider extends AtlasGremlin2QueryProvider { case EXPORT_TYPE_DEFAULT: return "g.V().has('__typeName',typeName).has(attrName, attrValue).has('__guid').values('__guid').toList()"; case EXPORT_BY_GUID_FULL: - return "g.V().has('__guid', startGuid).bothE().bothV().has('__guid').transform{[__guid:it.__guid,isProcess:(it.__superTypeNames != null) ? it.__superTypeNames.contains('Process') : false ]}.dedup().toList()"; + return "g.V().has('__guid', startGuid).bothE().bothV().has('__guid').project('__guid', 'isProcess').by('__guid').by(map {it.get().values('__superTypeNames').toSet().contains('Process')}).dedup().toList()"; case EXPORT_BY_GUID_CONNECTED_IN_EDGE: return "g.V().has('__guid', startGuid).inE().outV().has('__guid').project('__guid', 'isProcess').by('__guid').by(map {it.get().values('__superTypeNames').toSet().contains('Process')}).dedup().toList()"; case EXPORT_BY_GUID_CONNECTED_OUT_EDGE:
