linkerd / linkerd/linkerd2

PostgreSQL Metrics Support

Open
#2,632 7 comments 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

rfc
Dominant language
Go
Stars
11.5k
Forks
1.4k
Avg merge
3d 22h
Merged PRs (30d)
53

Description

### What problem are you trying to solve?

Deep inspection into PostgreSQL connections and the data being passed across them would provide more granularity in debugging performance issues for many database-driven applications.

### How should the problem be solved?

Implement a PostgreSQL codec that allows the Linkerd proxy to inspect the PostgreSQL wire protocol and provide metrics for the communications with the database server. This could be exposed as a CLI as well as providing Prometheus metrics.

Potentially useful metrics made available as a result of this:

- Open database connections
- Authentication failures/successes (more than a very few failures is indicative of either a very bad misconfiguration, or malice)
- Connection lifetime
- Query-response latency
- Response size

### Related Issues

As #1779, similar to #2214.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with related issues #1779 and #2214, then locate the Linkerd proxy's protocol-handling entry point and the CLI and Prometheus metrics entry points. Done means PostgreSQL wire-protocol inspection is implemented and the listed connection, authentication, lifetime, latency, and response-size metrics are exposed; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
postgresql, prometheus
Domain
cli, databases, observability
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.