Seeing as HEAD requests, per the various RFCs, are essentially GET requests
with complete and valid response headers, but never any content, having a
HEAD response with Content-Length is 100% valid and appropriate.

Is the particular resource you are working with not valid for a GET request?


--
Joakim Erdfelt <[email protected]>
webtide.com <http://www.webtide.com/> - intalio.com/jetty
Expert advice, services and support from from the Jetty & CometD experts
eclipse.org/jetty - cometd.org

On Tue, Nov 11, 2014 at 6:58 PM, James Reeves <[email protected]>
wrote:

> Hi folks,
>
> I'd like to omit the Content-Length header in a response to a HEAD
> request, but I can't for the life of me work out how to do this. No matter
> what I do the Content-Length header is always emitted.
>
> I'm using an embedded Jetty 7.6.13. A little old, I know, but there's a
> minimum dependency on Java 1.5 I can't yet work around.
>
> Does anyone have any ideas on how to accomplish this, in Jetty 7 or indeed
> any other version?
>
> - James
>
> _______________________________________________
> jetty-users mailing list
> [email protected]
> To change your delivery options, retrieve your password, or unsubscribe
> from this list, visit
> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
_______________________________________________
jetty-users mailing list
[email protected]
To change your delivery options, retrieve your password, or unsubscribe from 
this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users

Reply via email to