Uploaded image for project: 'mod-search'
  1. mod-search
  2. MSEARCH-252

ApiException throws an error in mod search when installing modules



    • Falcon Sprint 129, Falcon Sprint 130
    • 2
    • Falcon


      When we run karate tests in the data-import, mod-data-export and mod-search modules, we get this error:

      POST request for mod-search-1.6.0-SNAPSHOT.162 /_/tenant failed with 500:{"errors":[ {"message":"[404 Not Found] during [GET] to http://perms/users/b8727404-7f90-439f-a895-1b3d68c573aa/permissions?indexField=userId PermissionsClient#getUserPermissions(String): [No user found by userId b8727404-7f90-439f-a895-1b3d68c573aa]","type":"NotFound","code":"unknown_error"}],"total_records":1}

      You can see more details in the attached test.log file.

      After studying the problem in more detail, I came to the conclusion that the mod-auth token throws the current exception:
      ERROR MainVerticle   Unsupported JWT format
      INFO  DockerModuleHandle   mod-authtoken-2.10.0-SNAPSHOT.95 org.folio.auth.authtokenmodule.BadSignatureException: Could not verify token eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJkaWt1X2FkbWluIiwidXNlcl9pZCI6IjAxZDQxOWExLTdkNjgtNWVhNi1hNWJjLWQwN2JhNTE1MTIyMiIsImlhdCI6MTYzODI3MDgxOSwidGVuYW50IjoiZGlrdSJ9.xmfa-0r3BsephpKY0MXUrrTMnpycPg5qw7ah-Ri61R4
      More details in the attached okapi.log file.
      All modules are deployed without problems except mod-search, after looking at the logs I noticed that the module cannot correctly handle the error associated with Unsupported JWT format:
      WARN  org.folio.search.controller.ApiExceptionHandler - Handling exception
      feign.FeignException$NotFound: [404 Not Found] during [GET] to http://perms/users/908981a4-8f01-4b3f-9988-9f23106b5c7f/permissions?indexField=userId PermissionsClient#getUserPermissions(String): [No user found by userId 908981a4-8f01-4b3f-9988-9f23106b5c7f]
          at feign.FeignException.clientErrorStatus(FeignException.java:201) ~[feign-core-10.10.1.jar!/:?]
          at feign.FeignException.errorStatus(FeignException.java:177) ~[feign-core-10.10.1.jar!/:?]
          at feign.FeignException.errorStatus(FeignException.java:169) ~[feign-core-10.10.1.jar!/:?]
          at feign.codec.ErrorDecoder$Default.decode(ErrorDecoder.java:92) ~[feign-core-10.10.1.jar!/:?]
      More details in the attached mod-search.log file.
      At the moment, three test modules related to mod-search (data-import, mod-data-export, mod-search) do not work. data-import and mod-data-export do not deploy mod-search directly, but when you try to deploy the mod-data-export required module, the modules are also lifted (mod-search is enabled in the Module Descriptor for the specified one).

      TestRail: Results


          1. mod-search.log
            1.15 MB
          2. okapi.log
            19.67 MB
          3. test.log
            217 kB

          Issue Links



                pavel_filippov Pavel Filippov
                Miami20 Khamidulla Abdulkhakimov
                0 Vote for this issue
                8 Start watching this issue



                  TestRail: Runs

                    TestRail: Cases