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
@pkshultz
pkshultz / gist:f947ffd80f29e7452c0e
Created Aug 26, 2015
Heroku "View Session" 500
View gist:f947ffd80f29e7452c0e
2015-08-26T16:51:26.421892+00:00 heroku[router]: at=info method=GET path="/sessions/13/feed/" host=lightning-visualization.herokuapp.com request_id=12823398-9089-47e2-adf9-40d62b47c87f fwd="173.63.221.177" dyno=web.1 connect=1ms service=136ms status=500 bytes=886
2015-08-26T16:51:26.408763+00:00 app[web.1]: line
2015-08-26T16:51:26.408823+00:00 app[web.1]: line
2015-08-26T16:51:26.408853+00:00 app[web.1]: line
2015-08-26T16:51:26.408880+00:00 app[web.1]: line
2015-08-26T16:51:26.408911+00:00 app[web.1]: line
2015-08-26T16:51:26.408934+00:00 app[web.1]: line
2015-08-26T16:51:26.408973+00:00 app[web.1]: null
2015-08-26T16:51:26.408997+00:00 app[web.1]: line
2015-08-26T16:51:26.409049+00:00 app[web.1]: line
@pkshultz
pkshultz / view-visualization-error.log
Last active Aug 27, 2015
View Visualization Error (Heroku)
View view-visualization-error.log
2015-08-27T15:12:28.781616+00:00 heroku[router]: at=info method=POST path="/sessions/16/visualizations" host=lightning-visualization.herokuapp.com request_id=6be4dae6-3495-4ee6-8cca-c6f0fb1fb7ab fwd="173.63.221.177" dyno=web.1 connect=1ms service=80ms status=200 bytes=510
2015-08-27T15:12:33.024577+00:00 heroku[router]: at=info method=GET path="/images/lightning.svg" host=lightning-visualization.herokuapp.com request_id=7288e92c-95b4-4cf2-9101-6cfb75d0231c fwd="173.63.221.177" dyno=web.1 connect=1ms service=5ms status=304 bytes=237
2015-08-27T15:12:32.859610+00:00 app[web.1]: TypeError: /app/app/views/session/visualization-iframe.jade:12
2015-08-27T15:12:32.859616+00:00 app[web.1]: 10|
2015-08-27T15:12:32.859619+00:00 app[web.1]: 11| .full-screen.feed-item-container(data-model="visualization", data-model-id="#{viz.id}")
2015-08-27T15:12:32.859621+00:00 app[web.1]: > 12| .feed-item(data-type="#{viz.type}", data-data="#{ JSON.stringify(viz.getInitialData(vizTypes[viz.type])) }", data-imag
View gist:46db4e99e3f45b093a62
Notes: Objective-C Syntax
Date: October 10, 2014
Description: Described NSLog(), strings, and function instantiation.
NSLog(): Similar to a print statement, or "cout" in C++. Prints data given within the parentheses
to the XCode Console.
Example: NSLog(@"Doing okay thus far"); prints "Doing okay thus far"
Strings: Data type that holds multiple characters. In Objective-C, strings are made by putting an
@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)
@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
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 / 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

@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 / 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
You can’t perform that action at this time.