Guide to Apache Druid extensions including core extensions, community extensions, and how to load them.
Druid implements an extension system that allows for adding functionality at runtime. Extensions are commonly used to add support for deep storages (like HDFS and S3), metadata stores (like MySQL and PostgreSQL), new aggregators, new input formats, and so on.Production clusters will generally use at least two extensions: one for deep storage and one for a metadata store. Many clusters will also use additional extensions.
The Maven groupId for most community extensions is org.apache.druid.extensions.contrib. The artifactId is the extension name, and the version matches the Druid version.
If you add your extension jar to the classpath at runtime, Druid will load it into the system. However, this means you must ensure all dependency jars on the classpath are compatible.
Druid makes no provisions for class loader isolation when using this method. Ensure all jars on your classpath are mutually compatible.
Extension behavior can be configured in common.runtime.properties:
# Directory containing extensionsdruid.extensions.directory=extensions# Hadoop dependencies directory druid.extensions.hadoopDependenciesDir=hadoop-dependencies# List of extensions to load (null = load all, [] = load none)druid.extensions.loadList=["postgresql-metadata-storage", "druid-s3-extensions"]# Search main classloader for extensionsdruid.extensions.searchCurrentClassloader=true# Extensions prefer their own jars over Druid's bundled jarsdruid.extensions.useExtensionClassloaderFirst=false
If you’d like a community extension to be promoted to core, or if you want to take on maintenance for a community extension, please post on dev@druid.apache.org.