阿帕奇 Http 组件(Apache HttpComponents)- Apache 翻译过来好像都不认识了吧

Apache HttpComponents

太阳火神的美丽人生 (http://blog.csdn.net/opengl_es)

本文遵循“署名-非商业用途-保持一致”创作公用协议

转载请保留此句:太阳火神的美丽人生 -  本博客专注于 敏捷开发及移动和物联设备研究:iOS、Android、Html5、Arduino、pcDuino,否则,出自本博客的文章拒绝转载或再转载,谢谢合作。

标题也就没啥可翻的了,就是 Apache 提供的免费开源的 Http 组件库。Apache 冷不丁翻译过来,自已有些木讷了,不太认识,反而对 Apache 更有敬畏之心。

但使用 Android 的兄弟会发现,Android 已经内置了。

是的,但 Java 并不天生拥有,那么不妨使用一下。

这里需要说明的是,Asynch HttpClient  对 Java NIO 进行了封装,异步网络请求一直是我钟爱的,不用线程阻塞等待,不用 select 检查事件,当然了,内部实现也可能这样做了,但至少不需要我们开发人员来做这些事情。

Android 的 AsynTask 是否会下岗呢?

估计涛声依旧了。。。

Apache HttpComponents

The Apache HttpComponents? project is responsible for creating and maintaining a toolset of low level Java components focused on HTTP and associated protocols.

This project functions under the Apache Software Foundation (http://www.apache.org), and is part of a larger community of developers and users.

HttpComponents Overview

The Hyper-Text Transfer Protocol (HTTP) is perhaps the most significant protocol used on the Internet today. Web services, network-enabled appliances and the growth of network computing continue to expand the role of the HTTP protocol beyond user-driven web browsers, while increasing the number of applications that require HTTP support.

Designed for extension while providing robust support for the base HTTP protocol, the HttpComponents may be of interest to anyone building HTTP-aware client and server applications such as web browsers, web spiders, HTTP proxies, web service transport libraries, or systems that leverage or extend the HTTP protocol for distributed communication.

HttpComponents Structure

HttpComponents Core

HttpCore is a set of low level HTTP transport components that can be used to build custom client and server side HTTP services with a minimal footprint. HttpCore supports two I/O models: blocking I/O model based on the classic Java I/O and non-blocking, event driven I/O model based on Java NIO.

The blocking I/O model may be more appropriate for data intensive, low latency scenarios, whereas the non-blocking model may be more appropriate for high latency scenarios where raw data throughput is less important than the ability to handle thousands of simultaneous HTTP connections in a resource efficient manner.

HttpComponents Client

HttpClient is a HTTP/1.1 compliant HTTP agent implementation based on HttpCore. It also provides reusable components for client-side authentication, HTTP state management, and HTTP connection management. HttpComponents Client is a successor of and replacement for Commons HttpClient 3.x. Users of Commons HttpClient are strongly encouraged to upgrade.

HttpComponents AsyncClient

Asynch HttpClient is a HTTP/1.1 compliant HTTP agent implementation based on HttpCore NIO and HttpClient components. It is a complementary module to Apache HttpClient intended for special cases where ability to handle a great number of concurrent connections is more important than performance in terms of a raw data throughput.

Commons HttpClient (legacy)

Commons HttpClient 3.x codeline is at the end of life. All users of Commons HttpClient 3.x are strongly encouraged to upgrade to HttpClient 4.1.

时间: 2024-10-14 10:22:22

阿帕奇 Http 组件(Apache HttpComponents)- Apache 翻译过来好像都不认识了吧的相关文章

org.apache.httpcomponents httpclient 发起HTTP JSON请求

1. pom.xml <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.5.3</version> </dependency> 2. HttpClient.java package com.midea.clean.util; import java.io

Apache HttpComponents 工具类 [ HttpUtil ]

pom.xml <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.5.5</version> </dependency> <dependency> <groupId>org.apache.httpcomponents</gr

Apache HttpComponents中的cookie匹配策略

*/--> pre.src {background-color: #292b2e; color: #b2b2b2;} pre.src {background-color: #292b2e; color: #b2b2b2;} pre.src {background-color: #292b2e; color: #b2b2b2;} pre.src {background-color: #292b2e; color: #b2b2b2;} pre.src {background-color: #292b

org.apache.httpcomponents.httpclient

apache org doc :http://hc.apache.org/httpcomponents-client-ga/tutorial/html/fundamentals.html#d5e49 依赖: <!-- https://mvnrepository.com/artifact/log4j/log4j --> <dependency> <groupId>log4j</groupId> <artifactId>log4j</artif

Apache commons——Apache旗下的通用工具包项目

Apache Commons是Apache旗下的一个开源项目,包含了很多开源的工具,用于解决平时编程经常会遇到的问题,减少重复劳动 这里是Apache commons的官方网站 下面是工具的简单介绍: Components   Attributes Runtime API to metadata attributes such as doclet tags. BCEL Byte Code Engineering Library - analyze, create, and manipulate

[Apache]改变Apache端口等配置修改方法

 如何改变Apache端口:找到Apache安装目录下conf目录下的httpd.conf文件.打开它,找到"Listen",紧接着Listen的数字就是端口号,默认状态下为"Listen 80".在之前的PHP专题中提到过关于在安装配置Apache时会遇到端口与IIS HTTP端口冲突的问题,因为IIS HTTP端口默认也为80.那么我们就可以在这里改变Apache的端口,从而避免冲突,比如可以改成:Listen 8011.改好之后别忘重起Apache服务使得配置

apache配置文件中文翻译

## This is the main Apache HTTP server configuration file.  It contains the这是apache的主配置文件,它包含了给服务的配置指令# configuration directives that give the server its instructions.# See <URL:http://httpd.apache.org/docs/2.2> for detailed information.# In particu

Apache zookeeper Overview翻译

名字由来 zookeeper:中文翻译动物园管理员,是用来协调分布式程序的服务框架.之所以起名zookeeper,是因为作者把这些分散的.分布式的系统协调任务看成是一个动物园管理员做的事情. 设计目标 操作简单:zookeeper主要用来协调处理分布式任务通过一个叫多层次的命名空间的东东,这个东东很类似文件系统.一个命名空间就是一个数据寄存器 - 称为znode,按照zookeeper的说法,多层次的命名空间就是文件与目录的关系.但zookeeper的数据是保存在内存中 自我复制:像下面的这个分

org.apache.httpcomponents:httpclient 工具类

基于httpclient 版本4.4.1 因为http连接需要三次握手,在需要频繁调用时浪费资源和时间 故采用连接池的方式连接 根据实际需要更改  连接池最大连接数.路由最大连接数 另一个需要注意的是 // 释放Socket流 response.close(); // 释放Connection // httpClient.close(); 1 import org.apache.http.HttpEntity; 2 import org.apache.http.NameValuePair; 3