{"record":{"id":"c1c64204dc39ae33","repo":"apache/cassandra","slug":"error-while-getting-seed-node-list","errorCode":null,"errorMessage":"Error while getting seed node list: {}","messagePattern":"Error while getting seed node list: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/java/org/apache/cassandra/gms/Gossiper.java","lineNumber":1823,"sourceCode":"\n        // Get the new set in the same that buildSeedsList does\n        Set<InetAddressAndPort> tmp = new HashSet<>();\n        try\n        {\n            for (InetAddressAndPort seed : DatabaseDescriptor.getSeeds())\n            {\n                if (seed.equals(getBroadcastAddressAndPort()))\n                    continue;\n                tmp.add(seed);\n            }\n        }\n        // If using the SimpleSeedProvider invalid yaml added to the config since startup could\n        // cause this to throw. Additionally, third party seed providers may throw exceptions.\n        // Handle the error and return a null to indicate that there was a problem.\n        catch (Throwable e)\n        {\n            JVMStabilityInspector.inspectThrowable(e);\n            logger.warn(\"Error while getting seed node list: {}\", e.getLocalizedMessage());\n            return null;\n        }\n\n        if (tmp.size() == 0)\n        {\n            logger.trace(\"New seed node list is empty. Not updating seed list.\");\n            return getSeeds();\n        }\n\n        if (tmp.equals(seeds))\n        {\n            logger.trace(\"New seed node list matches the existing list.\");\n            return getSeeds();\n        }\n\n        // Add the new entries\n        seeds.addAll(tmp);\n        // Remove the old entries","sourceCodeStart":1805,"sourceCodeEnd":1841,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/gms/Gossiper.java#L1805-L1841","documentation":"Gossiper periodically refreshes its seed list from the configured SeedProvider. If the provider throws (e.g., SimpleSeedProvider given invalid YAML, or a third-party provider failing), the code inspects the throwable for JVM stability and logs this warning, returning null to signal the refresh failed rather than crashing gossip.","triggerScenarios":"seed_provider implementation throws during getSeeds() when the periodic seed-list refresh runs — typically after cassandra.yaml was modified or a dynamic provider had a transient failure.","commonSituations":"Hand-edited cassandra.yaml with malformed seed entries reloaded at runtime; third-party seed providers (cloud metadata based) hitting network/auth failures; type mismatch in seed config values.","solutions":["Validate cassandra.yaml seed_provider syntax; fix invalid entries and restart.","Check the third-party seed provider's connectivity/credentials if a dynamic provider is used.","Inspect the accompanying exception message in the log to identify the exact provider failure.","Revert a recent seed config change and re-apply it correctly."],"exampleFix":"# before (cassandra.yaml)\nseed_provider:\n  - class_name: SimpleSeedProvider\n    parameters:\n      - seeds: 10.0.0.1 10.0.0.2   # malformed separator\n# after\nseed_provider:\n  - class_name: SimpleSeedProvider\n    parameters:\n      - seeds: \"10.0.0.1,10.0.0.2\"","handlingStrategy":"try-catch","validationCode":"// validate seed config at deploy time\nConfig config = DatabaseDescriptor.loadConfig();\nif (config.seed_provider == null || config.seed_provider.parameters.isEmpty()) throw new ConfigurationException(\"seed_provider misconfigured\");","typeGuard":null,"tryCatchPattern":"try { seeds = seedProvider.getSeeds(); } catch (Throwable t) { JVMStabilityInspector.inspectThrowable(t); logger.warn(\"seed list refresh failed\", t); }","preventionTips":["Lint/validate cassandra.yaml in CI before rollout.","Test third-party seed providers' auth/network from the node.","Keep SimpleSeedProvider entries comma-separated and quoted."],"tags":["cassandra","gossip","seeds","configuration","seed-provider"],"backgroundTag":"invalid-config-value","analyzedSha":"88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1","analyzedAt":"2026-09-10T07:29:22.284Z","contentChangedAt":"2026-09-10T07:29:22.284Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}