# Identity Service Developers Guide

**URL:** <https://community.mosip.io/t/identity-service-developers-guide/807>\
**Category:** Developer\
**Created:** [September 28, 2023, 9:27am UTC](https://community.mosip.io/t/identity-service-developers-guide/807 "2023-09-28T09:27:56Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [September 28, 2023, 9:27am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/1 "2023-09-28T09:27:57Z")

</div>

Hi, I try to clone id repo and run your source code. I follow all step in Identity Service Developers Guide. and this error shows up  
{“@timestamp”:“2023-09-28T16:13:12.216+07:00”,“@version”:“1”,“message”:“Failed to clear soft references from ObjectStreamClass$Caches for web application [ROOT]”,“logger\_name”:“org.apache.catalina.loader.WebappClassLoaderBase”,“thread\_name”:“localhost-startStop-1”,“level”:“WARN”,“level\_value”:30000,“stack\_trace”:“java.lang.ClassCastException: class java.io.ObjectStreamClass$Caches$1 cannot be cast to class java.util.Map (java.io.ObjectStreamClass$Caches$1 and java.util.Map are in module java.base of loader ‘bootstrap’)\n\tat org.apache.catalina.loader.WebappClassLoaderBase.clearCache(WebappClassLoaderBase.java:2244)\n\tat org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesObjectStreamClassCaches(WebappClassLoaderBase.java:2231)\n\tat org.apache.catalina.loader.WebappClassLoaderBase.clearReferences(WebappClassLoaderBase.java:1603)\n\tat org.apache.catalina.loader.WebappClassLoaderBase.stop(WebappClassLoaderBase.java:1548)\n\tat org.apache.catalina.loader.WebappLoader.stopInternal(WebappLoader.java:452)\n\tat org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:257)\n\tat org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5437)\n\tat org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:257)\n\tat org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1428)\n\tat org.apache.catalina.core.ContainerBase$StopChild.call(ContainerBase.java:1417)\n\tat java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)\n\tat java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)\n\tat java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)\n\tat java.base/java.lang.Thread.run(Thread.java:829)\n”,“appName”:“id-repository”}

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [September 28, 2023, 10:00am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/2 "2023-09-28T10:00:25Z")

</div>

mvn install errors

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/mosip1/original/1X/6cd8e10f239a5ea341bdc94a134d56e2e5effc96.png)

---

<div class="post-metadata">

