Skip to content

Instantly share code, notes, and snippets.

View npm_error.txt
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'run', 'test' ]
2 info using npm@3.10.8
3 info using node@v6.8.1
4 verbose run-script [ 'pretest', 'test', 'posttest' ]
5 info lifecycle react-redux-starter-kit@3.0.0-alpha.2~pretest: react-redux-starter-kit@3.0.0-alpha.2
6 silly lifecycle react-redux-starter-kit@3.0.0-alpha.2~pretest: no script for pretest, continuing
7 info lifecycle react-redux-starter-kit@3.0.0-alpha.2~test: react-redux-starter-kit@3.0.0-alpha.2
8 verbose lifecycle react-redux-starter-kit@3.0.0-alpha.2~test: unsafe-perm in lifecycle true
9 verbose lifecycle react-redux-starter-kit@3.0.0-alpha.2~test: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/home/jz/realestate-client/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
View create_env.txt
mkdir snapshot-env
virtualenv snapshot-env/
cd snapshot-env/
source bin/activate
pip install nodeenv
nodeenv --node=4.2.6 --prebuilt node/
deactivate
git clone https://github.com/prerender/prerender.git
source node/bin/activate
cd prerender
View .env
export PORT=35292
export PRERENDER_SERVICE_URL='http://localhost:35292/'
export PHANTOMJS_PORT=35294
export PHANTOM_CLUSTER_NUM_WORKERS=5
export PHANTOM_WORKER_ITERATIONS=10
export CACHE_ROOT_DIR="~/snapshot-env/prerender/filecache/"
export CACHE_LIVE_TIME=7200
PHANTOM_CLUSTER_MESSAGE_TIMEOUT=800
export LANGUAGE=en_US.UTF-8
export LANG=en_US.UTF-8
View demoserver.js
#!/usr/bin/env node
var prerender = require('./lib');
var server = prerender({
workers: process.env.PHANTOM_CLUSTER_NUM_WORKERS,
iterations: process.env.PHANTOM_WORKER_ITERATIONS,
logRequests: true
});
@amergin
amergin / npm install.log
Created May 25, 2016
Issue with setting up prerender
View npm install.log
(snapshot-env)jz@lakka:~/snapshot-env/prerender$ rm -rf node_modules/
(snapshot-env)jz@lakka:~/snapshot-env/prerender$ npm install
npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade
npm WARN deprecated graceful-fs@2.0.3: graceful-fs v3.0.0 and before will fail on node releases >= v7.0. Please update to graceful-fs@^4.0.0 as soon as possible. Use 'npm ls graceful-fs' to find it in the tree.
> phantomjs-prebuilt@2.1.7 install /home/users/jz/snapshot-env/prerender/node_modules/phantomjs-prebuilt
> node install.js
PhantomJS not found on PATH
Download already available at /tmp/phantomjs/phantomjs-2.1.1-linux-x86_64.tar.bz2
@amergin
amergin / angular-packery.js
Created Aug 6, 2014
Angular-masonry fork for Packery.js
View angular-packery.js
/*!
* angular-packery
* Forked from angular-masonry (Pascal Hartig, weluse GmbH, http://weluse.de/)
*/
(function () {
'use strict';
angular.module('wu.packery', []).controller('PackeryCtrl', [
'$scope',
'$element',
'$timeout',
@amergin
amergin / vmstat_idle_3min.txt
Created Jan 1, 2013
timeout 3m vmstat 3 > ~/vmstat_loading_3min.txt
View vmstat_idle_3min.txt
procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 175424 6648152 656812 17511332 0 0 38 20 0 0 1 1 98 0 0
1 0 175424 6648136 656812 17511336 0 0 0 4 3436 21147 1 2 97 0 0
0 0 175424 6648136 656816 17511336 0 0 0 11 3361 21589 1 2 97 0 0
0 0 175424 6648136 656816 17511336 0 0 0 5 3418 21793 1 2 97 0 0
0 0 175424 6648136 656816 17511336 0 0 0 4 3687 21588 1 2 97 0 0
0 0 175424 6648136 656816 17511344 0 0 3 16 3599 21750 1 2 97 0 0
0 0 175424 6647988 656820 17511348 0 0 0 21 3850 22033 1 2 97 0 0
0 0 175424 6647988 656820 17511348 0 0 0 3 3926 21425 1 2 96 0 0
@amergin
amergin / vmstat_loading.txt
Created Jan 1, 2013
vmstat while warming the graph.
View vmstat_loading.txt
procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 175424 7509264 656956 17513120 0 0 38 20 0 0 1 1 98 0 0
1 0 175424 7487780 656968 17517780 0 0 1651 0 5169 22462 5 4 88 4 0
1 0 175424 7450576 656976 17518080 0 0 5 156 7185 24458 21 3 76 0 0
1 0 175424 7453236 656976 17518080 0 0 0 168 5435 22729 12 4 83 0 0
1 0 175424 7428040 656984 17518080 0 0 0 4 5201 20206 13 3 84 0 0
9 0 175424 7370016 656984 17518080 0 0 0 12 7874 21739 25 4 71 0 0
3 0 175424 7312612 656988 17518084 0 0 1 11 7502 22395 22 4 73 0 1
2 0 175424 7277488 656988 17518084 0 0 0 47 7545 23143 26 5 69 0 1
@amergin
amergin / messages.log
Created Dec 31, 2012
messages.log, relevant parts
View messages.log
2012-12-31 00:23:14.528+0000 INFO [o.n.k.i.DiagnosticsManager]: --- INITIALIZED diagnostics START ---
2012-12-31 00:23:14.529+0000 INFO [o.n.k.i.DiagnosticsManager]: Neo4j Kernel properties:
2012-12-31 00:23:14.532+0000 INFO [o.n.k.i.DiagnosticsManager]: neostore.propertystore.db.mapped_memory=3000M
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: cache_type=gcr
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: read_only=true
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: use_memory_mapped_buffers=true
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: neostore.nodestore.db.mapped_memory=50M
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: ha.pull_interval=10
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: neostore.relationshipstore.db.mapped_memory=1200M
2012-12-31 00:23:14.533+0000 INFO [o.n.k.i.DiagnosticsManager]: neostore.propertystore.db.strings.mapped_memory=1000M
@amergin
amergin / dump_after_warming_idle.txt
Created Dec 31, 2012
jstack after warming the cache, at idle, CPU ~33%.
View dump_after_warming_idle.txt
2012-12-31 02:25:57
Full thread dump Java HotSpot(TM) 64-Bit Server VM (20.10-b01 mixed mode):
"Attach Listener" daemon prio=10 tid=0x00007ff318003800 nid=0x63fe waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"712944945@qtp-2058324786-3" prio=10 tid=0x00007ff2a8003800 nid=0x63d0 in Object.wait() [0x00007ff25502e000]
java.lang.Thread.State: TIMED_WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000005202a9ef0> (a org.mortbay.thread.QueuedThreadPool$PoolThread)