[ 
https://issues.apache.org/jira/browse/ATLAS-5423?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

SONALI SAKSENA updated ATLAS-5423:
----------------------------------
    Description: 
*Description:*

If an invalid or unknown {{typeName}} is encountered during notification 
processing, we should validate it upfront and throw an exception before 
processing the notification. This would prevent the notification from being 
processed, failing later, and being unnecessarily retried.

*Logs:*
 
 {{2026-09-24 06:27:31,201 [NotificationHookConsumer thread-0] INFO 
[NotificationHookConsumer.java:585] Message type: 
ENTITY_PARTIAL_UPDATE_V22026-09-24 06:27:31,203 [NotificationHookConsumer 
thread-0] INFO [GraphTransactionAdvisor.java:43] GraphTransaction intercept for 
org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2.updateEntity2026-09-24
 06:27:31,203 [NotificationHookConsumer thread-0] ERROR 
[GraphTransactionInterceptor.java:280] graph rollback due to 
exceptionorg.apache.atlas.exception.AtlasBaseException: trino_table: 
Unknown/invalid typename        at 
org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2.updateEntity(AtlasEntityStoreV2.java:366)
        at 
org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2$$FastClassBySpringCGLIB$$6861dca9.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:190)
        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.AtlasEntityStoreV2$$EnhancerBySpringCGLIB$$a46f3b8f.updateEntity(<generated>)
        at 
org.apache.atlas.notification.SerialEntityProcessor.handleMessage(SerialEntityProcessor.java:584)
        at 
org.apache.atlas.notification.SerialEntityProcessor.handleMessage(SerialEntityProcessor.java:324)
        at 
org.apache.atlas.notification.NotificationHookConsumer$HookConsumer.handleMessage(NotificationHookConsumer.java:587)
        at 
org.apache.atlas.notification.NotificationHookConsumer$HookConsumer.run(NotificationHookConsumer.java:501)
        at 
java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)   
     at 
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
        at 
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
        at java.base/java.lang.Thread.run(Thread.java:840) }}

  was:
We created a hive_table entity in Apache Atlas with the following details:
 * name: A string with 370 characters.
 * qualifiedName: In the format default.<entity_name>@primary, where 
<entity_name> is the same 370-character string.

Despite the entity being successfully created and visible through direct entity 
retrieval, *basic search queries using attribute filters on* *qualifiedName* 
*are not returning results* when using an AND condition with the following 
filters:
 # qualifiedName *starts with* default.<entity_name>
 # qualifiedName *ends with* @primary

 

*Observation:*
The search query returns an empty result list for the specified entities.

 

*Expected Outcome:*
The search should return a list of Hive table entities matching the query.

 

*Steps to Reproduce:*
 # Create an entity with a long name and corresponding qualified name using the 
following curl command:
{code:java}
curl --location --request POST 'http://localhost:21000/api/atlas/v2/entity' \
-u <username>:<password> \
--header 'Content-Type: application/json' \
--data-raw '{
    "entity": {
        "typeName": "hive_table",
        "attributes": {
            "aliases": [],
            "comment": null,
            "createTime": "1669974016149",
            "description": "entity_370",
            "displayName": null,
            "lastAccessTime": 1234567890999,
            "name": 
"name370oootphvx6vovxzedvv0sjaivlmn0b9pdkdd8lbctngkptfxv5yibzaffjtr7aa7n8cnlqcnamcxhsul8vxx6spcwoy5l6bmov44r8ympwm3hidmrztzcgvgyyuhi4h6egtanqb7t1aws0aodvpd3bqvl5ji1frfsznupfw4uqrsrdfdcy39hetlhq3aan8ogzr3nshgnpurskhkzvt8xov12yplobpfqble2b1zsq2gz1s5vliud1fihec4i2euiuqwiuyiyiwyeiuewawdsedvkjsljh234jh23k4h2j3h4k234hj23h4hj2h3j4j2h34kjkjh23k4jhk23k23jh4kh234kj32h4j32jh4j3a",
            "owner": "dev",
            "parameters": null,
            "qualifiedName": 
"default.name370oootphvx6vovxzedvv0sjaivlmn0b9pdkdd8lbctngkptfxv5yibzaffjtr7aa7n8cnlqcnamcxhsul8vxx6spcwoy5l6bmov44r8ympwm3hidmrztzcgvgyyuhi4h6egtanqb7t1aws0aodvpd3bqvl5ji1frfsznupfw4uqrsrdfdcy39hetlhq3aan8ogzr3nshgnpurskhkzvt8xov12yplobpfqble2b1zsq2gz1s5vliud1fihec4i2euiuqwiuyiyiwyeiuewawdsedvkjsljh234jh23k4h2j3h4k234hj23h4hj2h3j4j2h34kjkjh23k4jhk23k23jh4kh234kj32h4j32jh4j3a@primary",
            "replicatedFrom": [],
            "replicatedTo": [],
            "retention": null,
            "tableType": null,
            "temporary": null,
            "userDescription": null,
            "viewExpandedText": null,
            "viewOriginalText": null
        }
 
    },
    "referredEntities": {}
}'{code}

 # Perform a basic search using attribute filters:
 ## qualifiedName starts with default.<370_char_string>
 ## qualifiedName ends with @primary 

