Re: [twsocket] HttpCli TransferEncoding

2010-02-15 Thread Paul


- Original Message - 
From: Francois PIETTE francois.pie...@skynet.be

To: ICS support mailing twsocket@elists.org
Sent: Thursday, February 04, 2010 9:00 PM
Subject: Re: [twsocket] HttpCli TransferEncoding


Don't forget about proxies and firewalls. They probably has also to 
support it


It should be possible imho.

it's like sending a large file in pieces.


Not exactly. Any device analysing the content has to decode chunks.


Chunked encoded can be used both ways: client-- server and server -- 
client

http://en.wikipedia.org/wiki/Chunked_transfer_encoding

Paul 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread RTT



I can't get the client working with it.
httpCli.TransferEncoding is a readonly property.
How can I set the transfer encoding to chunked and send seperate chunks ?


From what I see there is no easy way to do it with the HttpCli, without 
overriding some methods or/and add your own PostChunked method. The 
existent TransferEncoding property is used only to handle responses.

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Arno Garrels
Paul wrote:
 I can't get the client working with it.
 httpCli.TransferEncoding is a readonly property.

It is server's TransferEncoding, that's why it's read only.

 How can I set the transfer encoding to chunked and send seperate
 chunks ? 

THttpCli supports chunked encoding when it receives such data
from a server. I don't know whether it's supported with posted 
data from clients to servers at all.

--
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul

So it's currently impossible with THttpCli :-(
I should at least be able to send substreams without ending the post 
request, but haven't found a way to do this yet.


Paul


- Original Message - 
From: Arno Garrels arno.garr...@gmx.de

To: ICS support mailing twsocket@elists.org
Sent: Thursday, February 04, 2010 5:18 PM
Subject: Re: [twsocket] HttpCli TransferEncoding



Paul wrote:

I can't get the client working with it.
httpCli.TransferEncoding is a readonly property.


It is server's TransferEncoding, that's why it's read only.


How can I set the transfer encoding to chunked and send seperate
chunks ?


THttpCli supports chunked encoding when it receives such data
from a server. I don't know whether it's supported with posted
data from clients to servers at all.

--
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be



--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Francois PIETTE

So it's currently impossible with THttpCli :-(


No impossible but a little bit tricky probably.
Probably you'd better derive a new component and override what has to be.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be



- Original Message - 
From: Paul paul.blommae...@telenet.be

To: ICS support mailing twsocket@elists.org
Sent: Thursday, February 04, 2010 6:39 PM
Subject: Re: [twsocket] HttpCli TransferEncoding



So it's currently impossible with THttpCli :-(
I should at least be able to send substreams without ending the post 
request, but haven't found a way to do this yet.


Paul


- Original Message - 
From: Arno Garrels arno.garr...@gmx.de

To: ICS support mailing twsocket@elists.org
Sent: Thursday, February 04, 2010 5:18 PM
Subject: Re: [twsocket] HttpCli TransferEncoding



Paul wrote:

I can't get the client working with it.
httpCli.TransferEncoding is a readonly property.


It is server's TransferEncoding, that's why it's read only.


How can I set the transfer encoding to chunked and send seperate
chunks ?


THttpCli supports chunked encoding when it receives such data
from a server. I don't know whether it's supported with posted
data from clients to servers at all.

--
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be



--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Arno Garrels
Paul wrote:
 So it's currently impossible with THttpCli :-(

Should not be difficult to add it to the component,
or a derived class. Are you sure the HTTP allows chunked 
encoded POST requests and server commonly support it? 

 I should at least be able to send substreams without ending the post
 request, but haven't found a way to do this yet.

I wonder what you want to achieve? If you managed to keep 
one conection alive by sending an infinite data stream
it won't ensure that the other connection, your work
connection, won't be disconnected nevertheless.

--
Arno Garrels

  
 
 Paul
 
 
 - Original Message -
 From: Arno Garrels arno.garr...@gmx.de
 To: ICS support mailing twsocket@elists.org
 Sent: Thursday, February 04, 2010 5:18 PM
 Subject: Re: [twsocket] HttpCli TransferEncoding
 
 
 Paul wrote:
 I can't get the client working with it.
 httpCli.TransferEncoding is a readonly property.
 
 It is server's TransferEncoding, that's why it's read only.
 
 How can I set the transfer encoding to chunked and send seperate
 chunks ?
 
 THttpCli supports chunked encoding when it receives such data
 from a server. I don't know whether it's supported with posted
 data from clients to servers at all.
 
 --
 Arno Garrels
 --
 To unsubscribe or change your settings for TWSocket mailing list
 please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
 Visit our website at http://www.overbyte.be
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul


- Original Message - 
From: Arno Garrels arno.garr...@gmx.de



I wonder what you want to achieve?

speed.

If you managed to keep 
one conection alive by sending an infinite data stream

it won't ensure that the other connection, your work
connection, won't be disconnected nevertheless.

Should be possible if you write both server and client though.

Paul



--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Arno Garrels
Paul wrote:
 - Original Message -
 From: Arno Garrels arno.garr...@gmx.de
 
 I wonder what you want to achieve?
 speed.
 
 If you managed to keep
 one conection alive by sending an infinite data stream
 it won't ensure that the other connection, your work
 connection, won't be disconnected nevertheless.
 Should be possible if you write both server and client though.

If I got you right, you use ICS HTTP server and it disconnects
the connections, right? If you are on v7 I hope you noticed that
the HTTP server component got a new timeout feature that 
disconnects clients even when they established
Keep-Alive connections? It's ON by default.

--
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul



If I got you right, you use ICS HTTP server and it disconnects
the connections, right? If you are on v7 I hope you noticed that
the HTTP server component got a new timeout feature that
disconnects clients even when they established
Keep-Alive connections? It's ON by default.


I use a modified version.

I'm trying to send a never ending stream in chunks.
Each chunk contains the length of the substream, so I should be able decode 
it on the fly on the server.

At least, that's what I'm trying to do.

If I do this the normal way, some messages are received too late, even with 
connection keep-alive.
Google is currently working on a new protocol (SPDY) to overcome this 
problem.
With Http(s), you have to send a new request each time for each message and 
there is a huge delay if multiple proxies are in between.


Paul 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Francois PIETTE
If you managed to keep one conection alive by sending an infinite data 
stream

it won't ensure that the other connection, your work
connection, won't be disconnected nevertheless.



Should be possible if you write both server and client though.


Don't forget about proxies and firewalls. They probably has also to support 
it.


--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul


Don't forget about proxies and firewalls. They probably has also to 
support it


It should be possible imho.

it's like sending a large file in pieces.


Paul

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Francois PIETTE
Don't forget about proxies and firewalls. They probably has also to 
support it


It should be possible imho.

it's like sending a large file in pieces.


Not exactly. Any device analysing the content has to decode chunks.

--
francois.pie...@overbyte.be
http://www.overbyte.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Arno Garrels
Paul wrote:
 With Http(s), you have to send a new request each time for each
 message and there is a huge delay if multiple proxies are in between.

And you never know what those proxies do.
That makes me believe that HTTP isn't the right protocol for the job.

--
Arno Garrels

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul



And you never know what those proxies do.
That makes me believe that HTTP isn't the right protocol for the job.


I wish I had another choise, but I'm not.
In the end, only https is allowed.

Paul 
--

To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli TransferEncoding

2010-02-04 Thread Paul




Not exactly. Any device analysing the content has to decode chunks.


I still don't get it right then.
What is the problem with sending a large file and pause the transfer for a 
few seconds in between ?


Paul 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be