Skip to content

Instantly share code, notes, and snippets.

View nrk's full-sized avatar
🤔
はい、猫のように見えます。

Daniele Alessandri nrk

🤔
はい、猫のように見えます。
View GitHub Profile
@nrk
nrk / predis-0_6_2-relnotes.markdown
Created November 28, 2010 18:59
Predis 0.6.2 (2010-11-28) - Release notes

Predis 0.6.2 (2010-11-28) - Release notes

Predis is a flexible and feature-complete PHP client library for Redis. This is a maintenance release for the 0.6 series that mainly features internal optimizations, a more stable support for transactions (MULTI/EXEC) and comes with a bunch of new commands for Redis 2.2-dev. As with previous releases, Predis is also available for PHP 5.2 with an officially supported backport (PHP >= 5.2.6). What follows is an overview of the new features introduced in this new release. For a more in-depth list of changes please see the CHANGELOG.

New features and changes

Miscellaneous

@nrk
nrk / compl1.rb
Created September 10, 2010 17:39 — forked from antirez/compl1.rb
# compl1.rb - Redis autocomplete example
# download female-names.txt from http://antirez.com/misc/female-names.txt
require 'rubygems'
require 'redis'
r = Redis.new
# Create the completion sorted set
if !r.exists(:compl)
17:33:39 encoder | guys, what's the best PHP client for redis out there?
17:34:16 ronr_ | the one that involves not using PHP?
@nrk
nrk / redis_app.lua
Created August 17, 2010 08:06
Redis + mercury + luapages (tiny example)
require 'luarocks.require'
require 'mercury'
require 'redis'
module('redis_app', package.seeall, mercury.application)
local templates = {
index = [[
<html>
@nrk
nrk / ironruby.txt
Created July 29, 2010 19:31
JSON under IronRuby (and comparisons)
C:\IronRuby\v1.1.0>ir json_speed.rb pure
Rehearsal ------------------------------------
474.906250 39.421875 514.328125 (394.262696)
------------------------- total: 514.328125sec
user system total real
482.531250 43.140625 525.671875 (384.509766)
C:\IronRuby\v1.1.0>ir json_speed.rb ext
Rehearsal ------------------------------------
<?php
/*
* The code in this file is a modification of a file in
* the predis project, and is thus governed by the same
* license. For details, please see:
*
* http://github.com/nrk/predis/blob/master/LICENSE
*/
/*
RubyArray.java:771:in `eltInternal': java.lang.ArrayIndexOutOfBoundsException: 1
from Pack.java:1343:in `encode'
from Pack.java:1640:in `pack'
from RubyArray.java:3852:in `pack'
from org/jruby/RubyArray$i_method_1_0$RUBYINVOKER$pack.gen:65535:in `call'
from CachingCallSite.java:309:in `cacheAndCall'
from CachingCallSite.java:148:in `call'
from test.rb:1:in `__file__'
from test.rb:-1:in `load'
from Ruby.java:685:in `runScript'
Loaded suite ipaddress\ipv4_test
Started
......F.................................
Finished in 2.302 seconds.
1) Failure:
test_initialize_format_error(IPv4Test) [ipaddress\ipv4_test.rb:74]:
<ArgumentError> exception expected but was
Class: <Java::JavaLang::ArrayIndexOutOfBoundsException>
Message: <"1">
@nrk
nrk / predis-0_6_1-relnotes.markdown
Created July 11, 2010 16:14
Predis 0.6.1 (2010-07-11) - Release notes

Predis 0.6.1 (2010-07-11) - Release notes

Predis is a flexible and feature-complete PHP client library for Redis. This is a maintenance release for the 0.6 series featuring some internal optimizations and a more stable and consistent support for pipelines and transactions (MULTI/EXEC) without any breaking changes. As with previous releases, Predis is also available for PHP 5.2 with an officially supported backport (PHP >= 5.2.6). What follows is an overview of the new features introduced in this new release. For a more in-depth list of changes please see the CHANGELOG.

New features and changes

Transactions (MULTI/EXEC)

@nrk
nrk / info_string_sample.txt
Created July 11, 2010 09:42
Parse the string returned by INFO (warning: code written by a newbie to Scala :-))
redis_version:1.3.15
redis_git_sha1:00000000
redis_git_dirty:0
arch_bits:32
multiplexing_api:select
process_id:3160
uptime_in_seconds:48
uptime_in_days:0
connected_clients:1
connected_slaves:0