コード例 #1
0
ファイル: MCClient.js プロジェクト: FancyIdiot/MCClient
			keys.forEach(function(stats){
				memcached.cachedump(itemSet.server, parseInt(stats) , 0, function( err, response ){
					if (response) {
						if(response instanceof Array ) {
							response.forEach(function(cacheItem){
								callback(cacheItem);
							});
						} else {
							callback(response);
						}
					} 
				})
			});
コード例 #2
0
ファイル: memcached.js プロジェクト: ClassCloud/iframely
                servers.forEach(function(s) {
                    memcached.cachedump(s, parseInt(sid), 0, function(a, b) {

                        if (!(b instanceof Array)) {
                            b = [b];
                        }

                        b.forEach(function(k) {
                            if (k.key === sk) {
                                console.log(' - key', k);
                                console.log(' - now is', new Date());
                                console.log(' - exp in', new Date(k.s * 1000));
                            }
                        })
                    });
                });
コード例 #3
0
ファイル: nmcache.js プロジェクト: zslx/nodejs
		        keys.forEach(function( stats ){ // get a cachedump for each slabid and slab.number
                    slabid = parseInt(stats);
                    item = itemSet[slabid];
                    console.log(slabid, item.number, item.age);
			        nmc.cachedump(itemSet.server, slabid, item.number, function(err,response ){
				        // dump the shizzle
                        if(err) console.log(err); // JSON.stringify( response );
                        if(util.isArray(response)) {
                            response.forEach(function(ele){
                                if(ele.key[0]==='w'&&ele.key[1]==='x')
                                    console.log('arkey:',ele.key);
                            });
                        }else{
                            if(response.key[0]==='w'&& response.key[1]==='x')
				                console.log('key:', response.key);
                        }
			        });
		        });
コード例 #4
0
exports.cachedump = function(server, status, number, callback){
  m.cachedump(server,status,number,function(err,results){
    GlobalCallBack(err,results,"cachedump",callback);
  })
}