[ https://issues.apache.org/jira/browse/ATLAS-4956?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17922188#comment-17922188 ]
Priyanshi Shah commented on ATLAS-4956: --------------------------------------- This issue occurs when we set the name of a typeDef to one of the property names like "description, name, version, options, and servicetype". This is because in the typedef vertex the name conflicts with the property key in the vertex. Example, if we have a classification with name "test" and additional attributes like attr1,attr2, then we have a vertex properties like the one explained below: __type.name-> test __type.description -> "" // line2 __type.options -> "" __type.version -> "" __type.serviceType -> "" __type.test -> ["attr1","attr2"] //line6 So, if the name of the typedef is (for example) description, then property key on line2 conflicts with the one on line 6 and causes the various issues. > Creating tag with name description throws java.lang.ClassCastException > ---------------------------------------------------------------------- > > Key: ATLAS-4956 > URL: https://issues.apache.org/jira/browse/ATLAS-4956 > Project: Atlas > Issue Type: Bug > Components: atlas-core > Reporter: Priyanshi Shah > Assignee: Priyanshi Shah > Priority: Major > > Attempt to create a tag with name "description" , Atlas throws 500 with > following exception: > {code:java} > 2024-12-31 17:54:36,378 [etp940087898-232 - > fdf1467f-1146-493b-8b24-6ee25dc089ba] ERROR [ExceptionMapperUtil.java:32] > Error handling a request: 22206345b8ffa8f0 > java.lang.ClassCastException: java.lang.String cannot be cast to > java.util.List > at > org.apache.atlas.repository.store.graph.v2.AtlasStructDefStoreV2.toStructDef(AtlasStructDefStoreV2.java:495) > at > org.apache.atlas.repository.store.graph.v2.AtlasClassificationDefStoreV2.toClassificationDef(AtlasClassificationDefStoreV2.java:355) > at > org.apache.atlas.repository.store.graph.v2.AtlasClassificationDefStoreV2.create(AtlasClassificationDefStoreV2.java:103) > at > org.apache.atlas.repository.store.graph.v2.AtlasClassificationDefStoreV2.create(AtlasClassificationDefStoreV2.java:46) > at > org.apache.atlas.repository.store.graph.AtlasTypeDefGraphStore.addToGraphStore(AtlasTypeDefGraphStore.java:1016) > at > org.apache.atlas.repository.store.graph.AtlasTypeDefGraphStore.createTypesDef(AtlasTypeDefGraphStore.java:399) > at > org.apache.atlas.repository.store.graph.AtlasTypeDefGraphStore$$FastClassBySpringCGLIB$$5226c80b.invoke(<generated>) > at > org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) > at > org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:792) > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) > at > org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:762) > at > org.apache.atlas.GraphTransactionInterceptor.invoke(GraphTransactionInterceptor.java:111) > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) > at > org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:762) > at > org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:707) > at > org.apache.atlas.repository.store.graph.v2.AtlasTypeDefGraphStoreV2$$EnhancerBySpringCGLIB$$674192d4.createTypesDef(<generated>) > at > org.apache.atlas.web.rest.TypesREST.createAtlasTypeDefs(TypesREST.java:399) > {code} > > -- This message was sent by Atlassian Jira (v8.20.10#820010)