This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Transactions: 5000 hits | |
| Availability: 100.00 % | |
| Elapsed time: 67.20 secs | |
| Data transferred: 43.10 MB | |
| Response time: 0.12 secs | |
| Transaction rate: 74.40 trans/sec | |
| Throughput: 0.64 MB/sec | |
| Concurrency: 9.16 | |
| Successful transactions: 5000 | |
| Failed transactions: 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if((couchcache["popular-"+page])&&(couchcache["popular-"+page].timesaved > (Date.now() - 60000))){ | |
| res.send(couchcache["popular-"+page].docs); | |
| }else{ | |
| //...get doc... | |
| if(page < 10){ | |
| couchcache["popular-"+page]={"timesaved":Date.now(),"docs":docs}; | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| twistd -noy punjab.tac | |
| /usr/local/lib/python2.6/dist-packages/punjab/httpb.py:16: DeprecationWarning: the sha module is deprecated; use the hashlib module instead | |
| import sha, time | |
| /usr/local/lib/python2.6/dist-packages/punjab/session.py:18: DeprecationWarning: the md5 module is deprecated; use hashlib instead | |
| import md5 | |
| 2011-02-28 16:09:00+0000 [-] Log opened. | |
| 2011-02-28 16:09:00+0000 [-] twistd 10.2.0 (/usr/bin/python 2.6.5) starting up. | |
| 2011-02-28 16:09:00+0000 [-] reactor class: twisted.internet.selectreactor.SelectReactor. | |
| 2011-02-28 16:09:00+0000 [-] twisted.web.server.Site starting on 5280 | |
| 2011-02-28 16:09:00+0000 [-] Starting factory <twisted.web.server.Site instance at 0xb704354c> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ------------ThIs_Is_tHe_bouNdaRY_$ | |
| Content-Disposition: form-data; name="guid" | |
| t3st15 | |
| ------------ThIs_Is_tHe_bouNdaRY_$ | |
| Content-Disposition: form-data; name="count" | |
| 2 | |
| ------------ThIs_Is_tHe_bouNdaRY_$ | |
| Content-Disposition: form-data; name="userid" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """HTTP/1.1 client library | |
| <intro stuff goes here> | |
| <other stuff, too> | |
| HTTPConnection goes through a number of "states", which define when a client | |
| may legally make another request or fetch the response for a particular | |
| request. This diagram details these state transitions: | |
| (null) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Day job: Web Developer at occipital.com | |
| Favorite Python project: graphite | |
| Favorite Conference: OSCON. | |
| Python Experience Level: Advanced. 5yr+ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "_id": "_design/gc-utils", | |
| "_rev": "2-bd8fcdf5509cb9cc99560a39f0c642f0", | |
| "vendor": { | |
| "clustering": { | |
| "KNNCluster": "/**\n * kNN-based Clustering\n */\n(function() {\n\tvar cluster = this.cluster = {};\n\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tmodule.exports = cluster;\n\t}\n\t\n\t//TODO\n})();", | |
| "ProximityCluster": "/**\n * Proximity based clustering\n */\n(function() {\n\n var proxcluster = this.proxcluster = {};\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tmodule.exports = proxcluster;\n\t}\n\n var gju = require('vendor/geojson-js-utils/geojson-utils');\n\n proxcluster.PointCluster = function(threshold){\n this.clusters = [];\n this.points = [];\n this.distanceThreshold = threshold;\n\n };\n \n proxcluster.PointCluster.prototype.addToClosestCluster = function(point) {\n var distance = 40000; // Some large number\n var clusterToAddTo = null;\n var pos = point.geometry;\n |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var list = [1,45,23,45,65,6,2]; | |
| var steps = 6; | |
| var packed_list = []; | |
| var min=0, max=0; | |
| for(l in list){ | |
| if(min > list[l]) | |
| min = list[l]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <iq type='set' | |
| from='admin@talkback.im' | |
| to='geo.talkback.im' | |
| id='sub1'> | |
| <pubsub xmlns='http://jabber.org/protocol/pubsub'> | |
| <subscribe | |
| node='test' | |
| jid='admin@talkback.im'/> | |
| <options node='test' jid='admin@talkback.im'> | |
| <x xmlns='jabber:x:data' type='submit'> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| prefix=/app/.geo/geos | |
| exec_prefix=${prefix} | |
| libdir=${exec_prefix}/lib | |
| usage() | |
| { | |
| cat <<EOF | |
| Usage: geos-config [OPTIONS] | |
| Options: |