This file contains 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
// includes bindings for fetching/fetched | |
var PaginatedCollection = Backbone.Collection.extend({ | |
initialize: function() { | |
_.bindAll(this, 'parse', 'url', 'pageInfo', 'nextPage', 'previousPage'); | |
typeof(options) != 'undefined' || (options = {}); | |
this.page = 1; | |
typeof(this.perPage) != 'undefined' || (this.perPage = 10); | |
}, | |
fetch: function(options) { |
This file contains 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
Vows: http://vowsjs.org/ | |
SASS: http://sass-lang.com/ | |
SSHGuard (pretty decent layout): http://www.sshguard.net/ | |
Django Haystack: http://haystacksearch.org/ | |
twelvesouth (products not project, but still): http://www.twelvesouth.com/ |
This file contains 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
java.lang.Thread.State: RUNNABLE | |
at java.util.Arrays.copyOf(Arrays.java:2734) | |
at java.util.PriorityQueue.toArray(PriorityQueue.java:357) | |
at java.util.concurrent.DelayQueue.toArray(DelayQueue.java:360) | |
at java.util.concurrent.DelayQueue.iterator(DelayQueue.java:439) | |
at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue$1.<init>(ScheduledThreadPoolExecutor.java:644) | |
at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.iterator(ScheduledThreadPoolExecutor.java:643) | |
at java.util.concurrent.ThreadPoolExecutor.drainQueue(ThreadPoolExecutor.java:1198) | |
at java.util.concurrent.ThreadPoolExecutor.shutdownNow(ThreadPoolExecutor.java:1175) | |
at java.util.concurrent.ScheduledThreadPoolExecutor.shutdownNow(ScheduledThreadPoolExecutor.java:580) |
This file contains 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
Client: Mac Pro OS X, 2.8Ghz Quad-Core Intel Xeon, 8 GB 1066 Mhz DDR3 | |
Server: lighttpd/1.4.26 -> Ubuntu, 2.8Ghz Duo-Core Intel Xeon, 6 1066 Mhz DDR3 | |
50 threads that does 50 requests, done 50 times. | |
Async Http Client 1.5.0 (Config http://is.gd/7rGGWU) | |
============================================================= | |
BenchmarkResult{requestsPerSecond=1578.96, threads=50, batches=50, targetRequests=125000, successfulRequests=125000, failedRequests=0, averageRequestTime=0.63ms, averageBatchTime=1583.32ms, totalBenchmarkTime=79166.03ms} | |
(last 5 runs) |
This file contains 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
// Service Definition | |
ServiceDefinition serviceDefinition = injector.getInstance(ServiceDefinition.class); | |
serviceDefinition | |
.producing(ServiceDefinition.Media.JSON) | |
.producing(ServiceDefinition.Media.XML) | |
.consuming(ServiceDefinition.Media.JSON) | |
.consuming(ServiceDefinition.Media.XML) | |
.withHandler(new ServiceHandler(ServiceDefinition.HttpMethod.PUT, "id", "createAddressBook")) | |
.withHandler(new ServiceHandler(ServiceDefinition.HttpMethod.GET, "id", "getAddressBook")) |
This file contains 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
// includes bindings for fetching/fetched | |
PaginatedCollection = Backbone.Collection.extend({ | |
initialize: function() { | |
_.bindAll(this, 'parse', 'url', 'pageInfo', 'nextPage', 'previousPage'); | |
this.page = 1; | |
}, | |
fetch: function(options) { | |
options || (options = {}); | |
this.trigger("fetching"); |
This file contains 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
-# Super cheapo minification! | |
-# Here's how it works: | |
-# | |
-# * The HAML below points to the minified version on production, | |
-# or prints <script> tags if not. | |
-# | |
-# * We define the route to /js/script.js ourselves. | |
-# | |
-# * Some silly caching will ensure that the minification only happens once. |
This file contains 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
require 'redis' | |
# This is a direct port of ActiveSupport::Cache::MemCacheStore | |
# Drop this file in lib/active_support/cache/redis_store and in your env files | |
# add: | |
# | |
# config.cache_store = :redis_store | |
module ActiveSupport | |
module Cache |
NewerOlder