cassandradatastax-astradsbulk

DSBulk CSV Load Failure to DataStax Astra Cassandra Database, missing file config.json


I am trying to load a csv into a database in DataStax Astra using the DSBulk tool.

Here is the command I ran minus the sensitive details:

dsbulk load -url D:\\App\\data.csv -k data -t data -b D:\\App\\secure-connect-myapp -u username -p password

Here is the error I get back:

Operation LOAD_20221206-004421-512000 failed: Invalid bundle: missing file config.json.

Here is the full log:

2022-12-06 00:44:21 INFO  Username and password provided but auth provider not specified, inferring PlainTextAuthProvider
2022-12-06 00:44:21 INFO  A cloud secure connect bundle was provided: ignoring all explicit contact points.
2022-12-06 00:44:21 INFO  A cloud secure connect bundle was provided and selected operation performs writes: changing default consistency level to LOCAL_QUORUM.
2022-12-06 00:44:21 INFO  Operation directory: C:\Program Files\dsbulk-1.10.0\bin\logs\LOAD_20221206-004421-512000
2022-12-06 00:44:21 ERROR Operation LOAD_20221206-004421-512000 failed: Invalid bundle: missing file config.json.
java.lang.IllegalStateException: Invalid bundle: missing file config.json
    at com.datastax.oss.driver.internal.core.config.cloud.CloudConfigFactory.createCloudConfig(CloudConfigFactory.java:114)
    at com.datastax.oss.driver.api.core.session.SessionBuilder.buildDefaultSessionAsync(SessionBuilder.java:876)
    at com.datastax.oss.driver.api.core.session.SessionBuilder.buildAsync(SessionBuilder.java:817)
    at com.datastax.oss.driver.api.core.session.SessionBuilder.build(SessionBuilder.java:835)
    at com.datastax.oss.dsbulk.workflow.commons.settings.DriverSettings.newSession(DriverSettings.java:560)
    at com.datastax.oss.dsbulk.workflow.load.LoadWorkflow.init(LoadWorkflow.java:145)
    at com.datastax.oss.dsbulk.runner.WorkflowThread.run(WorkflowThread.java:52)

The error says that config.json is missing, but it isn't. So I'm stuck. Unless it's looking somewhere other than in the bundle I specified, but the bundle definitely has the config.json file.


Solution

  • This error:

    ...
    java.lang.IllegalStateException: Invalid bundle: missing file config.json
        at com.datastax.oss.driver.internal.core.config.cloud.CloudConfigFactory.createCloudConfig(CloudConfigFactory.java:114)
        ...
    

    indicates that the Java driver bundled with DSBulk is unable to connect to your Astra DB because it couldn't get the configuration details from the secure connect bundle.

    Please make sure that the valid secure bundle ZIP is accessible to DSBulk. You need to provide the path to the ZIP file, not just the directory. For example:

    $ dsbulk ... -b /path/to/secure-connect-db.zip ...
    

    Please check the path in your command then try again. Cheers!


    👉 Please support the Apache Cassandra community by hovering over the cassandra tag above and click on Watch tag. 🙏 Thanks!