Skip to content

Instantly share code, notes, and snippets.

@yhurski
yhurski / exportstats.go
Created April 17, 2024 20:28 — forked from 17twenty/exportstats.go
Simple example of using expvar to instrument Golang apps.
package exportstats
import (
"expvar"
"fmt"
"runtime"
)
var stats *expvar.Map
@yhurski
yhurski / README-Template.md
Created April 9, 2024 21:12 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@yhurski
yhurski / key-value-performance-test.md
Created July 4, 2019 11:51 — forked from stephan-nordnes-eriksen/key-value-performance-test.md
Performance testing different Key-Value stores in Ruby

For a project I am on I need to use a key-value store to converts file-paths to fixnum IDs. The dataset will typically be in the range of 100 000 to 1 000 000. These tests use 305 000 file paths to fixnum IDs.

The Different Key-Value stores tested are:

Daybreak: "Daybreak is a simple and very fast key value store for ruby" GDBM: GNU dbm. "a simple database engine for storing key-value pairs on disk." DBM: "The DBM class provides a wrapper to a Unix-style dbm or Database Manager library" PStore: "PStore implements a file based persistence mechanism based on a Hash. "

Out of these, all except Daybreak are in the Ruby standard library.