{"id":19458488,"url":"https://github.com/postgrespro/pg_ycsb","last_synced_at":"2025-02-25T11:42:40.529Z","repository":{"id":73853211,"uuid":"114218654","full_name":"postgrespro/pg_ycsb","owner":"postgrespro","description":"YCSB-like benchmark for pgbench","archived":false,"fork":false,"pushed_at":"2017-12-18T09:06:12.000Z","size":8,"stargazers_count":15,"open_issues_count":1,"forks_count":4,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-02-22T17:12:34.448Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PLpgSQL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/postgrespro.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-12-14T07:43:01.000Z","updated_at":"2024-04-26T13:36:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"ed69ba95-1fd9-489c-ac70-0761c5d7fdc5","html_url":"https://github.com/postgrespro/pg_ycsb","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postgrespro%2Fpg_ycsb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postgrespro%2Fpg_ycsb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postgrespro%2Fpg_ycsb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/postgrespro%2Fpg_ycsb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/postgrespro","download_url":"https://codeload.github.com/postgrespro/pg_ycsb/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240662852,"owners_count":19837369,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T17:27:17.747Z","updated_at":"2025-02-25T11:42:40.470Z","avatar_url":"https://github.com/postgrespro.png","language":"PLpgSQL","funding_links":[],"categories":[],"sub_categories":[],"readme":"[WIP]\n\n# pg_ycsb\n\npg_ycsb implements basic YCSB-like workloads designed specifically to be run with pgbench.\n\n## What is YCSB\n\n[YCSB](https://github.com/brianfrankcooper/YCSB) is a framework and common set of workloads for performance evaluating of different kinds of database systems.\n\n## Workloads\n\n* **workload A**\n   Update heavy workload. Example: session store recording recent actions.\n   50% reads, 50% updates\n\n* **workload B**\n   Read mostly workload. Example: photo tagging; add a tag is an update, but most operations are to read tags.\n   95% reads, 5% updates\n\n* **workload C**\n   Read only. Example: user profile cache, where profiles are constructed elsewhere.\n   100% reads\n\n* **workload D**\n   Read latest workload. Example: user status updates; people want to read the latest.\n   95% reads, 5% inserts (WIP)\n\n* **workload E**\n   Short ranges. Example: threaded conversations, where each scan is for the posts in a given thread.\n   95% scans, 5% inserts (WIP)\n\n* **workload F**\n   Read-modify-write workload. Example: user database, where user records are read and modified by the user or to record user activity.\n   50% reads, 50% inserts (WIP)\n\n## Why use pgbench?\n\npgbench is a lightweight and flexible framework and usually goes with PostgreSQL. By default it performs TPC-B like benchmarks and widely used across developers. But in some cases default scripts fail to provide comprehensive measurements. pg_ycsb is a set of scripts which enables developers to run YCSB-like workloads with pgbench and using pgbench's default table set.\n\n## Using\n\nFull documentation on pgbench can be found in [official documentation](https://www.postgresql.org/docs/current/static/pgbench.html). The most important options are:\n\n`-f filename@weight`\nAdd script to the list of executed scripts and `weight` represents probability of the execution of this script.\n\n`-T seconds`\nTotal time of execution.\n\n`-c clients`\nNumber of concurrent clients.\n\n**Workload A:**\n```\npgbench postgres -f scripts/zipfian/read.sql@50 -f scripts/zipfian/update.sql@50 -T60 -c10\n```\n\n**Workload B:**\n```\npgbench postgres -f scripts/zipfian/read.sql@95 -f scripts/zipfian/update.sql@5 -T60 -c10\n```\n\n**Workload C:**\n```\npgbench postgres -f scripts/zipfian/read.sql -T60 -c10\n```\n\n**Workload D:**\n\nNot implemented yet.\n\n**Workload E:**\n```\npgbench postgres -f scripts/zipfian/scan.sql@95 -f scripts/uniform/insert.sql@5 -T60 -c10\n```\n\n**Workload F:**\n\nNot implemented yet.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpostgrespro%2Fpg_ycsb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpostgrespro%2Fpg_ycsb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpostgrespro%2Fpg_ycsb/lists"}