You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by ginsohn <ad...@gmail.com> on 2009/03/05 13:27:11 UTC

[users@httpd] HTTP Server connection hangs

Hello,
I am rather unfamiliar with HTTP Server requirements. I am trying to
implement a simple HTTP 1.1 server that receives a GET request, and
transfers a 3gp (video) file to the client. All works fine except the fact
that the client gets the file, but does not close the connection.
I do not have the length of the content I send out, so I cannot declare it.

Here are the headers I use:
statusCode: 200
Server: MyServer...
Date: <now>
Content-type: video/3gp
connection: close

What am I missing?

Thanks,

-- 
View this message in context: http://www.nabble.com/HTTP-Server-connection-hangs-tp22350633p22350633.html
Sent from the Apache HTTP Server - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] HTTP Server connection hangs

Posted by Eric Covener <co...@gmail.com>.
On Thu, Mar 5, 2009 at 9:33 AM, ginsohn <ad...@gmail.com> wrote:

>>
>> Hi,
>> Thanks for the reply. I've tried to avoid explicit session.close(), and
>> used response.finishedWriting() instead. Do I have to explicitly close the
>> session? Can't I signal the client any other way?

Sorry, I thought you were implementing your own HTTP Server and
concerned with generating all of this yourself.

These objects and methods don't mean anything to me.  You can use
chunked encoding to signal the end of content whose length you don't
know. It's defined in rfc2616.


-- 
Eric Covener
covener@gmail.com

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] HTTP Server connection hangs

Posted by ginsohn <ad...@gmail.com>.


Eric Covener wrote:
> 
> On Thu, Mar 5, 2009 at 7:27 AM, ginsohn <ad...@gmail.com> wrote:
>>
>> Hello,
>> I am rather unfamiliar with HTTP Server requirements. I am trying to
>> implement a simple HTTP 1.1 server that receives a GET request, and
>> transfers a 3gp (video) file to the client. All works fine except the
>> fact
>> that the client gets the file, but does not close the connection.
>> I do not have the length of the content I send out, so I cannot declare
>> it.
>>
>> Here are the headers I use:
>> statusCode: 200
>> Server: MyServer...
>> Date: <now>
>> Content-type: video/3gp
>> connection: close
>>
> 
> Connection: close means the server will close the connection when the
> content is transferred, so you're not waiting for the client to do so.
> 
> -- 
> Eric Covener
> covener@gmail.com
> 
> Hi,
> Thanks for the reply. I've tried to avoid explicit session.close(), and
> used response.finishedWriting() instead. Do I have to explicitly close the
> session? Can't I signal the client any other way?
> 
> Thanks,
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>    "   from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/HTTP-Server-connection-hangs-tp22350633p22352776.html
Sent from the Apache HTTP Server - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] HTTP Server connection hangs

Posted by Eric Covener <co...@gmail.com>.
On Thu, Mar 5, 2009 at 7:27 AM, ginsohn <ad...@gmail.com> wrote:
>
> Hello,
> I am rather unfamiliar with HTTP Server requirements. I am trying to
> implement a simple HTTP 1.1 server that receives a GET request, and
> transfers a 3gp (video) file to the client. All works fine except the fact
> that the client gets the file, but does not close the connection.
> I do not have the length of the content I send out, so I cannot declare it.
>
> Here are the headers I use:
> statusCode: 200
> Server: MyServer...
> Date: <now>
> Content-type: video/3gp
> connection: close
>

Connection: close means the server will close the connection when the
content is transferred, so you're not waiting for the client to do so.


-- 
Eric Covener
covener@gmail.com

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org