Curl Request:
{code:java}
curl 'http://localhost:21000/api/atlas/v2/search/basic' \
-u <username>:<password> \
--header 'Content-Type: application/json' \
--data-raw '{
    "excludeDeletedEntities": true,
    "includeSubClassifications": true,
    "includeSubTypes": true,
    "includeClassificationAttributes": true,
    "entityFilters": {
        "condition": "AND",
        "criterion": [
            {
                "attributeName": "qualifiedName",
                "operator": "startsWith",
                "attributeValue": 
"default.name370oootphvx6vovxzedvv0sjaivlmn0b9pdkdd8lbctngkptfxv5yibzaffjtr7aa7n8cnlqcnamcxhsul8vxx6spcwoy5l6bmov44r8ympwm3hidmrztzcgvgyyuhi4h6egtanqb7t1aws0aodvpd3bqvl5ji1frfsznupfw4uqrsrdfdcy39hetlhq3aan8ogzr3nshgnpurskhkzvt8xov12yplobpfqble2b1zsq2gz1s5vliud1fihec4i2euiuqwiuyiyiwyeiuewawdsedvkjsljh234jh23k4h2j3h4k234hj23h4hj2h3j4j2h34kjkjh23k4jhk23k23jh4kh234kj32h4j32jh4j3a"
            },
            {
                "attributeName": "qualifiedName",
                "operator": "endsWith",
                "attributeValue": "@primary"
            }
        ]
    },
    "tagFilters": null,
    "attributes": [
        "qualifiedName"
    ],
    "limit": 25,
    "offset": 0,
    "typeName": "hive_table",
    "classification": null,
    "termName": null
}'{code}

 


> Incase of Unknown/invalid typename, notifications should not be retried
> -----------------------------------------------------------------------
>
>                 Key: ATLAS-5423
>                 URL: https://issues.apache.org/jira/browse/ATLAS-5423
>             Project: Atlas
>          Issue Type: Bug
>            Reporter: SONALI SAKSENA
>            Assignee: SONALI SAKSENA
>            Priority: Major
>             Fix For: 3.0.0, 2.6.0
>
>
> *Description:*
> If an invalid or unknown {{typeName}} is encountered during notification 
> processing, we should validate it upfront and throw an exception before 
> processing the notification. This would prevent the notification from being 
> processed, failing later, and being unnecessarily retried.
> *Logs:*
>  
>  {{2026-09-24 06:27:31,201 [NotificationHookConsumer thread-0] INFO 
> [NotificationHookConsumer.java:585] Message type: 
> ENTITY_PARTIAL_UPDATE_V22026-09-24 06:27:31,203 [NotificationHookConsumer 
> thread-0] INFO [GraphTransactionAdvisor.java:43] GraphTransaction intercept 
> for 
> org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2.updateEntity2026-09-24
>  06:27:31,203 [NotificationHookConsumer thread-0] ERROR 
> [GraphTransactionInterceptor.java:280] graph rollback due to 
> exceptionorg.apache.atlas.exception.AtlasBaseException: trino_table: 
> Unknown/invalid typename        at 
> org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2.updateEntity(AtlasEntityStoreV2.java:366)
>         at 
> org.apache.atlas.repository.store.graph.v2.AtlasEntityStoreV2$$FastClassBySpringCGLIB$$6861dca9.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:190)
>         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.AtlasEntityStoreV2$$EnhancerBySpringCGLIB$$a46f3b8f.updateEntity(<generated>)
>         at 
> org.apache.atlas.notification.SerialEntityProcessor.handleMessage(SerialEntityProcessor.java:584)
>         at 
> org.apache.atlas.notification.SerialEntityProcessor.handleMessage(SerialEntityProcessor.java:324)
>         at 
> org.apache.atlas.notification.NotificationHookConsumer$HookConsumer.handleMessage(NotificationHookConsumer.java:587)
>         at 
> org.apache.atlas.notification.NotificationHookConsumer$HookConsumer.run(NotificationHookConsumer.java:501)
>         at 
> java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
>         at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) 
>        at 
> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
>         at 
> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
>         at java.base/java.lang.Thread.run(Thread.java:840) }}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to