deft
deft copied to clipboard
High performance non blocking web framework
The ByteBuffer usage is HttpProtocol is pretty optimized (bytebuffer reusage etc). Apply the similiar usage in AS
Augment IOLoopMXBean with an additonal method e.g. ``` int getSelectorKeySetSize() ```
background and inspiration: http://stackoverflow.com/questions/4938902/tornado-asynchronous-handler/4939170#4939170
The current JMX usage is not thread safe. (The "jmx thread" is accessing methods on e.g IOLoop.) One way to solve this is to use IOLoop.addCallback and explicit locking. e.g...
Just a thought. Proposal: ``` @Path("/") class SynchronousRequestHandler extends RequestHandler { @Override public void get(HttpRequest request, HttpResponse response) { response.write("hello world!"); } } public static void main(String[] args) { List...
Nicholas Whitehead found a bug that makes the server go into an infinite loop. Bug described on ML, third bullet (http://groups.google.com/group/deft-web-server/browse_thread/thread/d59fe5cd35aebfd8) Stacktrace: 22:53:58.876 [I/O-LOOP] ERROR org.deftserver.web.http.HttpResponse - ClosedChannelException during flush():...
inspiration: http://www.tornadoweb.org/documentation#cookies-and-secure-cookies
Convenience method from facebook/tornado ``` def redirect(self, url, permanent=False): """Sends a redirect to the given (optionally relative) URL.""" if self._headers_written: raise Exception("Cannot redirect after headers have been written") self.set_status(301 if...