Answers: <p>This is a little off.  You are comparing a &quot;Time Series Database&quot; to a &quot;Log Shipper&quot;.</p>
  <p><strong>How Prometheus Works</strong></p>
  <p>Any service/entity prometheus wants to run monitor has to provide an &quot;exporter&quot;.  An exporter is just a http endpoint that has metrics in a simple text format.  The exporter can be a standalone app, a web sever linking to a file, or something like spring boot literally just adding a url to serve prometheus metrics.  Lots of other systems can pickup and use this format, not just prometheus.</p>
  <p>You configure prometheus to &quot;scrape&quot; these metrics and store them in its own Time Series Database, usually at 30 second intervals.  Then prometheus is basically your metrics database.  It also integrates with alert manager to help you trigger alerts to slack, pager duty, etc.</p>
  <p><strong>How Fluent Bit Works</strong></p>
  <p>Fluent Bit is a log shipper.  It is better compared with, say, logstash.  It can basically take any kind of log data (text lines) and ship/route/filter/etc them to a destination system.  It is not itself a time series database like prometheus though.  Also prometheus is not a log shipper, it can't go make arbitrary routing decisions on the data being sent to it.</p>
  <p>This may be worth a skim - <a href="https://logz.io/blog/fluentd-logstash/" rel="nofollow noreferrer">https://logz.io/blog/fluentd-logstash/</a>.</p>
  
Answers: CC BY-SA 4.0
Answers: 2022-01-10T22:10:02.567Z
Answers: So, they work in unison or is having Prometheus enough if I don't have any super-complex logging routing/strategies?
Answers: Grafana
Answers: CC BY-SA 4.0
Answers: 2022-01-11T01:41:38.693Z
Answers: Prometheus handles application metrics specifically and is a TSDB.  Fluent Bit is a part of a logging solution (like ELK - Elastic Search, LogStash, Kibana), which is generally used to collect, centralize, and visualize application logs (like when you do `logger.error("Oh No!");`.  Fluent Bit would replace LogStash in that stack for routing logs to Elastic Search (kind of a text database) for visualization in Kibana.  You could route and analyze metrics in ELK, and you can do alerting, etc.  But Prometheus/alert-manager/grafana are really designed for doing that on app metrics and excel at it.
Answers: John Humphreys
Answers: CC BY-SA 4.0
Answers: 2022-01-11T01:43:39.040Z
Answers: For example, we maintain prometheus + alert manager + thanos + cortex + grafana for application metrics, and a separate ELK stack (which may use fluent eventually) for application log analysis.  Metrics != logs.
Answers: John Humphreys
Answers: CC BY-SA 4.0
Answers: 2022-01-11T16:26:50.673Z
Answers: Ah, thanks, that cleared it up. I'd vote the answer up if I could.
Answers: Grafana
Answers: CC BY-SA 4.0
Answers: 2023-07-02T14:17:32.563Z
Answers: Fluent Bit is also a "Metric Shipper": "Metrics also are unique in Fluent Bit in that metrics don’t go through the same pipelines that logs go through. So metrics are almost treated as an independent type." (https://calyptia.com/blog/logs-openmetrics-opentelemetry-fluent-bit). There is an experimental plugin attempting to cross this divide within Fluent Bit: Log to Metrics (https://docs.fluentbit.io/manual/pipeline/filters/log_to_metrics). The following Fluent Bit pipeline could work: Tail -> JSON -> Log to Metrics -> Prometheus Exporter (or Prometheus Remote Write)
Answers: n1ghtm4n4g3r
Answers: CC BY-SA 4.0
Answers: 2022-01-10T19:46:35.560Z
Answers: 2022-01-10T19:46:35.560Z
Answers: John Humphreys
Body: <p>From what I've seen, Prometheus scrapes data and metrics and displays them and Fluent Bit collects logs and metrics and can output them.</p>
  <p>So, are they doing the same thing, i.e. should I choose one over the other or am I missing something?</p>
  
Tags: <kubernetes><prometheus><logging><fluentd>
Title: What is the difference between Fluent Bit and Prometheus?
UserDisplayName: Grafana
ThreadText: # What is the difference between Fluent Bit and Prometheus?
  
  (Asked by: username_0 on 2022-01-10)
  
  From what I've seen, Prometheus scrapes data and metrics and displays them and Fluent Bit collects logs and metrics and can output them.
  
  So, are they doing the same thing, i.e. should I choose one over the other or am I missing something?
  
  **Tags:** kubernetes, prometheus, logging, fluentd
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2022-01-10. Score: 2 | Accepted answer
  
  This is a little off. You are comparing a "Time Series Database" to a "Log Shipper".
  
  **How Prometheus Works**
  
  Any service/entity prometheus wants to run monitor has to provide an "exporter". An exporter is just a http endpoint that has metrics in a simple text format. The exporter can be a standalone app, a web sever linking to a file, or something like spring boot literally just adding a url to serve prometheus metrics. Lots of other systems can pickup and use this format, not just prometheus.
  
  You configure prometheus to "scrape" these metrics and store them in its own Time Series Database, usually at 30 second intervals. Then prometheus is basically your metrics database. It also integrates with alert manager to help you trigger alerts to slack, pager duty, etc.
  
  **How Fluent Bit Works**
  
  Fluent Bit is a log shipper. It is better compared with, say, logstash. It can basically take any kind of log data (text lines) and ship/route/filter/etc them to a destination system. It is not itself a time series database like prometheus though. Also prometheus is not a log shipper, it can't go make arbitrary routing decisions on the data being sent to it.
  
  This may be worth a skim - <https://logz.io/blog/fluentd-logstash/>.
  
  > **Comments:**
  > **username_0**: So, they work in unison or is having Prometheus enough if I don't have any super-complex logging routing/strategies?  
  > **username_1**: Prometheus handles application metrics specifically and is a TSDB.  Fluent Bit is a part of a logging solution (like ELK - Elastic Search, LogStash, Kibana), which is generally used to collect, centralize, and visualize application logs (like when you do `logger.error("Oh No!");`.  Fluent Bit would replace LogStash in that stack for routing logs to Elastic Search (kind of a text database) for visualization in Kibana.  You could route and analyze metrics in ELK, and you can do alerting, etc.  But Prometheus/alert-manager/username_0 are really designed for doing that on app metrics and excel at it.  
  > **username_1**: For example, we maintain prometheus + alert manager + thanos + cortex + username_0 for application metrics, and a separate ELK stack (which may use fluent eventually) for application log analysis.  Metrics != logs.  
  > **username_0**: Ah, thanks, that cleared it up. I'd vote the answer up if I could.  
  > **username_2**: Fluent Bit is also a "Metric Shipper": "Metrics also are unique in Fluent Bit in that metrics don’t go through the same pipelines that logs go through. So metrics are almost treated as an independent type." (https://calyptia.com/blog/logs-openmetrics-opentelemetry-fluent-bit). There is an experimental plugin attempting to cross this divide within Fluent Bit: Log to Metrics (https://docs.fluentbit.io/manual/pipeline/filters/log_to_metrics). The following Fluent Bit pipeline could work: Tail -> JSON -> Log to Metrics -> Prometheus Exporter (or Prometheus Remote Write)  
  
  ---
  
  