File: chat-websocket/node_modules/socket.io/node_modules/redis/examples/unix_socket.js

Recommend this page to a friend!
  Classes of Igor Escobar   Terminal Crossword   chat-websocket/node_modules/socket.io/node_modules/redis/examples/unix_socket.js   Download  
File: chat-websocket/node_modules/socket.io/node_modules/redis/examples/unix_socket.js
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Terminal Crossword
Generate a crosswords board on a text console
Author: By
Last change:
Date: 2 years ago
Size: 633 bytes
 

Contents

Class file image Download
var redis = require("redis"), client = redis.createClient("/tmp/redis.sock"), profiler = require("v8-profiler"); client.on("connect", function () { console.log("Got Unix socket connection.") }); client.on("error", function (err) { console.log(err.message); }); client.set("space chars", "space value"); setInterval(function () { client.get("space chars"); }, 100); function done() { client.info(function (err, reply) { console.log(reply.toString()); client.quit(); }); } setTimeout(function () { console.log("Taking snapshot."); var snap = profiler.takeSnapshot(); }, 5000);