Skip to content

Instantly share code, notes, and snippets.

View jboles31's full-sized avatar
😺

Jordan Boles jboles31

😺
  • San Diego, CA
View GitHub Profile

Proxy RPS

Set Up / Config Details

require('newrelic');
const express = require('express');
const app = express();
const path = require('path');
const cors = require('cors');
const bodyParser = require('body-parser');

Service RPS

Set Up / Config Details

require('dotenv').config();
const mongoose = require('mongoose');

let photosSchema = mongoose.Schema({
    listings: String,
 diningroom: String,
@jboles31
jboles31 / gist:859f2127f0205fe210fef0ee61e2aa90
Created June 10, 2019 23:28
Postgres Query Time and Samples
sdc_airbnb=# EXPLAIN ANALYZE SELECT * FROM bigboi WHERE id >= 400 and id < 405;
QUERY PLAN
----------------------------------------------------------------------------------------------------------------------
Index Scan using listing_id on bigboi (cost=0.43..9.86 rows=21 width=605) (actual time=0.016..0.019 rows=5 loops=1)
Index Cond: ((id >= 400) AND (id < 405))
Planning Time: 0.449 ms
Execution Time: 0.113 ms
(4 rows)
sdc_airbnb=# SELECT * FROM bigboi WHERE id >= 400 and id < 405;
@jboles31
jboles31 / apiCall.txt
Created May 17, 2019 22:14
Display of API call returning sample data
http://localhost:3003/descriptions
[
{
"id":1,
"name_":"La Sportiva Tarantulace Climbing Shoes",
"best_use":"Rock Climbing",
"climbing_show_type":"Neutral",
"last_":"Slip-Lasted",
"upper_":"Leather/synthetic leather",
module.exports = function(grunt){
grunt.initConfig({
jasmine: {
// ...
options: {
keepRunner: true
}
},
#include <Adafruit_NeoPixel.h>
Adafruit_NeoPixel strip_0 = Adafruit_NeoPixel(14, 9, NEO_GRB + NEO_KHZ800);
Adafruit_NeoPixel strip_1 = Adafruit_NeoPixel(14, 3, NEO_GRB + NEO_KHZ800);
Adafruit_NeoPixel strip_2 = Adafruit_NeoPixel(14, 5, NEO_GRB + NEO_KHZ800);
Adafruit_NeoPixel strip_3 = Adafruit_NeoPixel(14, 6, NEO_GRB + NEO_KHZ800);
Adafruit_NeoPixel strip_4 = Adafruit_NeoPixel(14, 10, NEO_GRB + NEO_KHZ800);
Adafruit_NeoPixel strip_5 = Adafruit_NeoPixel(14, 11, NEO_GRB + NEO_KHZ800);
//variable to keep track of state