Skip to content

Create Jenkins Job to test Binlog Server docker image - #1202

Merged
kaushikpuneet07 merged 81 commits into
Percona-QA:masterfrom
kaushikpuneet07:binlog-docker
Aug 25, 2026
Merged

Create Jenkins Job to test Binlog Server docker image#1202
kaushikpuneet07 merged 81 commits into
Percona-QA:masterfrom
kaushikpuneet07:binlog-docker

Conversation

@kaushikpuneet07

@kaushikpuneet07 kaushikpuneet07 commented Aug 24, 2026

Copy link
Copy Markdown
Collaborator
tests/test_binlog_server_fetch.py::TestBinlogServerFetch::test_fetch_streams_binlogs PASSED [ 10%]
tests/test_binlog_server_fetch.py::TestBinlogServerFetch::test_list_shows_fetched_binlogs PASSED [ 20%]
tests/test_binlog_server_gtid.py::TestBinlogServerGtid::test_fetch_streams_binlogs_in_gtid_mode PASSED [ 30%]
tests/test_binlog_server_gtid.py::TestBinlogServerGtid::test_search_by_gtid_set PASSED [ 40%]
tests/test_binlog_server_inspect.py::TestBinlogServerInspect::test_search_by_timestamp PASSED [ 50%]
tests/test_binlog_server_inspect.py::TestBinlogServerInspect::test_purge_binlogs PASSED [ 60%]
tests/test_binlog_server_pull.py::TestBinlogServerPull::test_pull_streams_new_binlogs_without_restart PASSED [ 70%]
tests/test_binlog_server_static.py::TestBinlogServerStatic::test_version PASSED [ 80%]
tests/test_binlog_server_static.py::TestBinlogServerStatic::test_usage PASSED [ 90%]
tests/test_binlog_server_static.py::TestBinlogServerStatic::test_runs_as_unprivileged_user PASSED [100%]

kaushikpuneet07 and others added 30 commits March 7, 2025 21:40
kaushikpuneet07 and others added 24 commits May 26, 2026 23:23
Smoke tests against a standalone Percona Server source: binlog_server
version/usage, and a fetch-mode/file-backend run that creates a
REPLICATION SLAVE user, generates data, and checks binlog files land
in local storage and are reported by `binlog_server list`. Pull mode
and the S3 backend are not covered yet.
They were committed without the executable bit, so the Jenkins job
failed with "Permission denied" on ./run.sh.
logger.file was a relative path ("binsrv.log"), which resolves against
the container's cwd (/, not writable by the unprivileged pbs user) and
made binlog_server crash before it even attempted the connection.
Point it at /var/log/binlog-server, which the image already creates
and chowns to that user.
Adds three test files alongside the existing position-mode fetch test:
- test_binlog_server_gtid.py: fetch + search_by_gtid_set against a
  gtid_mode=ON source, using its real gtid_executed value.
- test_binlog_server_pull.py: long-running pull mode, checking the
  storage directory grows from live data without restarting it.
- test_binlog_server_inspect.py: search_by_timestamp and purge_binlogs
  against an already-fetched, multi-file storage directory.

S3/MinIO storage is intentionally out of scope. Factored the
run-one-binlog_server-container logic shared by all of these into
pbs_helpers.py (existing test_binlog_server_fetch.py updated to use it
too instead of its own copy).
mysql -p<password> on the command line prints an "insecure password"
warning to stderr, which exec_run merges into stdout. That warning was
getting prepended to the parsed gtid_executed value, so binlog_server
rejected it as an unparsable GTID set. Pass the password via MYSQL_PWD
instead to avoid the warning entirely.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@kaushikpuneet07 kaushikpuneet07 changed the title Binlog docker Create Jenkins Job to test Binlog Server docker image Aug 25, 2026

@ParveezBaig ParveezBaig left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Puneet,

Changes looks good. minor suggestions below.

Thanks,

Comment thread docker-image-tests/binlog-server/tests/test_binlog_server_pull.py Outdated
Comment thread docker-image-tests/binlog-server/tests/test_binlog_server_gtid.py
…of sleep in pull test

- test_binlog_server_gtid.py: add list, search_by_timestamp, and
  purge_binlogs coverage for gtid mode, mirroring the existing
  position-mode tests. The gtid_source fixture now rotates the binlog
  a few times so purge_binlogs has more than one file to work with.
- test_binlog_server_pull.py: replace the fixed 20s sleep with polling
  the storage directory size (0.5s interval, 20s timeout) so the test
  returns as soon as pull mode picks up the new binlog data instead of
  always waiting out the full timeout.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@kaushikpuneet07
kaushikpuneet07 merged commit dfce8e1 into Percona-QA:master Aug 25, 2026
@kaushikpuneet07
kaushikpuneet07 deleted the binlog-docker branch August 25, 2026 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants