Skip to content

Instantly share code, notes, and snippets.

View alebsys's full-sized avatar

Aleksandr Lebedev alebsys

View GitHub Profile
@alebsys
alebsys / tcp-connection-latency.bpf.c
Last active December 26, 2024 11:16
tcp-connection-latency for ebpf_exporter
#include <vmlinux.h>
#include <bpf/bpf_tracing.h>
#include <bpf/bpf_helpers.h>
#include <bpf/bpf_core_read.h>
#include "maps.bpf.h"
#define AF_INET 2
#define AF_INET6 10
@alebsys
alebsys / gist:629f0545a5a4250142406c354b90d308
Created September 16, 2024 06:10
Ссылки к выступлению на PerfConf #10
[TCP Congestion Control in Action](https://www.alebedev.tech/posts/cwnd-retransmit/)
[TCP ретрансмиты и их направления](https://www.alebedev.tech/posts/tcp-retransmit-ebpf-exporter/)
Long way to the application ([ч1](https://www.alebedev.tech/posts/long-way-to-the-app-1/), [ч2](https://www.alebedev.tech/posts/long-way-to-the-app-2/))
[Как мы боролись с овербукингом Kubernetes-кластеров](https://habr.com/ru/companies/ecom_tech/articles/735638/)
{
"$schema": "https://vega.github.io/schema/vega/v5.json",
"width": 950,
"height": 600,
"data": [
{
"name": "traces",
"values" : [
{
"operation_name" : "input",
version: '3.4'
services:
comment_db:
image: mongo:3.2
volumes:
- comment_db:/data/db
networks:
back_net:
aliases:
- comment_db
version: '3.4'
services:
comment_db:
image: mongo:3.2
volumes:
- comment_db:/data/db
networks:
back_net:
aliases:
- comment_db
# global
USERNAME=<your_username>
TAG=mcdocker
# postgresql config
POSTGRES_DB=post
POSTGRES_USER=post
POSTGRES_PASSWORD=post
# ui config
version: '3.4'
services:
comment_db:
image: mongo:3.2
volumes:
- comment_db:/data/db
networks:
back_net:
aliases:
- comment_db
FROM ruby:2.3
ENV APP_HOME /app
ENV POST_SERVICE_HOST post
ENV POST_SERVICE_PORT 5000
ENV COMMENT_SERVICE_HOST comment
ENV COMMENT_SERVICE_PORT 9292
WORKDIR $APP_HOME
COPY . $APP_HOME
FROM alpine:3.7
ENV POST_DATABASE_HOST 127.0.0.1
ENV POST_DATABASE post
ENV POST_DATABASE_PORT 5432
ENV POST_DATABASE_USER post
ENV POST_DATABASE_PASSWORD post
RUN apk add --no-cache python3 python3-dev gcc musl-dev curl postgresql-dev
FROM alpine:3.7 as builder
ENV APP_HOME /app
WORKDIR $APP_HOME
COPY . $APP_HOME
RUN apk add --no-cache \
gcc \
g++ \