**Author:** ![sanchi-singh24](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/sanchi-singh24/32/538_2.png) [@sanchi-singh24](https://community.mosip.io/u/sanchi-singh24)\
**Post date:** [September 29, 2023, 10:22am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/3 "2023-09-29T10:22:30Z")

</div>

Hi @mengleang-ngoun

Let me go through the error logs and see why this ID repo is showing this error.

@mahammedtaheer can you look into this and provide your guidance.

Best Regards,  
Team MOSIP

---

<div class="post-metadata">

**Author:** ![mahammedtaheer](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mahammedtaheer/32/90_2.png) [@mahammedtaheer](https://community.mosip.io/u/mahammedtaheer)\
**Post date:** [September 29, 2023, 1:13pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/4 "2023-09-29T13:13:28Z")

</div>

Hi @mengleang-ngoun

Please add the below repository in pom.xml file for info.weboftrust jar file.

```auto
          <repository>
			<id>danubetech-maven-public</id>
			<url>https://repo.danubetech.com/repository/maven-public/</url>
		  </repository>

```

Thanks

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [September 30, 2023, 9:38am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/5 "2023-09-30T09:38:30Z")

</div>

Thank @mahammedtaheer and @sanchi-singh24

problem with Maven solved but I have one more issue with the start identity service. it gives me this log

{“@timestamp”:“2023-09-30T16:34:08.878+07:00”,“@version”:“1”,“message”:“\n\n\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\nAPPLICATION FAILED TO START\n\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\n\nDescription:\n\nParameter 0 of method securityManagerWithAuth in io.mosip.idrepository.identity.config.IdRepoConfig required a bean of type ‘org.springframework.web.reactive.function.client.WebClient’ that could not be found.\n\n\nAction:\n\nConsider defining a bean of type ‘org.springframework.web.reactive.function.client.WebClient’ in your configuration.\n”,“logger\_name”:“org.springframework.boot.diagnostics.LoggingFailureAnalysisReporter”,“thread\_name”:“main”,“level”:“ERROR”,“level\_value”:40000,“appName”:“id-repository”}

currently, we running now version 1.2.0.1-SNAPSHOT id-repo

Best Regards

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 2, 2023, 7:50am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/6 "2023-10-02T07:50:25Z")

</div>

got this error when try running identity service in id repo module

“message”:“Error starting Tomcat context. Exception: org.springframework.beans.factory.UnsatisfiedDependencyException. Message: Error creating bean with name ‘securityConfig’: Unsatisfied dependency expressed through method ‘setContentNegotationStrategy’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration’: Unsatisfied dependency expressed through method ‘setConfigurers’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘idRepoConfig’: Unsatisfied dependency expressed through field ‘interceptor’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘idRepoEntityInterceptor’: Unsatisfied dependency expressed through field ‘securityManager’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘securityManagerWithAuth’ defined in class path resource [io/mosip/idrepository/identity/config/IdRepoConfig.class]: Unsatisfied dependency expressed through method ‘securityManagerWithAuth’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘selfTokenWebClient’ defined in class path resource [io/mosip/kernel/auth/defaultadapter/config/BeanConfig.class]: Unsatisfied dependency expressed through method ‘selfTokenWebClient’ parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘plainWebClient’ defined in class path resource [io/mosip/kernel/auth/defaultadapter/config/BeanConfig.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.web.reactive.function.client.WebClient]: Factory method ‘plainWebClient’ threw exception; nested exception is java.lang.NoSuchMethodError: ‘java.lang.Throwable io.netty.util.internal.ReflectionUtil.trySetAccessible(java.lang.reflect.AccessibleObject)’”,

Thank

---

<div class="post-metadata">

**Author:** ![mahammedtaheer](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mahammedtaheer/32/90_2.png) [@mahammedtaheer](https://community.mosip.io/u/mahammedtaheer)\
**Post date:** [October 3, 2023, 2:00pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/7 "2023-10-03T14:00:03Z")

</div>

Hi @mengleang-ngoun

During start of application it is expected to add auth-adapter jar file in the classpath. The auth-adapter jar file should be downloadable from the artifactory.  
Because of non availability of this jar file in classpath, its throwing ‘selfTokenWebClient’ & ‘plainWebClient’ bean not available error.

Please add the jar file in the artifactory and download the jar file from artifactory in the classpath to resolve the issue.

Thanks,

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 3, 2023, 2:58pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/8 "2023-10-03T14:58:06Z")

</div>

Thank @mahammedtaheer and MOSIP team

we don’t run artifactory module parallelly for id repo to get kernel-auth-adapter. currently, we download it from [https://oss.sonatype.org/](https://oss.sonatype.org/) at version v1.2.0.1-B1 and import it into the service module as a library. Based on your commendation above do we need to artifactory to id repo get a kernel-auth-adapter? Or am I missing some point in configuration on IDE to start this module?

Thanks

---

<div class="post-metadata">

**Author:** ![mahammedtaheer](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mahammedtaheer/32/90_2.png) [@mahammedtaheer](https://community.mosip.io/u/mahammedtaheer)\
**Post date:** [October 3, 2023, 4:09pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/9 "2023-10-03T16:09:29Z")

</div>

Hi @mengleang-ngoun

If you are trying to run the id-repo through IDE, no need to configure artifactory. As you mentioned, kernel-auth-adapter is added as service module check why the jar is not getting loaded in the classpath.

Which IDE are you using? and how are you import the jar file into service module as a library.

Thanks

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 3, 2023, 4:25pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/10 "2023-10-03T16:25:35Z")

</div>

Hi @mahammedtaheer

I use Intellij and I import the jar file by project setting \> libraries \> click on + and add jar file. and I choose to add on mosip-id-repository service

Thanks

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 6, 2023, 4:16am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/11 "2023-10-06T04:16:45Z")

</div>

Hello @mahammedtaheer,

I still have a problem with that. Is it possible to record the video you set up in this module?

Thank

---

<div class="post-metadata">

**Author:** ![mahammedtaheer](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mahammedtaheer/32/90_2.png) [@mahammedtaheer](https://community.mosip.io/u/mahammedtaheer)\
**Post date:** [October 6, 2023, 2:18pm UTC](https://community.mosip.io/t/identity-service-developers-guide/807/12 "2023-10-06T14:18:54Z")

</div>

Hi @mengleang-ngoun

Instead of adding in libraries under “Project Setting” try adding it in module and select specific module where you want the auth-adapter to be available in classpath.

Refer the attached image where the jar file is added to specific module (vci-service-impl module)

 ![intelij](https://europe1.discourse-cdn.com/flex017/uploads/mosip1/original/1X/275a2d488fe405af8f8a9465e6e4a55f2bdbaab2.jpeg)

Thanks

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 9, 2023, 2:43am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/13 "2023-10-09T02:43:55Z")

</div>

Thank @mahammedtaheer

I tried to import jar to the module like you did. but the problem still occurs.

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/mosip1/original/1X/55f78f03511ca515f77f01945490e3dc0582f13f.png)

**logs:**  
{“@timestamp”:“2023-10-09T09:41:18.649+07:00”,“@version”:“1”,“message”:“Error starting Tomcat context. Exception: org.springframework.beans.factory.UnsatisfiedDependencyException. Message: Error creating bean with name ‘securityConfig’: Unsatisfied dependency expressed through method ‘setContentNegotationStrategy’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration’: Unsatisfied dependency expressed through method ‘setConfigurers’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘idRepoConfig’: Unsatisfied dependency expressed through field ‘interceptor’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘idRepoEntityInterceptor’: Unsatisfied dependency expressed through field ‘securityManager’; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘securityManagerWithAuth’ defined in class path resource [io/mosip/idrepository/identity/config/IdRepoConfig.class]: Unsatisfied dependency expressed through method ‘securityManagerWithAuth’ parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘selfTokenWebClient’ defined in class path resource [io/mosip/kernel/auth/defaultadapter/config/BeanConfig.class]: Unsatisfied dependency expressed through method ‘selfTokenWebClient’ parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘plainWebClient’ defined in class path resource [io/mosip/kernel/auth/defaultadapter/config/BeanConfig.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.web.reactive.function.client.WebClient]: Factory method ‘plainWebClient’ threw exception; nested exception is java.lang.NoSuchMethodError: ‘java.lang.Throwable io.netty.util.internal.ReflectionUtil.trySetAccessible(java.lang.reflect.AccessibleObject)’”,“logger\_name”:“org.springframework.boot.web.embedded.tomcat.TomcatStarter”,“thread\_name”:“localhost-startStop-1”,“level”:“ERROR”,“level\_value”:40000,“appName”:“id-repository”}

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 10, 2023, 9:23am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/14 "2023-10-10T09:23:08Z")

</div>

Thank @mahammedtaheer

Now it’s running

---

<div class="post-metadata">

**Author:** ![mengleang-ngoun](https://dub1.discourse-cdn.com/flex017/user_avatar/community.mosip.io/mengleang-ngoun/32/568_2.png) [@mengleang-ngoun](https://community.mosip.io/u/mengleang-ngoun)\
**Post date:** [October 10, 2023, 11:40am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/15 "2023-10-10T11:40:35Z")

</div>

I have one more question. I tried to add a new identity in id repo identity service but it required to have authorize to do it. In development, Dose it required to connect with keycloak as IAM to get authorization, or does it have another way to disable connect to IAM for development stage?

Thanks

---

<div class="post-metadata">

**Author:** ![gsasikumar](https://avatars.discourse-cdn.com/v4/letter/g/b782af/32.png) [@gsasikumar](https://community.mosip.io/u/gsasikumar)\
**Post date:** [October 10, 2023, 11:40am UTC](https://community.mosip.io/t/identity-service-developers-guide/807/16 "2023-10-10T11:40:48Z")

</div>


