Skip to content

Instantly share code, notes, and snippets.

💭
The mess cannot go into the program, it piles up around the programmer.

Sam Pullara spullara

💭
The mess cannot go into the program, it piles up around the programmer.
Block or report user

Report or block spullara

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 gist:304434
package com.sampullara.twitter.track;
import com.espertech.esper.client.*;
import com.sampullara.twitter.JsonNodeMap;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
View gist:331602
private static long REFERENCE = System.nanoTime();
...
SimpleDateFormat dateKey = new SimpleDateFormat("yyyyMMddHHmmss");
String delta = String.valueOf(System.nanoTime() - REFERENCE);
byte[] timestamp = $(dateKey.format(date) + delta.substring(delta.length() - 9));
View gist:339617
diff --git a/src/node-supervisor.c b/src/node-supervisor.c
index 3e807d2..5569489 100644
--- a/src/node-supervisor.c
+++ b/src/node-supervisor.c
@@ -1,11 +1,16 @@
#define NODE_SUPERVISOR "/usr/local/lib/node-supervisor/cli-wrapper.js"
#include <unistd.h>
+#include <stdlib.h>
int main (int argc, char** argv) {
- return execl(
View gist:387648
macpro:npm sam$ make
node install-npm.js
TypeError: Cannot call method 'error' of undefined
at Object.<anonymous> (/Volumes/Data/Software/src/npm/lib/utils/ini.js:22:7)
at Module._compile (node.js:639:23)
at Module._loadScriptSync (node.js:651:16)
at Module.loadSync (node.js:550:10)
at loadModule (node.js:495:16)
at require (node.js:618:12)
at Object.<anonymous> (/Volumes/Data/Software/src/npm/npm.js:5:11)
View gist:387658
node install-npm.js
*
* Warning: Cipher unavailable in this nodejs version (v0.1.91-15-g39464b4)
* Username/password stored in the clear
*
TypeError: Object prototype may only be an Object or null
at Function.create (native)
at Object.<anonymous> (/Volumes/Data/Software/src/npm/npm.js:42:21)
at Module._compile (node.js:639:23)
at Module._loadScriptSync (node.js:651:16)
View gist:387736
var sys = require("sys");
var fab = require('./lib/fab');
var mu = require('./lib/Mu/lib/mu');
mu.templateRoot = './templates';
(fab)
(fab.listen, 0xFAB)
(/^\/$/)
View gist:411321
2010-05-23 15:43:00,636 INFO org.apache.hadoop.hbase.master.BaseScanner: RegionManager.metaScanner scanning meta region {server: 10.211.55.7:60020, regionname: .META.,,1, startKey: <>}
2010-05-23 15:43:00,647 DEBUG org.apache.hadoop.hbase.master.BaseScanner: Current assignment of item,,1274235159640 is not valid; serverAddress=, startCode=0 unknown.
2010-05-23 15:43:00,652 INFO org.apache.hadoop.hbase.master.BaseScanner: RegionManager.metaScanner scan of 3 row(s) of meta region {server: 10.211.55.7:60020, regionname: .META.,,1, startKey: <>} complete
2010-05-23 15:43:00,653 INFO org.apache.hadoop.hbase.master.BaseScanner: All 1 .META. region(s) scanned
2010-05-23 15:43:00,875 INFO org.apache.hadoop.hbase.master.RegionManager: Assigning region item,,1274235159640 to hbase,60020,1274653326052
2010-05-23 15:43:00,880 INFO org.apache.hadoop.hbase.master.ServerManager: Processing MSG_REPORT_OPEN: item,,1274235159640 from hbase,60020,1274653326052; 1 of 1
2010-05-23 15:43:00,881 DEBUG org.apache.hadoop.hbase.maste
View gist:411326
hbase(main):028:0> get '.META.', 'item,,1274235159640'
COLUMN CELL
info:regioninfo timestamp=1274653782811, value=REGION => {NAME => 'item,,1274235159640', STARTKEY
=> '', ENDKEY => '', ENCODED => 1594705793, TABLE => {{NAME => 'item', FAMILIES
=> [{NAME => 'accessories', COMPRESSION => 'LZO', VERSIONS => '1', TTL => '214748
3647', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}, {NAME =
> 'browsenode', COMPRESSION => 'LZO', VERSIONS => '1', TTL => '2147483647', BLOCK
SIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}, {NAME => 'editorial
review', COMPRESSION => 'LZO', VERSIONS => '1', TTL => '2147483647', BLOCKSIZE =>
'65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'
View gist:411329
hbase(main):029:0> status 'detailed'
version 0.20.4
0 regionsInTransition
1 live servers
hbase:60020 1274653326052
requests=0, regions=5, usedHeap=39, maxHeap=995
category,,1274234496204
stores=7, storefiles=7, storefileSizeMB=0, memstoreSizeMB=0, storefileIndexSizeMB=0
.META.,,1
stores=2, storefiles=1, storefileSizeMB=0, memstoreSizeMB=0, storefileIndexSizeMB=0
View gist:411334
2010-05-23 15:57:40,016 INFO org.apache.zookeeper.ZooKeeper: Initiating client connection, connectString=hbase:2181 sessionTimeout=60000 watcher=org
/
...skipping
2010-05-23 15:59:29,610 INFO org.apache.hadoop.hbase.master.BaseScanner: RegionManager.metaScanner scanning meta region {server: 10.211.55.7:60020,
regionname: .META.,,1, startKey: <>}
2010-05-23 15:59:29,625 DEBUG org.apache.hadoop.hbase.master.BaseScanner: Current assignment of category,,1274234496204 is not valid; serverAddress
=10.211.55.7:60020, startCode=1274653326052 unknown.
2010-05-23 15:59:29,632 DEBUG org.apache.hadoop.hbase.master.BaseScanner: Current assignment of item,,1274235159640 is not valid; serverAddress=10.
211.55.7:60020, startCode=1274653326052 unknown.
2010-05-23 15:59:29,638 DEBUG org.apache.hadoop.hbase.master.BaseScanner: Current assignment of update,,1274235160834 is not valid; serverAddress=1
You can’t perform that action at this time.