Working with Embedded Cassandra Database

The embedded Cassandra service used by the Iotellect server is sufficient for a wide range of use cases, but exceptionally large or specialized systems may require unique database configurations.

Cassandra Configuration Model in Embedded Mode

Embedded Cassandra uses a configuration model that is different from an external Cassandra deployment. In embedded mode, all active configuration parameters are taken exclusively from the Iotellect Server server configuration file (server.xml).
The bundled cassandra.yaml file is used only as an internal template and must not be edited.

How Parameters Are Resolved

When embedded mode is enabled:

  • Iotellect Server reads Cassandra-related settings only from the databaseCassandra* parameters in server.xml.

  • Network, storage, cluster name, ports, and memory settings are all inherited from server.xml.

  • Any user modifications to cassandra.yaml are ignored by the embedded server process.

Why Editing cassandra.yaml Is Not Allowed

The embedded Cassandra engine is tightly integrated with Iotellect Server lifecycle management.
Changing the cassandra.yaml file may cause:

  • inconsistent node identity

  • incorrect network binding

  • failed startup

  • cluster membership issues

  • data file schema mismatches

Therefore, only the configuration exposed in server.xml must be used to manage embedded Cassandra.

Summary

Deployment mode

Active configuration

Ignored configuration

Embedded Cassandra

server.xml (databaseCassandra* parameters)

cassandra.yaml (read-only template)

This ensures consistent node behavior and reliable operation of the embedded database service.

Enabling Log Output to External File

In order to output embedded Cassandra logs to an external file:

  1. Open the logging configuration file, which is typically logging.xml in the root directory of your Iotellect installation.

  2. In the <Loggers>...</Loggers> section, remove the following lines:

    <Logger name="org.apache.cassandra.cql3.QueryProcessor" level="off"/>
    <Logger name="org.apache.cassandra.db.Memtable" level="off"/>
    <Logger name="org.apache.cassandra.io.sstable.SSTableDeletingTask" level="off"/>
  3. In the <Loggers>...</Loggers> section, add the following lines:

            <Logger name="org.apache.cassandra" level="info" additivity="false">
    <AppenderRef ref="cassandra"/>
    </Logger>
  4. in the <Appenders>...</Appenders> section, add the following lines:

            <File name="cassandra" fileName="logs/cassandra.log" append="false">
    <ThresholdFilter level="debug"/>
    <PatternLayout pattern="%d{dd.MM.yyyy HH:mm:ss,SSS} %-5p %-25c %m - [%t] %C.%M (%F:%L)%n%throwable{full}"/>
    </File>
  5. Optionally, configure log file rotation by adding a Log4J Rolling File Appender to the logging.xml file.

Was this page helpful?