Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/springtainer/springtainer-elasticsearch
Elasticsearch as docker-container for springboot testing
https://github.com/springtainer/springtainer-elasticsearch
elasticsearch spring spring-boot testcontainers testing
Last synced: 1 day ago
JSON representation
Elasticsearch as docker-container for springboot testing
- Host: GitHub
- URL: https://github.com/springtainer/springtainer-elasticsearch
- Owner: springtainer
- License: mit
- Created: 2018-03-14T06:37:03.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-05-26T22:16:03.000Z (over 1 year ago)
- Last Synced: 2023-06-29T21:44:37.786Z (over 1 year ago)
- Topics: elasticsearch, spring, spring-boot, testcontainers, testing
- Language: Java
- Homepage:
- Size: 69.3 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# springtainer-elasticsearch
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.avides.springboot.springtainer/springtainer-elasticsearch/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.avides.springboot.springtainer/springtainer-elasticsearch)
[![Build](https://github.com/springtainer/springtainer-elasticsearch/workflows/release/badge.svg)](https://github.com/springtainer/springtainer-elasticsearch/actions)
[![Nightly build](https://github.com/springtainer/springtainer-elasticsearch/workflows/nightly/badge.svg)](https://github.com/springtainer/springtainer-elasticsearch/actions)
[![Coverage report](https://sonarcloud.io/api/project_badges/measure?project=springtainer_springtainer-elasticsearch&metric=coverage)](https://sonarcloud.io/dashboard?id=springtainer_springtainer-elasticsearch)
[![Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=springtainer_springtainer-elasticsearch&metric=alert_status)](https://sonarcloud.io/dashboard?id=springtainer_springtainer-elasticsearch)
[![Technical dept](https://sonarcloud.io/api/project_badges/measure?project=springtainer_springtainer-elasticsearch&metric=sqale_index)](https://sonarcloud.io/dashboard?id=springtainer_springtainer-elasticsearch)### Dependency
```xml
com.avides.springboot.springtainer
springtainer-elasticsearch
1.4.0
test```
### Configuration
Properties consumed (in `bootstrap.properties`):
- `embedded.container.elasticsearch.enabled` (default is `true`)
- `embedded.container.elasticsearch.startup-timeout` (default is `30`)
- `embedded.container.elasticsearch.docker-image` (default is `docker.elastic.co/elasticsearch/elasticsearch:7.17.9`)
- `embedded.container.elasticsearch.http-port` (default is `9200`)
- `embedded.container.elasticsearch.transport-host` (default is `9300`)Properties provided (in `application-it.properties`):
- `embedded.container.elasticsearch.host`
- `embedded.container.elasticsearch.http-port`
- `embedded.container.elasticsearch.transport-port`Example for minimal configuration in `application-it.properties`:
```
spring.data.elasticsearch.cluster-nodes=${embedded.container.elasticsearch.host}:${embedded.container.elasticsearch.transport-port}
spring.data.elasticsearch.properties.client.transport.ignore_cluster_name=true
```## Logging
To reduce logging insert this into the logback-configuration:
```xml
```
## Labels
The container exports multiple labels to analyze running springtainers:
- `SPRINGTAINER_SERVICE=elasticsearch`
- `SPRINGTAINER_IMAGE=${embedded.container.elasticsearch.docker-image}`
- `SPRINGTAINER_STARTED=$currentTimestamp`