New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ability to set zero-length content on an HTTP GET request #145
Comments
From yan...@google.com on February 23, 2011 19:52:03 Try this: Status: ByDesign |
From zcmk...@gmail.com on February 24, 2011 05:43:13 Thank you for the answer.I tried the code,it seems still doesn't work correct.
I use fiddle catch to package, include your code the Httpmethod is post |
From zcmk...@gmail.com on February 27, 2011 00:14:22 There seems has a bug.I traced in httprequest.java: |
From zcmk...@gmail.com on March 14, 2011 04:38:47 In NetHttpRequest.java ,public LowLevelHttpResponse execute(): |
From yan...@google.com on March 22, 2011 07:26:02 Need to try to reproduce it. Status: New |
From yan...@google.com on April 05, 2011 12:31:44 Taking a look at the JavaDoc for HttpURLConnection on Android: http://developer.android.com/reference/java/net/HttpURLConnection.html It says that calling setDoOutput(true) changes the method from GET to POST. Summary: Ability to set zero-length content on a GET request |
From yan...@google.com on April 05, 2011 12:53:20 http://codereview.appspot.com/4354051/ Summary: Ability to set zero-length content on an HTTP GET request |
From yan...@google.com on April 05, 2011 12:56:38 Status: Fixed |
From zcmk...@gmail.com on February 23, 2011 19:13:15
Version of google-api-java-client (e.g. 1.2.1-alpha)? 1.3.1-alpha Java environment (e.g. Java 6, Android 2.2, App Engine 1.3.7)? Java 6 Describe the problem. As yan...@google.com concerned in Issue 68 ,"Please don't use "content-type" header directly and instead use an instance of HttpContent.If the HttpContent of a request is null, we will assume there is no content."
but how to make an instance httpcontent? For example I need make request as this:
Content-Length=0 Content-Type=text/plain.which httpcontent should I use GZip,urlencode or logcontent?
the other way is use NetHttpRequest,but I can't use NetHttpRequest.setcontent().
HttpRequest request = transport.buildGetRequest();is correct,but HttpRequest doesn't have method setcontent()
NetHttpRequest request = transport.buildGetRequest(); It said "NetHttpRequest cannot be resolved to a type".When I
import com.google.api.client.http.javanet.NetHttpRequest; It said "The type com.google.api.client.http.javanet.NetHttpRequest is not visible."
The declaration of NetHttpQequest is
final class NetHttpRequest extends LowLevelHttpRequest How would you expect it to be fixed? would mend give a sample of googlestorage?
here is my code:
public GoogleStorage(String accessKey,String secret) throws IOException
{
//work for fiddle
//System.setProperty("http.proxyHost", "localhost");
//System.setProperty("http.proxyPort", "8888");
//System.setProperty("https.proxyHost", "localhost");
//System.setProperty("https.proxyPort", "8888");
Original issue: http://code.google.com/p/google-api-java-client/issues/detail?id=130
The text was updated successfully, but these errors were encountered: