To save GPRS traffic, I wan't to delete some headers from my midlet's request. For example, if regular response headers looks like this:
then it would be great to truncate such headers to something like this:
If I try to do
then it takes no changes into resulting Http Request Headers - User agent stays as it was - Nokia5310XpressMusic/2.0 (05.81) Profile/MIDP-2.1 Configuration/CLDC-1.1 UNTRUSTED/1.0
In API docs of HttpConnection interface, there is written:
public void setRequestProperty(String key,
throws IOException Sets the general request property. If a property with the key already exists, overwrite its value with the new value.
Looks like Nokia add that user-agent header right before connection is opening. So how to avoid this? How to truncate these headers to minimum?