HttpClient Tutorial

Oleg Kalnichevski

4.0.1

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.


Preface
1. HttpClient scope
2. What HttpClient is NOT
1. Fundamentals
1.1. Request execution
1.1.1. HTTP request
1.1.2. HTTP response
1.1.3. Working with message headers
1.1.4. HTTP entity
1.1.4.1. Repeatable entities
1.1.4.2. Using HTTP entities
1.1.5. Ensuring release of low level resources
1.1.6. Consuming entity content
1.1.7. Producing entity content
1.1.7.1. Dynamic content entities
1.1.7.2. HTML forms
1.1.7.3. Content chunking
1.1.8. Response handlers
1.2. HTTP execution context
1.3. Exception handling
1.3.1. HTTP transport safety
1.3.2. Idempotent methods
1.3.3. Automatic exception recovery
1.3.4. Request retry handler
1.4. Aborting requests
1.5. HTTP protocol interceptors
1.6. HTTP parameters
1.6.1. Parameter hierarchies
1.6.2. HTTP parameters beans
1.7. HTTP request execution parameters
2. Connection management
2.1. Connection parameters
2.2. Connection persistence
2.3. HTTP connection routing
2.3.1. Route computation
2.3.2. Secure HTTP connections
2.4. HTTP route parameters
2.5. Socket factories
2.5.1. Secure socket layering
2.5.2. SSL/TLS customization
2.5.3. Hostname verification
2.6. Protocol schemes
2.7. HttpClient proxy configuration
2.8. HTTP connection managers
2.8.1. Connection operators
2.8.2. Managed connections and connection managers
2.8.3. Simple connection manager
2.8.4. Pooling connection manager
2.8.5. Connection manager shutdown
2.9. Connection management parameters
2.10. Multithreaded request execution
2.11. Connection eviction policy
2.12. Connection keep alive strategy
3. HTTP state management
3.1. HTTP cookies
3.1.1. Cookie versions
3.2. Cookie specifications
3.3. HTTP cookie and state management parameters
3.4. Cookie specification registry
3.5. Choosing cookie policy
3.6. Custom cookie policy
3.7. Cookie persistence
3.8. HTTP state management and execution context
3.9. Per user / thread state management
4. HTTP authentication
4.1. User credentials
4.2. Authentication schemes
4.3. HTTP authentication parameters
4.4. Authentication scheme registry
4.5. Credentials provider
4.6. HTTP authentication and execution context
4.7. Preemptive authentication
4.8. NTLM Authentication
4.8.1. NTLM connection persistence
5. HTTP client service
5.1. HttpClient facade
5.2. HttpClient parameters
5.3. Automcatic redirect handling
5.4. HTTP client and execution context
6. Advanced topics
6.1. Custom client connections
6.2. Stateful HTTP connections
6.2.1. User token handler
6.2.2. User token and execution context
6.2.2.1. Persistent stateful connections