Skip to content

jonrangel/mongodb-workload-generator

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

Overview
=============
This project contains workloads for use in scale & performance testing. 
Tests are built using https://github.com/cgoldberg/multi-mechanize 
You should follow the instructions there to install and setup multimechanize before using these tests. 

This project is organized into different categories of workloads, along with different implementations 
of each workload. 

Setup instructions for Mac OS X 
================================

sudo pip install -U multi-mechanize
brew install pkg-config
brew install libpng
brew install freetype
export LDFLAGS="-L/usr/X11/lib"
export CFLAGS="-I/usr/X11/include -I/usr/X11/include/freetype2 -I/usr/X11/include/libpng12"
sudo pip install matplotlib

Running a workload
==================
1) cd into the workload directory (e.g. "cd inbox") 
2) edit the config file for the workload implementation you want to run (e.g. inbox/fanout-on-write/config.cfg)
3) multimech-run <workload-name> (e.g. multimech-run fanout-on-write)
4) results are stored in the results directory of the implementation (e.g. inbox/fanout-on-write/results)

Workloads
=========

Inbox Workload
--------------

The inbox workload is one in which you have a number of users who send & receive messages. The primary
interactions are sending messages, and reading messages. We provide 3 different inbox workloads.

1) Fan out on read 
This is the naive approach to an inbox. Sending a message involves writing that message to the database. Reading an inbox requires finding all of the messages where the user's id is in the "to" field and sorting by time. 

2) Fan out on write 
Sending a message involves making a copy of the message for each recipient. Reading an inbox still requires finding all of the messages where the user's id is in the "owner" field, but we expect better locality of reads across shards. 

3) Bucketed fan out on write. 
Sending a message involves pushing the message onto an array field in the user's "inbox" document for each recipient in the message". Reading the inbox involves fetching just the inbox document which contains the messages in sorted order. This model exhibits better data locality on a single node. 


About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published