Skip to content

Instantly share code, notes, and snippets.

Peter K. Shultz pkshultz

Block or report user

Report or block pkshultz

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
View keybase.md

Keybase proof

I hereby claim:

  • I am pkshultz on github.
  • I am pkshultz (https://keybase.io/pkshultz) on keybase.
  • I have a public key ASA2ihGPq1uybkPVYmOSZ6caheYixamsdTc-JZWTS_qmQAo

To claim this, I am signing this object:

@pkshultz
pkshultz / scalability.txt
Created Sep 4, 2015
Discussion in https://gitter.im/lightning-viz/lightning regarding the scalability of Lightning in a production environment
View scalability.txt
deardooley 00:13
Hi guys, does anyone have experience running this in production use cases? What kind of performance considerations should be thought through prior to loading the service up? What are some practical constraints on the datasets the server can process and store?
mathisonian 00:42
hey @deardooley, i think it really depends on what scale we are talking about. in general setting ```NODE_ENV=production``` and configuring it to use a postgres database will do some performance optimizations for production use
at this stage the basic constraints would be data ingesting / and storage, again depending on your use case
it may be enough that a beefy postgres instance is fine with what you need to throw at it, or other backends could be explored
there are a few ways to scale out the server itself to if the amount of requests going in/out becomes the actual issue
im happy to discuss anything in more detail, lmk
@pkshultz
pkshultz / another-scatter-3-POST.txt
Last active Sep 1, 2015
Another attempted POST
View another-scatter-3-POST.txt
POST /sessions/6b066e1d-5f24-4aaf-96de-8bdd0a80acef/visualizations HTTP/1.1
Host: morning-reef-9589.herokuapp.com
Content-Type: application/json
Cache-Control: no-cache
{ "type": "scatter-3", "data":[[94, 12, 28], [34, 97, 67], [124, 68, 20], [102, 101, 25], [115, 57, 138], [138, 69, 144], [141, 64, 27], [11, 112, 92], [33, 35, 43], [128, 102, 141], [31, 52, 80], [58, 81, 117], [75, 74, 136], [20, 124, 57], [14, 84, 7], [22, 118, 126], [31, 103, 67], [114, 18, 69], [84, 66, 17], [37, 26, 36], [13, 61, 22], [130, 106, 30], [115, 75, 15], [141, 101, 35], [93, 90, 73], [102, 59, 147], [88, 65, 14], [67, 141, 73], [107, 3, 53], [120, 35, 29]], "color": [[14, 100, 167], [166, 244, 37], [53, 213, 117], [244, 210, 145], [110, 103, 148], [116, 26, 59], [35, 237, 214], [208, 86, 63], [100, 76, 248], [216, 145, 7], [244, 84, 231], [12, 154, 252], [196, 105, 221], [90, 162, 127], [94, 221, 134], [105, 70, 67], [40, 251, 69], [137, 4, 43], [90, 173, 164], [242, 15, 187], [47, 3, 22], [146, 37, 170], [192, 153, 190], [21
@pkshultz
pkshultz / scatter-3-POST.txt
Created Sep 1, 2015
An attempted POST to Lightning Viz Server
View scatter-3-POST.txt
POST /sessions/81282108-8b93-45b2-9c4a-da87764721cb/visualizations HTTP/1.1
Host: morning-reef-9589.herokuapp.com
Content-Type: application/json
Cache-Control: no-cache
{ "type": "scatter-3", "size": [4], "label": [0, 3, 2, 3, 4, 1, 1, 3, 1, 2, 3, 4, 1, 2, 2, 1, 4, 2, 2, 0, 2, 3, 2, 1, 3, 2, 2, 3, 2, 0, 2, 1, 0, 3, 2, 1, 0, 3, 3, 0, 0, 4, 0, 2, 2, 3, 2, 0, 4, 4, 4, 4, 3, 3, 2, 4, 0, 0, 2, 4, 2, 0, 1, 2, 2, 3, 1, 0, 2, 4, 0, 3, 3, 2, 1, 3, 0, 2, 2, 2, 1, 0, 0, 1, 2, 2, 1, 0, 0, 0, 4, 0, 3, 3, 1, 4, 0, 4, 3, 3, 4, 1, 2, 2, 4, 0, 1, 4, 3, 2, 3, 1, 1, 2, 2, 4, 2, 3, 2, 1, 0, 1, 0, 4, 0, 0, 0, 1, 2, 2, 0, 3, 0, 1, 1, 0, 3, 2, 4, 2, 0, 2, 4, 4, 4, 1, 3, 2, 0, 0, 4, 2, 0, 4, 2, 3, 1, 2, 1, 3, 3, 2, 2, 2, 2, 0, 0, 1, 4, 4, 2, 1, 0, 4, 1, 4, 3, 4, 1, 1, 3, 1, 2, 2, 1, 0, 1, 1, 0, 1, 0, 2, 3, 4, 1, 4, 4, 4, 1, 4, 0, 2, 4, 2, 1, 0, 1, 2, 2, 3, 4, 2, 0, 2, 0, 1, 2, 2, 1, 3, 2, 2, 1, 2, 4, 4, 1, 3, 2, 4, 0, 2, 3, 4, 3, 4, 3, 2, 1, 0, 2, 2, 4, 1, 3, 2, 1, 1, 3, 0, 3, 4, 4, 0, 0, 0, 4, 1, 1, 2, 2, 1, 1, 4, 0, 2, 1, 4, 4, 3
@pkshultz
pkshultz / heroku-build.log
Last active Aug 29, 2015
Failed Heroku build of the Lightning Visualization server.
View heroku-build.log
-----> Fetching custom git buildpack... done
-----> Node.js app detected
-----> Requested node range: 0.10.x
-----> Resolved node version: 0.10.40
-----> Downloading and installing node
-----> Exporting config vars to environment
-----> Installing dependencies
npm WARN deprecated lingo@0.0.5: This project is abandoned
npm WARN engine hawk@0.10.2: wanted: {"node":"0.8.x"} (current: {"node":"0.10.40","npm":"1.4.28"})
@pkshultz
pkshultz / graphite.md
Created Aug 23, 2015 — forked from relaxdiego/graphite.md
Installing Graphite in OS X Mavericks
View graphite.md

Follow these steps to install graphite on OS X Mavericks.

Prerequisites

  • Homebrew
  • Python 2.7
  • Git

Install dependencies

Install Cairo and friends

View example.alert.beacon
//Example JSON alert entry (comments are allowed; Graphite-Beacon strips them)
{
// (required) Alert name
"name": "Example Alert Name",
// (required) Alert query
"query": "carbon.local.prototype.example.metric.query",
// (optional) Alert type (graphite, url)
"source": "graphite",
View example.jmxtrans
{
"servers" : [ {
"host" : "w2",
"port" : "1099",
"queries" : [ {
"obj" : "net.sf.ehcache:type=CacheStatistics,*",
"attr" : [ "CacheHits", "CacheMisses", "ObjectCount" ],
"outputWriters" : [ {
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriter",
"settings" : {
@pkshultz
pkshultz / ios-app-talk
Created Mar 30, 2015
iOS Application Talk
View ios-app-talk
- Chief idea about iOS development: user experience.
- Algorithms and security play a part, to be sure, but user experience is paramount.
- Model-View-Controller
- Take all of the objects in the application and divide them into 3 parts:
- Model
- Data
@pkshultz
pkshultz / sieve.java
Created Mar 26, 2015
Sieve of Eratosthenes
View sieve.java
// Sieve of Eratosthenes
public int sieve_of_eratosthenes(int input)
{
boolean [] is_prime = new boolean [input];
int number_of_primes = 0;
// Set all values to true
Arrays.fill(is_prime, Boolean.TRUE)
You can’t perform that action at this time.