Skip to content

Instantly share code, notes, and snippets.

Jakub Román jakub-roman

View GitHub Profile
View build_query.js
const format = require('pg-format')
var filter = [
c: "id",
o: "=",
v: "1"
c: "name",
View express.js
var express = require('express')
var app = express()
var pug = require('pug')
var fs = require('fs')
var bp = require('body-parser')
const config = './config.json'
const timeout = 300 // 5mins
app.use(bp.urlencoded({ extended: false }))
View perl-redis
#!/usr/bin/env perl
use strict;
use warnings;
use Redis;
use Data::Dumper;
use Time::HiRes qw/time/;
my $r = Redis->new();
my $num = 10000;
View python-redis
#!/usr/bin/env python
import redis
import time
import random, string
from os import getenv
r_host = getenv('HOST', 'localhost')
r_port = getenv('PORT', '6379')
r = redis.StrictRedis(host=r_host, port=r_port)
You can’t perform that action at this time.