frostfs-s3-gw/docs/playback.md
Nikita Zinkevich 62615d7ab7 [#369] Request reproducer
Signed-off-by: Nikita Zinkevich <n.zinkevich@yadro.com>
2024-09-11 15:25:09 +03:00

2.8 KiB

FrostFS S3 Playback

Playback is a tool to reproduce queries to frostfs-s3-gw in dev environment. Network logs could be gathered from s3-gw via HTTP Logger which could be enabled on build with loghttp build tag and http_logging.enabled option set to true in s3-gw configuration.

Commands

run - reads log file and reproduces send requests from it to specified endpoint

Example

frostfs-s3-playback --config <config_path> run [--endpoint=<endpoint>] [--log=<log_path>]

Configuration

Playback accepts configuration file path in yaml with corresponding options:

endpoint: http://localhost:8084
log: ./request.log
env: .env
credentials:
  access_key: CAtUxDSSFtuVyVCjHTMhwx3eP3YSPo5ffwbPcnKfcdrD06WwUSn72T5EBNe3jcgjL54rmxFM6u3nUAoNBps8qJ1PD
  secret_key: 560027d81c277de7378f71cbf12a32e4f7f541de724be59bcfdbfdc925425f30
http_timeout: 60s
skip_verify_tls: true

Configuration path is passed via required --config flag. If corresponding flag is set, it overrides parameter from config.

Configuration parameters

Global parameters

Config parameter name Flag name Type Default value Description
- config string - config file path (e.g. ./config/playback.yaml)
http_timeout http-timeout duration 60s http request timeout
skip_verify_tls skip-verify-tls bool false skips tls certificate verification for https endpoints
credentials.accessKey - string - AWS access key id
credentials.secretKey - string - AWS secret key
print_response_limit - int 1024 max response length to be printed in stdout, the rest of body will be omitted

run command parameters

Config parameter name Flag name Type Default value Description
endpoint endpoint string - s3-gw endpoint URL
log log string ./request.log path to log file, could be either absolute or relative