Closed srprasanna closed 1 year ago
Yesterday i have searched for the querry statement, read about that. But I need some clarifications about that for that I have sent msg to holash and Prasana but its not happened on today. @srprasanna need your help to understand the issue
@srprasanna @Renuka-S I have check the docker compose file , stopped the es service and and in application.yml file I have make keycloak authentication enabled=false and elastic_search_enabled=false whenever I run the registry logs in terminal there is some exception and error about es even es is not available, but when I tried to check with local there was no errors regarding es,I have not understood exactly what should I do for this issue. I have discussed with holash but not got exact way. @srprasanna please help me in this.
As per the dicussion with Sreejith my understanding:
When we set the following settings disabled es from docker comploe.yml file make keycloak_authentication =false providerName:NativeSearchService Elasticsearch_enabled=false ElasticSerach_auth_enabled=false in application.yml file
when we run the project on local and hit the api - http://localhost:8081/health it gives exception Caused by: java.lang.IllegalArgumentException: Username may not be null so I need to find that why this exception is occur
Today i have tried to solve IllegalArgumentException. in ElasticServiceImpl class I have add the condition that If Elasticsearch is disabled, the method createClient will return early without performing any Elasticsearch-related operations. but after adding that condition NullPointerException is occurring , trying to solve that
Today I have use some conditional annotations, now When the registry is started without authentication and elastic search is disabled, it not throws errors in the logs
PR Raised and shared link with holash, sharing PR link here https://github.com/Sunbird-RC/sunbird-rc-core/pull/244/files
recorded video of output -link -https://drive.google.com/file/d/1m2vR-J7mwbM06N8B_zYbFeGDOrerGTQe/view
Closing due to duplicate issue https://github.com/Sunbird-RC/community/issues/802
What is the bug related to?
Registry Core
What went wrong?
When the registry is started without authentication and elastic search is disabled, it throws errors in the logs. These errors give the wrong impression that the registry service isn't started. These should not be shown when starting the registry.
What did you expect to see?
Logs should not have errors in stacktrace when starting without Auth and ES.
Additional Context
No response
Relevant logs/output (if any)
No response