sheetalshah1007 opened a new pull request, #569:
URL: https://github.com/apache/atlas/pull/569

   …elation maps to multiple types
   
   ## What changes were proposed in this pull request?
   
   - Fixed bug in `searchRelatedEntities` where attributes with multiple 
relationship types only returned entities of one type Example: `hive_db.tables 
`can have both `hive_table` and hbase_table, but API only returned one type
   
   - Modified `EntityDiscoveryService.searchRelatedEntities() `to:
   -Detect when an attribute has multiple relationship types
   -Collect all corresponding edge labels for the attribute
   -Use `bothE(allEdgeLabels) `to traverse all relationships in a single query
   -Update approximate count calculation to count across all relationship types 
using optimized Gremlin query
   
   
   ## How was this patch tested?
   
   Added 3 new unit tests in `EntityDiscoveryServiceTest`:
   `testSearchRelatedEntitiesWithMultipleRelationshipTypes`: Tests core 
multi-type scenario (hive_table + hbase_table)
   `testSearchRelatedEntitiesWithApproximateCountMultipleTypes`: Verifies 
approximate count accuracy with multiple types
   `testSearchRelatedEntitiesWithSingleRelationshipType`: Ensures backward 
compatibility for single type
   
   Performance testing on databases with mixed hive and hbase tables: no 
degradation observed


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to