MariaDB JDBC driver

Connect Scriptella to MariaDB using the built-in mariadb adapter and an external JDBC driver.

Install the JDBC driver

Download the official JDBC driver for Maven coordinate org.mariadb.jdbc:mariadb-java-client:3.5.7. Place mariadb-java-client-3.5.7.jar in a lib/ directory next to your ETL file.

JDBC class org.mariadb.jdbc.Driver. The example below shows the JDBC URL format.

Check the connection

Replace the sample host and database or service name. Replace DEMO_USER and DEMO_PASSWORD with your local demo credentials. Save this as check.etl.xml, then run scriptella.sh check.etl.xml. The read-only query passes the connection_ok column to the nested script, which prints CONNECTION OK: 1.

<?xml version="1.0"?>
<!DOCTYPE etl SYSTEM "http://scriptella.org/dtd/etl.dtd">
<etl>
    <connection id="db" driver="mariadb"
                url="jdbc:mariadb://db.example.com:3306/app"
                user="DEMO_USER" password="DEMO_PASSWORD"
                classpath="lib/mariadb-java-client-3.5.7.jar"/>
    <connection id="console" driver="text"/>
    <query connection-id="db">
        SELECT 1 AS connection_ok;
        <script connection-id="console">CONNECTION OK: $connection_ok</script>
    </query>
</etl>

Keep real passwords out of version control. For shared or deployed ETL files, set SCRIPTELLA_DB_USER and SCRIPTELLA_DB_PASSWORD in the process environment and use user="${env.SCRIPTELLA_DB_USER}" and password="${env.SCRIPTELLA_DB_PASSWORD}" in the connection.

Installation instructions · Download Scriptella

Verified with Scriptella 1.7.0

MariaDB 11.8.8 with JDBC driver 3.5.7. Packaged validation passed parameterized writes and reads, migration in both directions with H2, commit, and rollback. The public Testcontainers check passed ETL copy, representative values, and rollback.

Compatibility evidence · Public Testcontainers run

Configuration notes

Use the jdbc:mariadb: scheme with MariaDB Connector/J and configure TLS for remote deployments.

Adapter Javadoc