Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
0.8.2
-
None
-
None
Description
When trying to:
POST /api/atlas/v2/entity/bulk
{ "entities": [ { "typeName": "hive_db", "attributes": { "qualifiedName": "findme", "name": "findme", "clusterName": <here comes a 33482223 + 10 character long string> }, "status": "ACTIVE", "createdBy": "admin", "updatedBy": "admin", "createTime": 1489585008165, "updateTime": 1489585008801, "version": 0, "classifications": [], "superTypes": [] } ], "referredEntities": {} }
The following occurs in the logs:
Caused by: org.apache.atlas.AtlasException: Unknown datatype {name=hive_principal_type, description=hive_principal_type} at org.apache.atlas.typesystem.persistence.StructInstance.setNull(StructInstance.java:274) at org.apache.atlas.repository.audit.EntityAuditListener.clearAttributeValues(EntityAuditListener.java:175) at org.apache.atlas.repository.audit.EntityAuditListener.getAuditEventDetail(EntityAuditListener.java:158) at org.apache.atlas.repository.audit.EntityAuditListener.createEvent(EntityAuditListener.java:133) at org.apache.atlas.repository.audit.EntityAuditListener.onEntitiesAdded(EntityAuditListener.java:63) at org.apache.atlas.repository.store.graph.v1.AtlasEntityChangeNotifier.notifyListeners(AtlasEntityChangeNotifier.java:164) ... 101 more
This is because the hive_db contains hive_principal_type which is an enum, and StructInstance.setNull does not handle enum types.