{"record":{"id":"8c0317eeb9e5bbf5","repo":"apache/cassandra","slug":"is-deprecated-and-not-actively-maintained-it-w","errorCode":null,"errorMessage":"{} is deprecated and not actively maintained. It will be removed in the next major version of Cassandra.","messagePattern":"(.+?) is deprecated and not actively maintained\\. It will be removed in the next major version of Cassandra\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/java/org/apache/cassandra/locator/CloudstackLocationProvider.java","lineNumber":67,"sourceCode":"    };\n\n    /**\n     * Used via reflection by DatabaseDescriptor::createInitialLocationProvider\n     */\n    public CloudstackLocationProvider() throws IOException\n    {\n        this(new SnitchProperties(new Properties()));\n    }\n\n    public CloudstackLocationProvider(SnitchProperties snitchProperties) throws IOException\n    {\n        this(new DefaultCloudMetadataServiceConnector(snitchProperties.putIfAbsent(METADATA_URL_PROPERTY, csMetadataEndpoint())));\n    }\n\n    public CloudstackLocationProvider(AbstractCloudMetadataServiceConnector connector) throws IOException\n    {\n        super(connector, CloudstackLocationProvider::resolveLocation);\n        logger.warn(\"{} is deprecated and not actively maintained. It will be removed in the next \" +\n                    \"major version of Cassandra.\", CloudstackSnitch.class.getName());\n    }\n\n    private static Location resolveLocation(AbstractCloudMetadataServiceConnector connector) throws IOException\n    {\n        String zone = connector.apiCall(ZONE_NAME_QUERY_URI);\n        String[] zoneParts = zone.split(\"-\");\n\n        if (zoneParts.length != 3)\n            throw new ConfigurationException(\"CloudstackSnitch cannot handle invalid zone format: \" + zone);\n\n        return new Location(zoneParts[0] + '-' + zoneParts[1], zoneParts[2]);\n    }\n\n    private static String csMetadataEndpoint() throws ConfigurationException\n    {\n        for (String lease_uri : LEASE_FILES)\n        {","sourceCodeStart":49,"sourceCodeEnd":85,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/locator/CloudstackLocationProvider.java#L49-L85","documentation":"Constructing a CloudstackLocationProvider logs this warning because the Cloudstack snitch/location-provider is deprecated and will be removed in the next major Cassandra version. Nothing failed; the constructor deliberately warns so operators notice before an upgrade removes the class.","triggerScenarios":"Creating CloudstackLocationProvider directly, or indirectly via any CloudstackSnitch constructor (endpoint_snitch loaded from cassandra.yaml, or programmatic instantiation).","commonSituations":"cassandra.yaml still sets endpoint_snitch: CloudstackSnitch on clusters deployed in Apache Cloudstack; inherited configs after upgrading Cassandra where the snitch was never migrated.","solutions":["Migrate to a supported snitch, e.g. GossipingPropertyFileSnitch/PropertyFileSnitch with explicit DC/Rack definitions.","Replace endpoint_snitch in cassandra.yaml before the next major upgrade.","Remove references to the deprecated provider from tooling and scripts.","Plan the snitch change during a rolling restart window since it affects replica placement."],"exampleFix":"// before (cassandra.yaml)\nendpoint_snitch: CloudstackSnitch\n// after\nendpoint_snitch: GossipingPropertyFileSnitch  # with cassandra-rackdc.properties defining dc/rack","handlingStrategy":"validation","validationCode":"# check cassandra.yaml before deploy\ngrep -q 'Cloudstack' conf/cassandra.yaml && echo 'deprecated snitch configured' && exit 1","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Audit cassandra.yaml for deprecated snitch classes before each major upgrade.","Migrate to GossipingPropertyFileSnitch/PropertyFileSnitch with explicit dc/rack.","Subscribe to Cassandra upgrade notes listing removed classes.","Test snitch changes in staging with nodetool ring verification."],"tags":["deprecation","snitch","configuration"],"backgroundTag":"deprecated-api-usage","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"}