Skip to content

Instantly share code, notes, and snippets.

strikeout

Block or report user

Report or block strikeout

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@strikeout
strikeout / README.md
Created Aug 10, 2019 — forked from magnetikonline/README.md
Setting Nginx FastCGI response buffer sizes.
View README.md
@strikeout
strikeout / BitMEX Jazz BEEP
Last active Jun 24, 2019
Aural indication of XBTUSD price movements via BitMEX websocket realtime-trade data. Uses the blues scale to add some funk to your trading. Copy & paste into your browser's console..
View BitMEX Jazz BEEP
/**
* BitMEX JAZZ BEEP
*
* Aural indication of XBTUSD price movements via BitMEX websocket realtime-trade data.
* Uses the blues scale to add some funk to your trading.
*
*/
var options = {
@strikeout
strikeout / market.js
Created Jun 28, 2016 — forked from maxant/market.js
Files for creating a trading engine with Node.js.
View market.js
// /////////////////////////////////////////////////
// this file contains all the classes related to a
// market.
// /////////////////////////////////////////////////
var log4js = require('log4js');
var logger = log4js.getLogger(require('path').basename(__filename, '.js'));
require('es6-collections');
var _ = require('underscore');
/**
View dmp.php
<?
/**
* Debug helper function. This is a wrapper for var_dump() that adds
* the <pre /> tags, cleans up newlines and indents, and runs
* htmlentities() before output.
*
* @param mixed $var The variable to dump.
* @param string $label OPTIONAL Label to prepend to output.
* @param bool $echo OPTIONAL Echo output if true.
* @return string
@strikeout
strikeout / addHostToMongoReplicaset.sh
Created Oct 8, 2015
Adds own host to a mongo replica-set. Runs on server-startup
View addHostToMongoReplicaset.sh
#!/usr/bin/env bash
#get own hostname
ME=$(hostname);
# find replica-set master, we think its the first in the array
MASTER=`mongo --quiet --eval "cfg=rs.config(); print( cfg.members[0].host );"`
# connect to master, add ME
mongo --host $MASTER --eval "print( rs.add('"$ME"') );"
@strikeout
strikeout / sites-enabled__app.conf
Last active Aug 29, 2015
Nginx vhost config for Meteor with working websockets
View sites-enabled__app.conf
server {
server_name thomassteinhauer.com;
location / {
root /var/www/app/bundle/;
}
location /admin {
root /var/www/admin/bundle/;
}
@strikeout
strikeout / gist:cfa3c6d009e85a0c78d0
Created Feb 26, 2015
Apache vhost config for Meteor with working websockets
View gist:cfa3c6d009e85a0c78d0
<VirtualHost 10.248.206.19:80>
ServerName some.domain.com
ProxyRequests Off
ProxyPreserveHost On
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
View Price-Time Matching Engine.c
/*****************************************************************************
* QuantCup 1: Price-Time Matching Engine
*
* Submitted by: voyager
*
* Design Overview:
* In this implementation, the limit order book is represented using
* a flat linear array (pricePoints), indexed by the numeric price value.
* Each entry in this array corresponds to a specific price point and holds
* an instance of struct pricePoint. This data structure maintains a list
View Price-Time Matching Engine.c
/*****************************************************************************
* QuantCup 1: Price-Time Matching Engine
*
* Submitted by: voyager
*
* Design Overview:
* In this implementation, the limit order book is represented using
* a flat linear array (pricePoints), indexed by the numeric price value.
* Each entry in this array corresponds to a specific price point and holds
* an instance of struct pricePoint. This data structure maintains a list
@strikeout
strikeout / cluster_observeChanges.js
Created Jan 9, 2014
please help me with my flawed logic on how to observeChanges in a clustered multi-server environment (with oplog-scaling).
View cluster_observeChanges.js
// 200k entries and more
HugeCollection = new Meteor.Collection("HugeCollection");
// convenience collection to hold the computed stats of HugeCollection
StatsForHugeCollection = new Meteor.Collection("StatsForHugeCollection");
/**
* Observer
*/
You can’t perform that action at this time.