{"record":{"id":"35854afd9f6f7a38","repo":"apache/hadoop","slug":"dtfetcher-for-service-service-does-not-require","errorCode":null,"errorMessage":"DtFetcher for service '{service}' does not require a token.  Check your configuration.  Note: security may be disabled or there may be two DtFetcher providers for the same service designation.","messagePattern":"DtFetcher for service '(.+?)' does not require a token\\.  Check your configuration\\.  Note: security may be disabled or there may be two DtFetcher providers for the same service designation\\.","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/DtFileOperations.java","lineNumber":204,"sourceCode":"      try {\n        if (!iterator.hasNext()) {\n          break;\n        }\n        fetcher = iterator.next();\n      } catch (ServiceConfigurationError | LinkageError e) {\n        // failure to load a token implementation\n        // log at debug and continue.\n        LOG.debug(\"Failed to load token fetcher implementation\", e);\n        continue;\n      }\n      if (matchService(fetcher, service, url)) {\n        if (!fetcher.isTokenRequired()) {\n          String message = \"DtFetcher for service '\" + service +\n              \"' does not require a token.  Check your configuration.  \" +\n              \"Note: security may be disabled or there may be two DtFetcher \" +\n              \"providers for the same service designation.\";\n          LOG.error(message);\n          throw new IllegalArgumentException(message);\n        }\n        token = fetcher.addDelegationTokens(conf, creds, renewer,\n                                            stripPrefix(url));\n      }\n    }\n    if (alias != null) {\n      if (token == null) {\n        String message = \"DtFetcher for service '\" + service + \"'\" +\n            \" does not allow aliasing.  Cannot apply alias '\" + alias + \"'.\" +\n            \"  Drop alias flag to get token for this service.\";\n        LOG.error(message);\n        throw new IOException(message);\n      }\n      Token<?> aliasedToken = token.copyToken();\n      aliasedToken.setService(alias);\n      creds.addToken(alias, aliasedToken);\n      LOG.info(\"Add token with service \" + alias);\n    }","sourceCodeStart":186,"sourceCodeEnd":222,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/DtFileOperations.java#L186-L222","documentation":"Error \"DtFetcher for service '{service}' does not require a token.  Check your configuration.  Note: security may be disabled or there may be two DtFetcher providers for the same service designation.\" thrown in apache/hadoop.","triggerScenarios":"Thrown at hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/DtFileOperations.java:204 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Configure a DtFetcher that returns a token for service '{service}'; the current fetcher reports no token is needed, which usually means security is disabled (hadoop.security.authentication=simple) or two DtFetcher providers are registered for the same service name.","Enable Kerberos security (hadoop.security.authentication=kerberos) if a delegation token is actually required, or remove the duplicate DtFetcher registration for the service."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-23T01:17:44.959Z"}