[#53] expose thrift

This commit is contained in:
Roy Kim 2020-03-24 14:42:11 +09:00 committed by Roy Kim
parent 477fd5a665
commit cc30618af8
7 changed files with 47 additions and 1 deletions

12
.env
View File

@ -63,6 +63,9 @@ COLLECTOR_RECEIVER_AGENT_PORT=9991
COLLECTOR_RECEIVER_METADATA_PORT=9991 COLLECTOR_RECEIVER_METADATA_PORT=9991
COLLECTOR_RECEIVER_STAT_PORT=9992 COLLECTOR_RECEIVER_STAT_PORT=9992
COLLECTOR_RECEIVER_SPAN_PORT=9993 COLLECTOR_RECEIVER_SPAN_PORT=9993
COLLECTOR_RECEIVER_BASE_PORT=9994
COLLECTOR_RECEIVER_STAT_UDP_PORT=9995
COLLECTOR_RECEIVER_SPAN_UDP_PORT=9996
FLINK_CLUSTER_ENABLE=true FLINK_CLUSTER_ENABLE=true
FLINK_CLUSTER_ZOOKEEPER_ADDRESS=zoo1 FLINK_CLUSTER_ZOOKEEPER_ADDRESS=zoo1
@ -73,12 +76,19 @@ COLLECTOR_DEBUG_LEVEL=INFO
### Pinpoint-Agent ### Pinpoint-Agent
PINPOINT_AGENT_NAME=pinpoint-agent PINPOINT_AGENT_NAME=pinpoint-agent
COLLECTOR_IP=pinpoint-collector
#network module(GRPC,THRIFT)
PROFILER_TRANSPORT_MODULE=GRPC
#collector information required
COLLECTOR_IP=pinpoint-collector
PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT=9991 PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT=9991
PROFILER_TRANSPORT_METADATA_COLLECTOR_PORT=9991 PROFILER_TRANSPORT_METADATA_COLLECTOR_PORT=9991
PROFILER_TRANSPORT_STAT_COLLECTOR_PORT=9992 PROFILER_TRANSPORT_STAT_COLLECTOR_PORT=9992
PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=9993 PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=9993
COLLECTOR_TCP_PORT=9994
COLLECTOR_STAT_PORT=9995
COLLECTOR_SPAN_PORT=9996
# Set sampling rate. If you set it to N, 1 out of N transaction will be sampled. # Set sampling rate. If you set it to N, 1 out of N transaction will be sampled.
PROFILER_SAMPLING_RATE=1 PROFILER_SAMPLING_RATE=1

View File

@ -130,11 +130,20 @@ services:
- "9991" - "9991"
- "9992" - "9992"
- "9993" - "9993"
- "9994"
- "9995"
- "9996"
ports: ports:
- "${COLLECTOR_RECEIVER_AGENT_PORT:-9991}:9991/udp" - "${COLLECTOR_RECEIVER_AGENT_PORT:-9991}:9991/udp"
- "${COLLECTOR_RECEIVER_METADATA_PORT:-9991}:9991/tcp" - "${COLLECTOR_RECEIVER_METADATA_PORT:-9991}:9991/tcp"
- "${COLLECTOR_RECEIVER_STAT_PORT:-9992}:9992/udp" - "${COLLECTOR_RECEIVER_STAT_PORT:-9992}:9992/udp"
- "${COLLECTOR_RECEIVER_SPAN_PORT:-9993}:9993/udp" - "${COLLECTOR_RECEIVER_SPAN_PORT:-9993}:9993/udp"
- "${COLLECTOR_RECEIVER_BASE_PORT:-9994}:9994"
- "${COLLECTOR_RECEIVER_STAT_UDP_PORT:-9995}:9995/tcp"
- "${COLLECTOR_RECEIVER_SPAN_UDP_PORT:-9996}:9996/tcp"
- "${COLLECTOR_RECEIVER_STAT_UDP_PORT:-9995}:9995/udp"
- "${COLLECTOR_RECEIVER_SPAN_UDP_PORT:-9996}:9996/udp"
networks: networks:
- pinpoint - pinpoint
environment: environment:
@ -191,6 +200,7 @@ services:
- PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=${PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT} - PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=${PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT}
- PROFILER_SAMPLING_RATE=${PROFILER_SAMPLING_RATE} - PROFILER_SAMPLING_RATE=${PROFILER_SAMPLING_RATE}
- DEBUG_LEVEL=${AGENT_DEBUG_LEVEL} - DEBUG_LEVEL=${AGENT_DEBUG_LEVEL}
- PROFILER_TRANSPORT_MODULE=${PROFILER_TRANSPORT_MODULE}
depends_on: depends_on:
- pinpoint-collector - pinpoint-collector

View File

@ -5,12 +5,18 @@ SPRING_PROFILES=release
PINPOINT_AGENT_NAME=pinpoint-agent PINPOINT_AGENT_NAME=pinpoint-agent
#network module(GRPC,THRIFT)
PROFILER_TRANSPORT_MODULE=GRPC
#collector information required #collector information required
COLLECTOR_IP= COLLECTOR_IP=
PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT=9991 PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT=9991
PROFILER_TRANSPORT_METADATA_COLLECTOR_PORT=9991 PROFILER_TRANSPORT_METADATA_COLLECTOR_PORT=9991
PROFILER_TRANSPORT_STAT_COLLECTOR_PORT=9992 PROFILER_TRANSPORT_STAT_COLLECTOR_PORT=9992
PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=9993 PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=9993
COLLECTOR_TCP_PORT=9994
COLLECTOR_STAT_PORT=9995
COLLECTOR_SPAN_PORT=9996
# Set sampling rate. If you set it to N, 1 out of N transaction will be sampled. # Set sampling rate. If you set it to N, 1 out of N transaction will be sampled.
PROFILER_SAMPLING_RATE=1 PROFILER_SAMPLING_RATE=1

View File

@ -2,6 +2,14 @@
set -e set -e
set -x set -x
sed -i "/profiler.transport.module=/ s/=.*/=${PROFILER_TRANSPORT_MODULE}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.transport.module=/ s/=.*/=${PROFILER_TRANSPORT_MODULE}/" /pinpoint-agent/profiles/${SPRING_PROFILES}/pinpoint-env.config
sed -i "/profiler.collector.ip=/ s/=.*/=${COLLECTOR_IP}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.collector.tcp.port=/ s/=.*/=${COLLECTOR_TCP_PORT}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.collector.stat.port=/ s/=.*/=${COLLECTOR_STAT_PORT}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.collector.span.port=/ s/=.*/=${COLLECTOR_SPAN_PORT}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.transport.grpc.collector.ip=/ s/=.*/=${COLLECTOR_IP}/" /pinpoint-agent/pinpoint.config sed -i "/profiler.transport.grpc.collector.ip=/ s/=.*/=${COLLECTOR_IP}/" /pinpoint-agent/pinpoint.config
sed -i "/profiler.transport.grpc.collector.ip=/ s/=.*/=${COLLECTOR_IP}/" /pinpoint-agent/profiles/${SPRING_PROFILES}/pinpoint-env.config sed -i "/profiler.transport.grpc.collector.ip=/ s/=.*/=${COLLECTOR_IP}/" /pinpoint-agent/profiles/${SPRING_PROFILES}/pinpoint-env.config
sed -i "/profiler.transport.grpc.agent.collector.port=/ s/=.*/=${PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT}/" /pinpoint-agent/pinpoint.config sed -i "/profiler.transport.grpc.agent.collector.port=/ s/=.*/=${PROFILER_TRANSPORT_AGENT_COLLECTOR_PORT}/" /pinpoint-agent/pinpoint.config

View File

@ -25,6 +25,7 @@ services:
- PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=${PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT} - PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT=${PROFILER_TRANSPORT_SPAN_COLLECTOR_PORT}
- PROFILER_SAMPLING_RATE=${PROFILER_SAMPLING_RATE} - PROFILER_SAMPLING_RATE=${PROFILER_SAMPLING_RATE}
- DEBUG_LEVEL=${AGENT_DEBUG_LEVEL} - DEBUG_LEVEL=${AGENT_DEBUG_LEVEL}
- PROFILER_TRANSPORT_MODULE=${PROFILER_TRANSPORT_MODULE}
networks: networks:
- pinpoint - pinpoint

View File

@ -17,6 +17,9 @@ COLLECTOR_RECEIVER_AGENT_PORT=9991
COLLECTOR_RECEIVER_METADATA_PORT=9991 COLLECTOR_RECEIVER_METADATA_PORT=9991
COLLECTOR_RECEIVER_STAT_PORT=9992 COLLECTOR_RECEIVER_STAT_PORT=9992
COLLECTOR_RECEIVER_SPAN_PORT=9993 COLLECTOR_RECEIVER_SPAN_PORT=9993
COLLECTOR_RECEIVER_BASE_PORT=9994
COLLECTOR_RECEIVER_STAT_UDP_PORT=9995
COLLECTOR_RECEIVER_SPAN_UDP_PORT=9996
FLINK_CLUSTER_ENABLE=true FLINK_CLUSTER_ENABLE=true
FLINK_CLUSTER_ZOOKEEPER_ADDRESS=zoo1 FLINK_CLUSTER_ZOOKEEPER_ADDRESS=zoo1

View File

@ -16,11 +16,19 @@ services:
- "9991" - "9991"
- "9992" - "9992"
- "9993" - "9993"
- "9994"
- "9995"
- "9996"
ports: ports:
- "${COLLECTOR_RECEIVER_AGENT_PORT:-9991}:9991/udp" - "${COLLECTOR_RECEIVER_AGENT_PORT:-9991}:9991/udp"
- "${COLLECTOR_RECEIVER_METADATA_PORT:-9991}:9991/tcp" - "${COLLECTOR_RECEIVER_METADATA_PORT:-9991}:9991/tcp"
- "${COLLECTOR_RECEIVER_STAT_PORT:-9992}:9992/udp" - "${COLLECTOR_RECEIVER_STAT_PORT:-9992}:9992/udp"
- "${COLLECTOR_RECEIVER_SPAN_PORT:-9993}:9993/udp" - "${COLLECTOR_RECEIVER_SPAN_PORT:-9993}:9993/udp"
- "${COLLECTOR_RECEIVER_BASE_PORT:-9994}:9994"
- "${COLLECTOR_RECEIVER_STAT_UDP_PORT:-9995}:9995/tcp"
- "${COLLECTOR_RECEIVER_SPAN_UDP_PORT:-9996}:9996/tcp"
- "${COLLECTOR_RECEIVER_STAT_UDP_PORT:-9995}:9995/udp"
- "${COLLECTOR_RECEIVER_SPAN_UDP_PORT:-9996}:9996/udp"
environment: environment:
- SPRING_PROFILES=${SPRING_PROFILES} - SPRING_PROFILES=${SPRING_PROFILES}