Step 1. Add the JitPack repository to your build file
Add it in your root settings.gradle at the end of repositories:
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url 'https://jitpack.io' }
}
}
Add it in your settings.gradle.kts at the end of repositories:
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url = uri("https://jitpack.io") }
}
}
Add to pom.xml
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
Add it in your build.sbt at the end of resolvers:
resolvers += "jitpack" at "https://jitpack.io"
Add it in your project.clj at the end of repositories:
:repositories [["jitpack" "https://jitpack.io"]]
Step 2. Add the dependency
dependencies {
implementation 'com.github.softwareverde:java-db-mysql-embedded:v3.2.1'
}
dependencies {
implementation("com.github.softwareverde:java-db-mysql-embedded:v3.2.1")
}
<dependency>
<groupId>com.github.softwareverde</groupId>
<artifactId>java-db-mysql-embedded</artifactId>
<version>v3.2.1</version>
</dependency>
libraryDependencies += "com.github.softwareverde" % "java-db-mysql-embedded" % "v3.2.1"
:dependencies [[com.github.softwareverde/java-db-mysql-embedded "v3.2.1"]]
Inspired by MariaDB4j, this package provides a framework for prebuilt MariaDB binaries for Windows, Linux, and OSX.
This framework improves upon MariaDB4j by having fewer dependencies, using a modern build process, a modern version of MariaDB4j, and ensures the database process is killed upon crash (when used with the prebuilt binaries/scripts provided below). This implementation is a rewrite and does not depend on MariaDB4j in any capacity.
Prebuilt binaries may be included via the following dependencies, and are not mutually-exclusive:
implementation group: 'com.github.softwareverde', name: 'java-mariadb-osx', version: 'v10.5.8'
implementation group: 'com.github.softwareverde', name: 'java-mariadb-windows', version: 'v10.5.8'
implementation group: 'com.github.softwareverde', name: 'java-mariadb-linux', version: 'v10.5.8'
Including multiple versions of prebuilt binaries for any one OS may result in undefined behavior.
If you choose to use your own compiled binaries, the resource jar must provide the following:
src/main/resources/mysql/<OS>/manifest
x
) if the extracted
file should be executable.init.sh
script for the Linux/OSX environments that initializes the data directories, located within
src/main/resources/mysql/<OS>/.
init.sh
script will receive the data directory as its first parameter.run.sh
script for Linux/OSX and a run.bat
script for Windows environments, located within
src/main/resources/mysql/<OS>/.
.datadir
helper file located within
src/main/resources/mysql/<OS>/.
to load the location of the database data files.The v1-v2 series are an API wrapper around MariaDB4j.