This injector is used to demo elasticsearch and Kibana.
| Injector | elasticsearch | Release date |
|---|---|---|
| 9.4-SNAPSHOT | 9.4.0 | |
| 9.3.1 | 9.3.0 | 2026年02月10日 |
| 9.3* | 9.3.0 | 2026年02月09日 |
| 8.16 | 8.16.1 | 2024年12月09日 |
| 8.15 | 8.15.1 | 2024年09月23日 |
| 8.7 | 8.7.0 | 2023年04月20日 |
| 8.6 | 8.6.0 | 2023年01月12日 |
| 8.4 | 8.4.1 | 2022年09月06日 |
| 8.3 | 8.3.1 | 2022年07月06日 |
| 8.0 | 8.0.0 | 2022年02月16日 |
| 7.15 | 7.15.1 | 2021年10月28日 |
| 7.0 | 7.0.0 | 2019年04月11日 |
| 6.5 | 6.5.1 | 2018年12月03日 |
| 6.4.2 | 6.4.2 | 2018年10月03日 |
| 6.4 | 6.4.0 | 2018年09月06日 |
| 6.2 | 6.2.3 | 2018年04月09日 |
| 6.0 | 6.0.0-alpha1 | 2017年05月10日 |
| 5.3 | 5.3.2 | 2017年05月05日 |
| 5.0 | 5.0.0 | 2016年10月03日 |
| 5.0 | 5.0.0 | 2016年03月31日 |
| 5.0 | 5.0.0-alpha1 | 2016年03月30日 |
| 3.2 | 2.2.0 | 2016年02月05日 |
| 3.1 | 2.1.0 | 2015年11月27日 |
| 3.0 | 2.0.0 | 2015年11月12日 |
| 2.10 | 1.7.1 | 2015年09月07日 |
| 2.9 | 1.6.0 | 2015年06月15日 |
| 2.8 | 1.5.2 | 2015年06月01日 |
| 2.7 | 1.4.4 | 2015年02月24日 |
| 2.6 | 1.4.0 | 2014年11月19日 |
| 2.5 | 1.3.2 | 2014年09月02日 |
| 2.4 | 1.2.0 | 2014年05月26日 |
| 2.3 | 1.1.1 | 2014年05月06日 |
| 2.2 | 1.1.0 | 2014年04月01日 |
| 2.1 | 1.0.0 | 2014年03月21日 |
| 2.1.RC2 | 1.0.0.RC2 | 2014年02月04日 |
| 2.1.RC1 | 1.0.0.RC1 | 2014年01月23日 |
| 1.1 | 0.90.6 | 2013年11月05日 |
| 1.0 | 0.90.5 | 2013年10月01日 |
* Broken version
Maven Central Build and Deploy the main branch
You will need Java 21 to run the injector.
# Download it from maven central wget https://repo1.maven.org/maven2/fr/pilato/elasticsearch/injector/injector/9.3.1/injector-9.3.1.jar # Launch it (with all default settings) java -jar injector-9.3.1.jar
If you are looking for a SNAPSHOT version, please look into https://s01.oss.sonatype.org/content/repositories/snapshots/fr/pilato/elasticsearch/injector/injector/9.4-SNAPSHOT/
# Pull the latest build docker pull dadoonet/persons-injector # Or a specific version docker pull dadoonet/persons-injector:9.3.1 # Launch it (with all default settings) docker run dadoonet/persons-injector
If you are looking for a SNAPSHOT version, please look into https://hub.docker.com/repository/docker/dadoonet/persons-injector/
With no option, it will inject 1000000 documents with a bulk size of 10000 in a local cluster running at
https://127.0.0.1:9200 with default password changeme for user named elastic.
Injector comes with the following implementations:
- Elasticsearch (
--elasticsearchflag), where you want to index generated data to an elasticsearch cluster running locally or on cloud. - Console (
--consoleflag), where you want to just print on the console generated data.
For both, you can configure --nb option to define the number of documents you'd like to generate
(defaults to 1000000).
Also --bulk option can be set to define how many documents should be sent at once (defaults to 10000).
For example:
# Docker installation docker run dadoonet/persons-injector --nb 1000 --bulk 100 # Local installation java -jar injector-9.3.1.jar --nb 1000 --bulk 100
If no implementation is set, the injector will assume by default that you want to index your data in Elasticsearch
and will set --elasticsearch flag for you.
When running an Elasticsearch instance, local or on cloud.elastic.co, you can define other options.
To define the host to send the data to, set --es.host option (defaults to https://127.0.0.1:9200):
# Docker installation docker run dadoonet/persons-injector --elasticsearch --es.host https://cloud_id.europe-west1.gcp.cloud.es.io:9243 # Local installation java -jar injector-9.3.1.jar --elasticsearch --es.host https://cloud_id.europe-west1.gcp.cloud.es.io:9243
When using the default local cluster using the Docker image, you need to tell the injector to use the host network with
--network host option so that it can connect to the local Elasticsearch instance running on localhost:9200.
docker run --network host dadoonet/persons-injector --elasticsearch
If your cluster is secured, which is what will happen most likely on cloud.elastic.co, use --es.apikey to set the API Key to use.
# Docker installation docker run --network host dadoonet/persons-injector --elasticsearch --es.apikey API_KEY # Local installation java -jar injector-9.3.1.jar --elasticsearch --es.apikey API_KEY
If you'd like to index your data in another index than person (default one), use --es.index:
# Docker installation docker run --network host dadoonet/persons-injector --elasticsearch --es.index person # Local installation java -jar injector-9.3.1.jar --elasticsearch --es.index person
Note: --es.user (defaults to elastic) and --es.pass are deprecated and should not be used anymore.
If you want to use Kibana to display the information that have been generated, you can import the following
files into Kibana using Stack Management -> Kibana -> Saved Objects menu and click on "Import":
- Data view, Dashboard, Maps, Visualisations: https://github.com/dadoonet/injector/blob/main/src/main/resources/kibana-dashboard.ndjson
- Canvas example: https://github.com/dadoonet/injector/blob/main/src/main/resources/kibana-canvas.ndjson
Example of the Persons dataset dashboard:
Example of the Canvas presentation:
When printing documents to the console, you can choose to prettify the documents first by using cs.pretty option:
# Docker installation docker run dadoonet/persons-injector --console --cs.pretty # Local installation java -jar injector-9.3.1.jar --console --cs.pretty
You can start the injector like this (all options together):
# Docker installation docker run dadoonet/persons-injector \ --nb 1000 --bulk 100 \ --elasticsearch --es.host https://cloud_id.europe-west1.gcp.cloud.es.io:9243 --es.apikey API_KEY --es.index person \ --console --cs.pretty # Local installation java -jar injector-9.3.1.jar \ --nb 1000 --bulk 100 \ --debug \ --elasticsearch --es.host https://cloud_id.europe-west1.gcp.cloud.es.io:9243 --es.apikey API_KEY --es.index person \ --console --cs.pretty
When you build the project with maven, you'll see in target/scripts dir an example
of scripts which you can adapt to your needs.
You can use --silent, --debug or --trace to change the log level when using the injector.
That can give you more information when something is failing for example.
If you wish to edit the documentation, please edit it in src/main/documentation.
Then run the following commands to update the README in the root of this project and commit your changes:
mvn clean process-resources
git commit -a -m "Update documentation"The command-line interface is implemented with Picocli.
If you want to update to a new elasticsearch server version, modify pom.xml file:
<elasticsearch.version>9.4.0</elasticsearch.version>
If you want to manually update to a new elasticsearch client version, modify pom.xml file:
<elasticsearch-client.version>9.4.2</elasticsearch-client.version>
Then compile the project:
# Compile
mvn clean installJust get the final jar from target/injector-9.4-SNAPSHOT.jar. Or:
cd targetAnd launch all the examples from this dir.
Ideally, modify the src/main/documentation/README.markdown file to add a static line with the release.
Also modify the injector.stable.version property in the pom.xml and commit the changes:
mvn clean process-resources
git commit -a -m "Document the stable version"To release the project you to use the release profile as you need to sign the artifacts.
First step is to check that everything is building correctly (javadoc, sources):
mvn clean install -Prelease # Or if you want to skip the tests mvn clean install -Prelease -DskipTests # And if you already know that Docker is building correctly, you can also skip it mvn clean install -Prelease -DskipTests -Ddocker.skip
Then you can run the following commands to prepare and perform the release:
mvn release:prepare git push --tags git push mvn release:perform -Prelease
If you need to skip the tests, run:
mvn release:perform -Prelease -Darguments="-DskipTests"After a while, the release should be available on maven central and docker hub.
It could take some time for the release to be available on maven central, so if you don't see it right away,
please be patient and check again later. You can always watch https://central.sonatype.com/publishing/deployments
to confirm that the deployment is still in progress. You need to be authenticated for this and have access to the
namespace fr.pilato.
This software is licensed under the Apache 2 license, quoted below. Copyright 2009-2026 Elastic <https://www.elastic.co> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.