Skip to content

Commit

Permalink
More fixes for #1338: Add a special client header
Browse files Browse the repository at this point in the history
  • Loading branch information
jfarcand committed Oct 30, 2013
1 parent 4798b6e commit 4a02e63
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,11 @@ Action action(AtmosphereRequest req, AtmosphereResponse res) throws IOException,
}
AtmosphereResourceImpl resource = configureWorkflow(null, handlerWrapper, req, res);

String v = req.getHeader(HeaderConfig.X_ATMO_BINARY);
if (v != null) {
resource.forceBinaryWrite(Boolean.valueOf(v));
}

// Globally defined
Action a = invokeInterceptors(config.framework().interceptors(), resource);
if (a.type() != Action.TYPE.CONTINUE) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,6 @@ public interface HeaderConfig {
String ATMOSPHERE_POST_BODY = "X-Atmosphere-Post-Body";

String X_ATMO_PROTOCOL = "X-atmo-protocol";

String X_ATMO_BINARY = "X-Atmosphere-Binary";
}

0 comments on commit 4a02e63

Please sign in to comment.