sagnitude / httpclientandroidlib Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/httpclientandroidlib
License: Other
Automatically exported from code.google.com/p/httpclientandroidlib
License: Other
It seems that httpmime directory is not included at all in the script (1.0.3
and all previous). Is it on purpose or it is just omited?
httpmime contains one very important class: MultiPartEntity. It is needed in
order to send multipart form data (e.g. file uploads).
btw, there is 4.1.3 released and it seems like the right moment to release
1.0.4 with httpmime bundled :-)
Original issue reported on code.google.com by [email protected]
on 20 Mar 2012 at 10:12
http://seclists.org/fulldisclosure/2014/Aug/48
Original issue reported on code.google.com by [email protected]
on 28 Aug 2014 at 3:20
Not a problem but apache have updated HttpCore to 4.1.4
http://www.apache.org/dist/httpcomponents/httpcore/RELEASE_NOTES-4.1.x.txt
Good job anyway.
Original issue reported on code.google.com by [email protected]
on 29 Dec 2011 at 7:43
What steps will reproduce the problem?
1. Try to open the jar file directly
2.
3.
What is the expected output? What do you see instead?
It should be Java exception ocurred, but it instead is an invalid jar file.
That is causing problems in my program.
What version of the product are you using? On what operating system?
1.0.2
Please provide any additional information below.
Original issue reported on code.google.com by [email protected]
on 13 Feb 2012 at 9:53
This issue is an issue of Apache HttpClient 4.3.1 and was fixed in release 4.3.2
See https://issues.apache.org/jira/browse/HTTPCLIENT-1426
Parts of multipart HttpEntity added with
MultipartEntityBuilder.addBinaryBody(String name, File file) don't contain
fields "filename" and "Content-Type", thus Commons FileUpload handles them as
form fields, not files.
The problem is probably caused by empty filename of the created FileBody.
Is planned a new release with the repackage of this release?
Thanks
Original issue reported on code.google.com by [email protected]
on 19 Feb 2014 at 6:53
The sed commands in the convert_stock_httpclient script are incompatible with
the default version of sed on a mac.
To make a mac-compliant version, replace commands like this:
sed -i "s/ACTIVITY_ENTRY_NAME/${PROJECTNAME}/g" AndroidManifest.xml
with this:
sed -e "s/ACTIVITY_ENTRY_NAME/${PROJECTNAME}/g" -i '' AndroidManifest.xml
Note: the zero-length extension (two single quotes) passed to the -i option.
It's better (and highly recommended) to provide an extension like this:
sed -e "s/ACTIVITY_ENTRY_NAME/${PROJECTNAME}/g" -i '.bak' AndroidManifest.xml
However, then every execution will leave backup files in the directory that
need to be managed.
Original issue reported on code.google.com by [email protected]
on 4 Jun 2013 at 2:22
加载正确的证书,去访问https服务。4.0以下版本的android会提��
�找不到证书位置的错误,
代码如下:
KeyStore trustStore = KeyStore.getInstance(KeyStore.getDefaultType());
ins = context.getResources().openRawResource(R.raw.huipumobile); // 下载的证书放到项目中的assets目录中
trustStore.load(ins, "123456".toCharArray());
SSLContext sslcontext = SSLContexts.custom()
.loadTrustMaterial(trustStore)
.build();
SSLConnectionSocketFactory sslsf = new SSLConnectionSocketFactory(sslcontext,
SSLConnectionSocketFactory.BROWSER_COMPATIBLE_HOSTNAME_VERIFIER);
httpClient = HttpClients.custom()
.setSSLSocketFactory(sslsf)
.build();
Original issue reported on code.google.com by [email protected]
on 23 Jan 2014 at 12:04
Can you do the same "Android-ization" for HttpClient Cache?
Having a nice, easy to use working cache for HttpClient would benefit quite a
few Android application, I bet!
https://hc.apache.org/httpcomponents-client-ga/httpclient-cache/index.html
Original issue reported on code.google.com by [email protected]
on 5 Oct 2011 at 6:58
What steps will reproduce the problem?
1. Http get or post with gzip compression used by server
Example:
response.setHeader("Content-Encoding", "gzip");
GZIPOutputStream gzipOutputStream = new
GZIPOutputStream(response.getOutputStream())
In this case decompression of response body is drammatically slow. See issue
https://issues.apache.org/jira/browse/HTTPCLIENT-1461
Thanks
Original issue reported on code.google.com by [email protected]
on 5 Dec 2014 at 4:48
What should i use instead of DefaultHttpClient() in order to do a
multipart/form request ?
Below is my code for uploading a file:
String upload_url = BASE_URL + UPLOAD_FILE;
HttpClient httpclient = new DefaultHttpClient();
HttpPost postRequest = new HttpPost(upload_url);
MultipartEntityBuilder entity = MultipartEntityBuilder.create();
try {
// Set Data and Content-type header for the image
FileBody fb = new FileBody(file, ContentType.MULTIPART_FORM_DATA);
StringBody directoryIDString = new StringBody(directoryID + "",ContentType.TEXT_PLAIN);
StringBody imageCreatedString = new StringBody(image_created_on
+ "",ContentType.TEXT_PLAIN);
Log.e("Upload File Response", image_created_on);
entity.addPart("directory_id", directoryIDString);
entity.addPart("created_on", imageCreatedString);
entity.addPart("file", fb);
postRequest.setEntity(entity.build());
HttpResponse response = httpclient.execute(postRequest);
// Read the response
String jsonString = EntityUtils.toString(response.getEntity());
Log.i("Upload File Response ", jsonString);
return true;
} catch (Exception e) {
Log.e("Error in uploadFile", e.getMessage());
return false;
}
Original issue reported on code.google.com by [email protected]
on 28 Mar 2014 at 11:34
Upgrade to httpcore-4.2.4 and httpclient-4.2.5.
Add a constant for sed as the gnu sed is required and on OSX it's available via
homebrew as gsed.
Original issue reported on code.google.com by [email protected]
on 30 May 2013 at 1:40
Hello,
I am wondering, why the hole
PoolingClientConnectionManager/ClientConnectionManager stuff isn't in
httpclientandroidlib?
Original issue reported on code.google.com by [email protected]
on 29 Jun 2012 at 2:38
What steps will reproduce the problem?
1. Use the library in a project and with a couple of methods.
What is the expected output? What do you see instead?
None of methods work; they all return ClassNotFound error.
What version of the product are you using? On what operating system?
1.0.2
Please provide any additional information below.
Original issue reported on code.google.com by [email protected]
on 13 Feb 2012 at 4:35
basic auth not working in released jar
it adds extra newlines between headers
the root of the problem seems to be Base64.encode from android (it adds a
newline when used with default flags, try Base64.NO_WRAP)
Original issue reported on code.google.com by [email protected]
on 30 Sep 2011 at 12:14
I've been using your httpclientandroidlib since version 1.1.2 and i need to
debug everything. Unfortunaltely i'm not able to call
httpClient.log.enableDebug() as mentioned in the project page.
Is it hard to get this working in another way?
thanks!
Original issue reported on code.google.com by [email protected]
on 3 Mar 2014 at 9:48
I want to target android 1.5, how can I use this lib? because I saw you
replaced the base64 calss use android.util.Base64
Original issue reported on code.google.com by [email protected]
on 17 Jan 2012 at 3:58
Thanks for making this!
What steps will reproduce the problem?
1. Attempt to use the jar with maven pom.xml
2. Must install jar locally.
3. Wish to find the jar as a dependency in Maven Central
Original issue reported on code.google.com by [email protected]
on 17 Mar 2012 at 10:50
Here's the start of a port from bash to pure Maven.
I didn't finish it, because I found this plugin and it solved my issue:
<groupId>org.sonatype.plugins</groupId>
<artifactId>jarjar-maven-plugin</artifactId>
<version>1.8</version>
Hopefully this Maven pom will be useful for someone who cant use the
jarjar-maven-plugin. Included:
1. get the dependency sources
2. upack them
3. filter out some files
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>jarjar</artifactId>
<packaging>jar</packaging>
<name>jarjar - Third Party Dependencies</name>
<properties>
<http.component.version>4.2.3</http.component.version>
<commons.codec.version>1.8</commons.codec.version>
<gson.version>2.1</gson.version>
</properties>
<dependencies>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${http.component.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpcore</artifactId>
<version>${http.component.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpmime</artifactId>
<version>${http.component.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient-cache</artifactId>
<version>${http.component.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>${commons.codec.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>com.google.gson</groupId>
<artifactId>gson</artifactId>
<version>${gson.version}</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.4</version>
<executions>
<execution>
<id>unpack-httpclient</id>
<phase>generate-resources</phase>
<goals>
<goal>unpack-dependencies</goal>
</goals>
<configuration> <includeArtifacIds>httpclient,httpcore,httpmime,httpclient-cache</includeArtifacIds>
<includeGroupIds>org.apache.httpcomponents</includeGroupIds>
<includeClassifiers>sources</includeClassifiers>
<excludes>**/org/apache/http/impl/client/cache/ehcache/*,
**/org/apache/http/impl/client/cache/memcached/*,
**/NegotiateScheme.java,**/NegotiateSchemeFactory.java,
**/GGSSchemeBase.java,**/KerberosScheme.java,
**/KerberosSchemeFactory.java,**/SPNegoScheme.java,
**/SPNegoSchemeFactory.java</excludes>
<outputDirectory>${project.build.directory}/jarjar</outputDirectory>
</configuration>
</execution>
<execution>
<id>unpack-commons-codec</id>
<phase>generate-resources</phase>
<goals>
<goal>unpack-dependencies</goal>
</goals>
<configuration>
<includeArtifacIds>commons-codec</includeArtifacIds>
<includeGroupIds>commons-codec</includeGroupIds>
<outputDirectory>${project.build.directory}/jarjar</outputDirectory>
<includeClassifiers>sources</includeClassifiers>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Original issue reported on code.google.com by [email protected]
on 12 Oct 2013 at 8:27
I have add java sources generation to your script. Cant create merge request
here. Please add this changes to your project.
look for patch file.
Original issue reported on code.google.com by [email protected]
on 11 Apr 2014 at 7:52
Attachments:
What steps will reproduce the problem?
1.download
2. run script
3.
What is the expected output? What do you see instead?
2 lines in the script cause issues on my system
What version of the product are you using? On what operating system?
1.1.2
Please provide any additional information below.
i had to change the following 2 lines:
android create lib-project -n ${PROJECTNAME} -t 6 -p ${ANDROIDPROJECTPATH} -k
${PACKAGENAME}
cp ${ROOTDIR}/script/androidextra/* androidextra
Notes: android targets available did not match my system
there was a node missing (./script) in the copy statement for the 2 java files
in ./androidextra
Original issue reported on code.google.com by [email protected]
on 15 Jun 2013 at 6:43
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.