Skip to content

Commit

Permalink
Monitoring with Prometheus and Grafana (#91)
Browse files Browse the repository at this point in the history
* Monitoring with Prometheus and Grafana

* Update docs
  • Loading branch information
mosuka authored Feb 9, 2022
1 parent 626f4dc commit faac714
Show file tree
Hide file tree
Showing 40 changed files with 8,864 additions and 163 deletions.
74 changes: 43 additions & 31 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ services:
environment:
MINIO_ROOT_USER: ${MINIO_ROOT_USER}
MINIO_ROOT_PASSWORD: ${MINIO_ROOT_PASSWORD}
MINIO_PROMETHEUS_AUTH_TYPE: ${MINIO_PROMETHEUS_AUTH_TYPE}
command: server ${MINIO_VOLUMES} ${MINIO_OPTS}
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
Expand All @@ -58,42 +59,53 @@ services:
ports:
- "4566:4566"

prometheus:
container_name: prometheus
image: prom/prometheus:latest
volumes:
- ./examples/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- "9090:9090"

grafana:
container_name: grafana
image: grafana/grafana:latest
ports:
- "3000:3000"
volumes:
- ./grafana.ini:/etc/grafana/grafana.ini
- ./dist:/var/lib/grafana/plugins/phalanx-grafana-datasource
- ./examples/grafana/grafana.ini:/etc/grafana/grafana.ini
- ./examples/grafana/dashboards:/etc/grafana/provisioning/dashboards
- ./examples/grafana/datasources:/etc/grafana/provisioning/datasources
environment:
- GF_SERVER_ROOT_URL=http://localhost:3000
- GF_SECURITY_ADMIN_PASSWORD=admin
GF_SERVER_ROOT_URL: ${GF_SERVER_ROOT_URL}
GF_SECURITY_ADMIN_PASSWORD: ${GF_SECURITY_ADMIN_PASSWORD}
depends_on:
- prometheus

# phalanx:
# container_name: phalanx
# image: mosuka/phalanx:latest
# environment:
# MINIO_ENDPOINT: minio:9000
# MINIO_ACCESS_KEY: ${MINIO_ACCESS_KEY}
# MINIO_SECRET_KEY: ${MINIO_SECRET_KEY}
# MINIO_REGION_NAME: ${MINIO_REGION_NAME}
# MINIO_SESSION_TOKEN: ${MINIO_SESSION_TOKEN}
# MINIO_SECURE: ${MINIO_SECURE}
# ETCD_ENDPOINTS: etcd:2379
# command:
# - '--host=phalanx'
# - '--bind-port=2000'
# - '--grpc-port=5000'
# - '--http-port=8000'
# - '--roles=indexer,searcher'
# - '--index-metastore-uri=etcd://phalanx/metastore'
# - '--log-level=info'
# ports:
# - "2000:2000"
# - "5000:5000"
# - "8000:8000"
# depends_on:
# - etcd
# - minio
# restart: always
phalanx:
container_name: phalanx
image: mosuka/phalanx:latest
environment:
MINIO_ENDPOINT: minio:9000
MINIO_ACCESS_KEY: ${MINIO_ACCESS_KEY}
MINIO_SECRET_KEY: ${MINIO_SECRET_KEY}
MINIO_REGION_NAME: ${MINIO_REGION_NAME}
MINIO_SESSION_TOKEN: ${MINIO_SESSION_TOKEN}
MINIO_SECURE: ${MINIO_SECURE}
ETCD_ENDPOINTS: etcd:2379
command:
- '--host=phalanx'
- '--bind-port=2000'
- '--grpc-port=5000'
- '--http-port=8000'
- '--roles=indexer,searcher'
- '--index-metastore-uri=etcd://phalanx-metadata'
- '--log-level=info'
ports:
- "2000:2000"
- "5000:5000"
- "8000:8000"
depends_on:
- etcd
- minio
restart: always
2 changes: 1 addition & 1 deletion docs/aggregations.html
Original file line number Diff line number Diff line change
Expand Up @@ -649,7 +649,7 @@ <h1 class="search-results-title">No results matching "<span class='search-query'
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Aggregations","level":"1.14","depth":1,"next":{"title":"RESTful API","level":"1.15","depth":1,"path":"restful_api.md","ref":"restful_api.md","articles":[{"title":"Create Index API","level":"1.15.1","depth":2,"path":"restful_api/create_index_api.md","ref":"restful_api/create_index_api.md","articles":[]},{"title":"Delete Index API","level":"1.15.2","depth":2,"path":"restful_api/delete_index_api.md","ref":"restful_api/delete_index_api.md","articles":[]},{"title":"Add Documents API","level":"1.15.3","depth":2,"path":"restful_api/add_documents_api.md","ref":"restful_api/add_documents_api.md","articles":[]},{"title":"Delete Documents API","level":"1.15.4","depth":2,"path":"restful_api/delete_documents_api.md","ref":"restful_api/delete_documents_api.md","articles":[]},{"title":"Search API","level":"1.15.5","depth":2,"path":"restful_api/search_api.md","ref":"restful_api/search_api.md","articles":[]}]},"previous":{"title":"Queries","level":"1.13","depth":1,"path":"queries.md","ref":"queries.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"aggregations.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-07T07:26:43.169Z"},"basePath":".","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Aggregations","level":"1.14","depth":1,"next":{"title":"RESTful API","level":"1.15","depth":1,"path":"restful_api.md","ref":"restful_api.md","articles":[{"title":"Create Index API","level":"1.15.1","depth":2,"path":"restful_api/create_index_api.md","ref":"restful_api/create_index_api.md","articles":[]},{"title":"Delete Index API","level":"1.15.2","depth":2,"path":"restful_api/delete_index_api.md","ref":"restful_api/delete_index_api.md","articles":[]},{"title":"Add Documents API","level":"1.15.3","depth":2,"path":"restful_api/add_documents_api.md","ref":"restful_api/add_documents_api.md","articles":[]},{"title":"Delete Documents API","level":"1.15.4","depth":2,"path":"restful_api/delete_documents_api.md","ref":"restful_api/delete_documents_api.md","articles":[]},{"title":"Search API","level":"1.15.5","depth":2,"path":"restful_api/search_api.md","ref":"restful_api/search_api.md","articles":[]}]},"previous":{"title":"Queries","level":"1.13","depth":1,"path":"queries.md","ref":"queries.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"aggregations.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-09T06:50:28.533Z"},"basePath":".","book":{"language":""}});
});
</script>
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/analyzer.html
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ <h1 class="search-results-title">No results matching "<span class='search-query'
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Analyzer","level":"1.12","depth":1,"next":{"title":"Char filters","level":"1.12.1","depth":2,"path":"analyzer/char_filters.md","ref":"analyzer/char_filters.md","articles":[]},"previous":{"title":"Index Mapping","level":"1.11","depth":1,"path":"index_mapping.md","ref":"index_mapping.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-07T07:26:43.169Z"},"basePath":".","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Analyzer","level":"1.12","depth":1,"next":{"title":"Char filters","level":"1.12.1","depth":2,"path":"analyzer/char_filters.md","ref":"analyzer/char_filters.md","articles":[]},"previous":{"title":"Index Mapping","level":"1.11","depth":1,"path":"index_mapping.md","ref":"index_mapping.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-09T06:50:28.533Z"},"basePath":".","book":{"language":""}});
});
</script>
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/analyzer/char_filters.html
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ <h1 class="search-results-title">No results matching "<span class='search-query'
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Char filters","level":"1.12.1","depth":2,"next":{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},"previous":{"title":"Analyzer","level":"1.12","depth":1,"path":"analyzer.md","ref":"analyzer.md","articles":[{"title":"Char filters","level":"1.12.1","depth":2,"path":"analyzer/char_filters.md","ref":"analyzer/char_filters.md","articles":[]},{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},{"title":"Token filters","level":"1.12.3","depth":2,"path":"analyzer/token_filters.md","ref":"analyzer/token_filters.md","articles":[]}]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer/char_filters.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-07T07:26:43.169Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Char filters","level":"1.12.1","depth":2,"next":{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},"previous":{"title":"Analyzer","level":"1.12","depth":1,"path":"analyzer.md","ref":"analyzer.md","articles":[{"title":"Char filters","level":"1.12.1","depth":2,"path":"analyzer/char_filters.md","ref":"analyzer/char_filters.md","articles":[]},{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},{"title":"Token filters","level":"1.12.3","depth":2,"path":"analyzer/token_filters.md","ref":"analyzer/token_filters.md","articles":[]}]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer/char_filters.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-09T06:50:28.533Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/analyzer/token_filters.html
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ <h1 class="search-results-title">No results matching "<span class='search-query'
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Token filters","level":"1.12.3","depth":2,"next":{"title":"Queries","level":"1.13","depth":1,"path":"queries.md","ref":"queries.md","articles":[]},"previous":{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer/token_filters.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-07T07:26:43.169Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Token filters","level":"1.12.3","depth":2,"next":{"title":"Queries","level":"1.13","depth":1,"path":"queries.md","ref":"queries.md","articles":[]},"previous":{"title":"Tokenizers","level":"1.12.2","depth":2,"path":"analyzer/tokenizers.md","ref":"analyzer/tokenizers.md","articles":[]},"dir":"ltr"},"config":{"gitbook":"*","theme":"default","variables":{},"plugins":["hide-published-with"],"pluginsConfig":{"hide-published-with":{},"highlight":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"}},"file":{"path":"analyzer/token_filters.md","mtime":"2022-01-18T13:00:14.678Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2022-02-09T06:50:28.533Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
Expand Down
Loading

0 comments on commit faac714

Please sign in to comment.