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
package se.schildmeijer; | |
import java.lang.annotation.ElementType; | |
import java.lang.annotation.Retention; | |
import java.lang.annotation.RetentionPolicy; | |
import java.lang.annotation.Target; | |
public class Playground { | |
@Retention(RetentionPolicy.RUNTIME) |
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
15:23:09.372 [main] DEBUG o.d.example.DeftServerExample - Starting up server on port: 8080 | |
15:23:17.494 [I/O-LOOP] DEBUG o.deftserver.example.AsyncDbHandler - Entering AsyncDbHandler.get | |
15:23:17.495 [I/O-LOOP] DEBUG org.deftserver.example.AsyncDbApi - Getting name from database... | |
15:23:17.496 [I/O-LOOP] DEBUG o.deftserver.example.AsyncDbHandler - Leaving AsyncDbHandler.get | |
15:23:17.496 [Thread-1] DEBUG org.deftserver.example.AsyncDbApi - sleeping for 200 seconds | |
15:23:17.696 [Thread-1] DEBUG o.deftserver.example.AsyncDbHandler - MyCallback.onSuccess, retrieved name: Jim123 | |
15:23:17.703 [I/O-LOOP] ERROR o.d.web.protocol.HttpProtocolImpl - Could not read buffer: {} | |
java.nio.channels.ClosedChannelException: null | |
at sun.nio.ch.SocketChannelImpl.ensureReadOpen(Unknown Source) ~[na:1.6.0_21] | |
at sun.nio.ch.SocketChannelImpl.read(Unknown Source) ~[na:1.6.0_21] |
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
diff --git src/main/java/org/deftserver/example/AsyncDbApi.java src/main/java/org/deftserver/example/AsyncDbApi.java | |
index 15fe0ed..c1a3c6b 100644 | |
--- src/main/java/org/deftserver/example/AsyncDbApi.java | |
+++ src/main/java/org/deftserver/example/AsyncDbApi.java | |
@@ -14,13 +14,13 @@ | |
private final int DELAY = 100; | |
public void getNameFromId(final String id, final AsyncCallback<String> callback) { | |
- logger.debug("Getting name from database..."); | |
+ //logger.debug("Getting name from database..."); |
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
#user rogerschildmeijer; | |
worker_processes 1; | |
error_log /var/log/nginx/error.log; | |
pid /var/run/nginx.pid; | |
events { | |
worker_connections 1024; | |
use kqueue; | |
} |
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
package org.deftserver.web.protocol; | |
import org.deftserver.web.HttpException; | |
import org.deftserver.web.HttpVerb; | |
import org.deftserver.web.handler.RequestHandler; | |
import org.slf4j.Logger; | |
import org.slf4j.LoggerFactory; | |
public class HttpRequestDispatcher { |
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
package org.deftserver.web.protocol; | |
import org.deftserver.web.HttpException; | |
import org.deftserver.web.HttpVerb; | |
import org.deftserver.web.handler.RequestHandler; | |
import org.slf4j.Logger; | |
import org.slf4j.LoggerFactory; | |
public class HttpRequestDispatcher { |
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
package org.deftserver.web; | |
public class HttpException extends RuntimeException { | |
private final int statusCode; | |
private final String body; | |
public HttpException(int statusCode) { | |
this(statusCode, ""); | |
} |
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
package org.deftserver.web; | |
public class HttpException extends RuntimeException { | |
private final int statusCode; | |
public HttpException(int statusCode) { | |
this(statusCode, ""); | |
} |
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
test: 5 of 10 done | |
Server-1 0 0 (226535 25) 8 5128 (1528 979448) 1 (0 0 0) | |
Server-1 0 0 (226535 25) 8 5128 (1536 984576) 1 (0 0 0) | |
Server-1 0 0 (226535 25) 8 5128 (1544 989704) 2 (0 0 1)client 0 0 (2 15) 25640 32 (466648 760) 5 (0 0 1) | |
test: 6 of 10 done | |
Server-1 0 0 (226535 25) 16 10256 (1560 999960) 2 (0 0 0) | |
client 0 0 (2 15) 10256 16 (476904 776) 2 (0 0 0) | |
test: 6 of 10 doneServer-1 0 0 (226535 25) 8 5128 (1568 1005088) 1 (0 0 0) |
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
test: 994 of 1000 done | |
client 0 0 (18293 1872) 0 0 (5097232 8000) 6 (0 0 0) | |
test: 994 of 1000 done | |
client 0 0 (18293 1872) 0 0 (5097232 8000) 6 (0 0 0) | |
test: 994 of 1000 done | |
client 0 0 (18293 1872) 0 0 (5097232 8000) 6 (0 0 0) | |
test: 994 of 1000 done | |
client 0 0 (18293 1872) 0 0 (5097232 8000) 6 (0 0 0) | |
test: 994 of 1000 done | |
client 0 0 (18293 1872) 0 0 (5097232 8000) 6 (0 0 0) |
OlderNewer