From http://www.darkcoding.net/software/memcached-list-all-keys/
Telnet into memcached
telnet 127.0.0.1 11211
List items
stats items
STAT items:3:number 1
From http://www.darkcoding.net/software/memcached-list-all-keys/
Telnet into memcached
telnet 127.0.0.1 11211
List items
stats items
STAT items:3:number 1
<?xml version="1.0"?> | |
<!DOCTYPE tsung SYSTEM "/usr/local/share/tsung/tsung-1.0.dtd"> | |
<tsung loglevel="error" version="1.0"> | |
<!-- t1 and t2 host record should be in /etc/hosts file (on t1,t2 machnines too) --> | |
<clients> | |
<client host="t1" weight="1" cpu="4" maxusers="51000"> | |
</client> | |
<client host="t2" weight="1" cpu="4" maxusers="51000"> | |
</client> | |
</clients> |
include <BLEDevice.h> | |
#include <BLEUtils.h> | |
#include <BLEServer.h> | |
#include "BLE2902.h" | |
#include "BLEHIDDevice.h" | |
#include "HIDTypes.h" | |
#include "HIDKeyboardTypes.h" | |
#include <driver/adc.h> | |
BLEHIDDevice* hid; |
defmodule Utils.Cowboy do | |
use Bitwise | |
# | |
# ipv4 cowboy string example: "0.0.0.0.0.65535.20060.31747" | |
# ipv6 cowboy string example: "10754.43916.45826.36224.35230.44219.15941.63302" | |
def erlangCowboyIpv6StringToString(string) do | |
if String.starts_with?(string, "0.0.0.0.0.65535") do | |
String.split(string,".") |> Enum.take(-2) |> Enum.map(fn(x)-> String.to_integer x end) |> Enum.map(fn(x)-> [x >>> 8,x &&& 255] end) |> List.flatten |> Enum.join(".") |
Top 10 DTrace scripts for Mac OS X | |
Since version 10.5 “Leopard”, Mac OS X has had DTrace, a tool used for performance analysis and troubleshooting. It provides data for Apple’s Instruments tool, as well as a collection of command line tools that are implemented as DTrace scripts. I’m familiar with the latter as I wrote the originals for the DTraceToolkit, which Apple then customized and enhanced for Mac OS X where they are shipped by default (great!). I use them regularly to answer this question: | |
why is my MacBook slow? | |
I work in an office where everyone has MacBook Pros, and “why is my MacBook slow?” is a common question. Applications can become slow or unresponsive while waiting for CPU work, memory requests or disk I/O to complete. | |
For people who try to ignore the slowdown, the question can become: | |
why is my MacBook fan so loud? |
%% ------------------------------------------------------------------- | |
%% | |
%% riak_mapreduce_map_for_groupby: | |
%% Map phase for reduce_plist_sum. | |
%% Together is like sql "count" - "group by" functionality) | |
%% | |
%% Copyright (c)2018, Szloboda Zsolt, [email protected] All Rights Reserved. | |
%% | |
%% This file is provided to you under the Apache License, | |
%% Version 2.0 (the "License"); you may not use this file |
-module(riak_postcommit_hook_example). | |
-export([postcommitcounter/1, postcommitmapcounter/1]). | |
%% Refreshing counters from commithook is very expensive! | |
%% | |
%% requirements: bucket-type: maps(Type::map), bucket-type: counters(Type::counters) | |
%% | |
%% riak-admin bucket-type create maps '{"props":{"datatype":"map"}}' | |
%% riak-admin bucket-type activate maps | |
%% riak-admin bucket-type create counters '{"props":{"datatype":"counter"}}' |
% Update Counter | |
increment | |
decrement | |
{increment, 4} | |
{decrement, 9} | |
% Update Set | |
{add, <<"Value">>} | |
{add_all, [<<"Value">>]} | |
{remove, <<"Value">>} | |
{remove_all, <<"Value">>} |
%% ------------------------------------------------------------------- | |
%% | |
%% riak_csv_etl: etl tools for csv files in Riak | |
%% | |
%% Copyright (c) 2011 Bradley Taylor. All Rights Reserved. | |
%% | |
%% This file is provided to you under the Apache License, | |
%% Version 2.0 (the "License"); you may not use this file | |
%% except in compliance with the License. You may obtain | |
%% a copy of the License at |