[ 
https://issues.apache.org/jira/browse/HDDS-10390?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17886312#comment-17886312
 ] 

Ivan Andika edited comment on HDDS-10390 at 10/2/24 8:41 AM:
-------------------------------------------------------------

h2. "NoInitialContextException" Root Cause Analysis

The issue can be identified by debugging the flow between running S3G from 
Intellij and integration test.

Both flows will call BeforeBeanDiscoveryImpl#fire in 
WeldStartup#startInitialization, but only the S3G called in integration test 
fails. Following the flow of the code, it will invoke Weld's 
ObserverNotifier#fireEvent method. This method calls resolveObserverMethods 
which returns the observers to invoke in response to the BeforeBeanDiscovery 
(using @Observes annotation). Only S3G ran from integration test will return 
CDIExtension as one of them which will throw the NotInitialContextException.
h2. Solution

The NoInitialContextException issue can be resolved by excluding jersey-servlet 
from hadoop-kms and hadoop-mapreduce-client-jobclient dependencies in 
ozone-integration-test. This will exclude CDIExtension as the observers for the 
BeforeBeanDiscovery and the exception will not be thrown.


was (Author: JIRAUSER298977):
h2. "NoInitialContextException" Root Cause Analysis

The issue can be identified by debugging the flow between running S3G from 
Intellij and integration test.

Both flows will call BeforeBeanDiscoveryImpl#fire in 
WeldStartup#startInitialization, but only the S3G called in integration test 
fails. Following the flow of the code, it will invoke Weld's 
ObserverNotifier#fireEvent method. This method calls resolveObserverMethods 
which returns the observers to invoke in response to the BeforeBeanDiscovery 
(using @Observes annotation). Only S3G ran from integration test will return 
CDIExtension as one of them which will throw the NotInitialContextException.
h2. Solution

The NoInitialContextException issue can be resolved by excluding jersey-servlet 
from hadoop-kms and hadoop-mapreduce-client-jobclient dependencies in 
ozone-integration-test. This will exclude CDIExtension as the observers for the 
BeforeBeanDiscovery and the exception will not be thrown.

 

> MiniOzoneCluster to support S3G
> -------------------------------
>
>                 Key: HDDS-10390
>                 URL: https://issues.apache.org/jira/browse/HDDS-10390
>             Project: Apache Ozone
>          Issue Type: Improvement
>            Reporter: Duong
>            Assignee: Ivan Andika
>            Priority: Major
>              Labels: S3
>
> MiniOzoneCluster should support creating S3G instances and provide access to 
> S3G via an AWS S3 client (AWS Java SDK).
> This will make it a lot easier to test and debug issues in S3G.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to