From 510c6d763fba74f95ae8f894408c3658bcef4f83 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Wed, 15 Jan 2014 18:13:16 +0000 Subject: embed dependencies that were previously pulled in by git during rebar build --- deps/ibrowse/doc/ibrowse.html | 472 ++++++++++++++++++++++++++++++++++++++ deps/ibrowse/doc/ibrowse_lib.html | 67 ++++++ deps/ibrowse/doc/short-desc | 1 + 3 files changed, 540 insertions(+) create mode 100644 deps/ibrowse/doc/ibrowse.html create mode 100644 deps/ibrowse/doc/ibrowse_lib.html create mode 100644 deps/ibrowse/doc/short-desc (limited to 'deps/ibrowse/doc') diff --git a/deps/ibrowse/doc/ibrowse.html b/deps/ibrowse/doc/ibrowse.html new file mode 100644 index 00000000..1594d741 --- /dev/null +++ b/deps/ibrowse/doc/ibrowse.html @@ -0,0 +1,472 @@ + + + +Module ibrowse + + + + +
+ +

Module ibrowse

+The ibrowse application implements an HTTP 1.1 client in erlang. +

Copyright © 2005-2010 Chandrashekhar Mullaparthi

+ +

Version: 2.1.2

+

Behaviours: gen_server.

+

Authors: Chandrashekhar Mullaparthi (chandrashekhar dot mullaparthi at gmail dot com).

+ +

Description

The ibrowse application implements an HTTP 1.1 client in erlang. This +module implements the API of the HTTP client. There is one named +process called 'ibrowse' which assists in load balancing and maintaining configuration. There is one load balancing process per unique webserver. There is +one process to handle one TCP connection to a webserver +(implemented in the module ibrowse_http_client). Multiple connections to a +webserver are setup based on the settings for each webserver. The +ibrowse process also determines which connection to pipeline a +certain request on. The functions to call are send_req/3, +send_req/4, send_req/5, send_req/6.

+ +

Here are a few sample invocations.

+ + + ibrowse:send_req("http://intranet/messenger/", [], get). +

+ + ibrowse:send_req("http://www.google.com/", [], get, [], + [{proxy_user, "XXXXX"}, + {proxy_password, "XXXXX"}, + {proxy_host, "proxy"}, + {proxy_port, 8080}], 1000). +

+ + ibrowse:send_req("http://www.erlang.org/download/otp_src_R10B-3.tar.gz", [], get, [], + [{proxy_user, "XXXXX"}, + {proxy_password, "XXXXX"}, + {proxy_host, "proxy"}, + {proxy_port, 8080}, + {save_response_to_file, true}], 1000). +

+ + ibrowse:send_req("http://www.erlang.org", [], head). + +

+ ibrowse:send_req("http://www.sun.com", [], options). + +

+ ibrowse:send_req("http://www.bbc.co.uk", [], trace). + +

+ ibrowse:send_req("http://www.google.com", [], get, [], + [{stream_to, self()}]). +
+ +

Function Index

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
all_trace_off/0Turn Off ALL tracing.
code_change/3
get_config_value/1Internal export.
get_config_value/2Internal export.
handle_call/3
handle_cast/2
handle_info/2
init/1
rescan_config/0Clear current configuration for ibrowse and load from the file + ibrowse.conf in the IBROWSE_EBIN/../priv directory.
rescan_config/1
send_req/3This is the basic function to send a HTTP request.
send_req/4Same as send_req/3.
send_req/5Same as send_req/4.
send_req/6Same as send_req/5.
send_req_direct/4Same as send_req/3 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2.
send_req_direct/5Same as send_req/4 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2.
send_req_direct/6Same as send_req/5 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2.
send_req_direct/7Same as send_req/6 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2.
set_dest/3Deprecated.
set_max_pipeline_size/3Set the maximum pipeline size for each connection to a specific Host:Port.
set_max_sessions/3Set the maximum number of connections allowed to a specific Host:Port.
show_dest_status/0Shows some internal information about load balancing.
show_dest_status/2Shows some internal information about load balancing to a + specified Host:Port.
spawn_link_worker_process/1Same as spawn_worker_process/1 except the the calling process + is linked to the worker process which is spawned.
spawn_link_worker_process/2Same as spawn_worker_process/2 except the the calling process + is linked to the worker process which is spawned.
spawn_worker_process/1Creates a HTTP client process to the specified Host:Port which + is not part of the load balancing pool.
spawn_worker_process/2Same as spawn_worker_process/1 but takes as input a Host and Port + instead of a URL.
start/0Starts the ibrowse process without linking.
start_link/0Starts the ibrowse process linked to the calling process.
stop/0Stop the ibrowse process.
stop_worker_process/1Terminate a worker process spawned using + spawn_worker_process/2 or spawn_link_worker_process/2.
stream_close/1Tell ibrowse to close the connection associated with the + specified stream.
stream_next/1Tell ibrowse to stream the next chunk of data to the + caller.
terminate/2
trace_off/0Turn tracing off for the ibrowse process.
trace_off/2Turn tracing OFF for all connections to the specified HTTP + server.
trace_on/0Turn tracing on for the ibrowse process.
trace_on/2Turn tracing on for all connections to the specified HTTP + server.
+ +

Function Details

+ +

all_trace_off/0

+
+

all_trace_off() -> ok

+

Turn Off ALL tracing

+ +

code_change/3

+
+

code_change(OldVsn, State, Extra) -> any()

+
+ +

get_config_value/1

+
+

get_config_value(Key) -> any()

+

Internal export

+ +

get_config_value/2

+
+

get_config_value(Key, DefVal) -> any()

+

Internal export

+ +

handle_call/3

+
+

handle_call(Request, From, State) -> any()

+
+ +

handle_cast/2

+
+

handle_cast(Msg, State) -> any()

+
+ +

handle_info/2

+
+

handle_info(Info, State) -> any()

+
+ +

init/1

+
+

init(X1) -> any()

+
+ +

rescan_config/0

+
+

rescan_config() -> any()

+

Clear current configuration for ibrowse and load from the file + ibrowse.conf in the IBROWSE_EBIN/../priv directory. Current + configuration is cleared only if the ibrowse.conf file is readable + using file:consult/1

+ +

rescan_config/1

+
+

rescan_config(File) -> any()

+
+ +

send_req/3

+
+

send_req(Url::string(), Headers::headerList(), Method::method()) -> response() +

+

This is the basic function to send a HTTP request. + The Status return value indicates the HTTP status code returned by the webserver

+ +

send_req/4

+
+

send_req(Url, Headers, Method::method(), Body::body()) -> response() +

+

Same as send_req/3. + If a list is specified for the body it has to be a flat list. The body can also be a fun/0 or a fun/1.
+ If fun/0, the connection handling process will repeatdely call the fun until it returns an error or eof.

Fun() = {ok, Data} | eof

+ If fun/1, the connection handling process will repeatedly call the fun with the supplied state until it returns an error or eof.
Fun(State) = {ok, Data} | {ok, Data, NewState} | eof

+ +

send_req/5

+
+

send_req(Url::string(), Headers::headerList(), Method::method(), Body::body(), Options::optionList()) -> response() +

+

Same as send_req/4. + For a description of SSL Options, look in the ssl manpage. If the + HTTP Version to use is not specified, the default is 1.1. +
+

+

+ +

send_req/6

+
+

send_req(Url, Headers::headerList(), Method::method(), Body::body(), Options::optionList(), Timeout) -> response() +

+

Same as send_req/5. + All timeout values are in milliseconds.

+ +

send_req_direct/4

+
+

send_req_direct(Conn_pid, Url, Headers, Method) -> any()

+

Same as send_req/3 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2

+ +

send_req_direct/5

+
+

send_req_direct(Conn_pid, Url, Headers, Method, Body) -> any()

+

Same as send_req/4 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2

+ +

send_req_direct/6

+
+

send_req_direct(Conn_pid, Url, Headers, Method, Body, Options) -> any()

+

Same as send_req/5 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2

+ +

send_req_direct/7

+
+

send_req_direct(Conn_pid, Url, Headers, Method, Body, Options, Timeout) -> any()

+

Same as send_req/6 except that the first argument is the PID + returned by spawn_worker_process/2 or spawn_link_worker_process/2

+ +

set_dest/3

+
+

set_dest(Host, Port, T) -> any()

+

Deprecated. Use set_max_sessions/3 and set_max_pipeline_size/3 + for achieving the same effect.

+ +

set_max_pipeline_size/3

+
+

set_max_pipeline_size(Host::string(), Port::integer(), Max::integer()) -> ok

+

Set the maximum pipeline size for each connection to a specific Host:Port.

+ +

set_max_sessions/3

+
+

set_max_sessions(Host::string(), Port::integer(), Max::integer()) -> ok

+

Set the maximum number of connections allowed to a specific Host:Port.

+ +

show_dest_status/0

+
+

show_dest_status() -> any()

+

Shows some internal information about load balancing. Info + about workers spawned using spawn_worker_process/2 or + spawn_link_worker_process/2 is not included.

+ +

show_dest_status/2

+
+

show_dest_status(Host, Port) -> any()

+

Shows some internal information about load balancing to a + specified Host:Port. Info about workers spawned using + spawn_worker_process/2 or spawn_link_worker_process/2 is not + included.

+ +

spawn_link_worker_process/1

+
+

spawn_link_worker_process(Url::string()) -> {ok, pid()}

+

Same as spawn_worker_process/1 except the the calling process + is linked to the worker process which is spawned.

+ +

spawn_link_worker_process/2

+
+

spawn_link_worker_process(Host::string(), Port::integer()) -> {ok, pid()}

+

Same as spawn_worker_process/2 except the the calling process + is linked to the worker process which is spawned.

+ +

spawn_worker_process/1

+
+

spawn_worker_process(Url::string()) -> {ok, pid()}

+

Creates a HTTP client process to the specified Host:Port which + is not part of the load balancing pool. This is useful in cases + where some requests to a webserver might take a long time whereas + some might take a very short time. To avoid getting these quick + requests stuck in the pipeline behind time consuming requests, use + this function to get a handle to a connection process.
+ Note: Calling this function only creates a worker process. No connection + is setup. The connection attempt is made only when the first + request is sent via any of the send_req_direct/4,5,6,7 functions.
+ Note: It is the responsibility of the calling process to control + pipeline size on such connections. +

+ +

spawn_worker_process/2

+
+

spawn_worker_process(Host::string(), Port::integer()) -> {ok, pid()}

+

Same as spawn_worker_process/1 but takes as input a Host and Port + instead of a URL.

+ +

start/0

+
+

start() -> any()

+

Starts the ibrowse process without linking. Useful when testing using the shell

+ +

start_link/0

+
+

start_link() -> {ok, pid()}

+

Starts the ibrowse process linked to the calling process. Usually invoked by the supervisor ibrowse_sup

+ +

stop/0

+
+

stop() -> any()

+

Stop the ibrowse process. Useful when testing using the shell.

+ +

stop_worker_process/1

+
+

stop_worker_process(Conn_pid::pid()) -> ok

+

Terminate a worker process spawned using + spawn_worker_process/2 or spawn_link_worker_process/2. Requests in + progress will get the error response

{error, closing_on_request}

+ +

stream_close/1

+
+

stream_close(Req_id::req_id()) -> ok | {error, unknown_req_id}

+

Tell ibrowse to close the connection associated with the + specified stream. Should be used in conjunction with the + stream_to option. Note that all requests in progress on + the connection which is serving this Req_id will be aborted, and an + error returned.

+ +

stream_next/1

+
+

stream_next(Req_id::req_id()) -> ok | {error, unknown_req_id}

+

Tell ibrowse to stream the next chunk of data to the + caller. Should be used in conjunction with the + stream_to option

+ +

terminate/2

+
+

terminate(Reason, State) -> any()

+
+ +

trace_off/0

+
+

trace_off() -> any()

+

Turn tracing off for the ibrowse process

+ +

trace_off/2

+
+

trace_off(Host, Port) -> ok

+

Turn tracing OFF for all connections to the specified HTTP + server.

+ +

trace_on/0

+
+

trace_on() -> any()

+

Turn tracing on for the ibrowse process

+ +

trace_on/2

+
+

trace_on(Host, Port) -> ok +

+

Turn tracing on for all connections to the specified HTTP + server. Host is whatever is specified as the domain name in the URL

+
+ + +

Generated by EDoc, Nov 10 2010, 06:04:33.

+ + diff --git a/deps/ibrowse/doc/ibrowse_lib.html b/deps/ibrowse/doc/ibrowse_lib.html new file mode 100644 index 00000000..7a00d4f8 --- /dev/null +++ b/deps/ibrowse/doc/ibrowse_lib.html @@ -0,0 +1,67 @@ + + + +Module ibrowse_lib + + + + +

Module ibrowse_lib

+Module with a few useful functions. + + +

Description

Module with a few useful functions +

Function Index

+ + + + + + + + +
dec2hex/2dec2hex taken from gtk.erl in std dist + M = integer() -- number of hex digits required + N = integer() -- the number to represent as hex.
decode_base64/1Implements the base64 decoding algorithm.
decode_rfc822_date/1
drv_ue/1
drv_ue/2
encode_base64/1Implements the base64 encoding algorithm.
status_code/1Given a status code, returns an atom describing the status code.
url_encode/1URL-encodes a string based on RFC 1738.
+ +

Function Details

+ +

dec2hex/2

+

dec2hex(M::integer(), N::integer()) -> string()

+

dec2hex taken from gtk.erl in std dist + M = integer() -- number of hex digits required + N = integer() -- the number to represent as hex

+ +

decode_base64/1

+

decode_base64(List::In) -> Out | exit({error, invalid_input}) +

+

Implements the base64 decoding algorithm. The output data type matches in the input data type.

+ +

decode_rfc822_date/1

+decode_rfc822_date(String) -> term() + + +

drv_ue/1

+drv_ue(Str) -> term() + + +

drv_ue/2

+drv_ue(Str, Port) -> term() + + +

encode_base64/1

+

encode_base64(List::In) -> Out +

+

Implements the base64 encoding algorithm. The output data type matches in the input data type.

+ +

status_code/1

+

status_code(StatusCode::status_code()) -> StatusDescription +

+

Given a status code, returns an atom describing the status code.

+ +

url_encode/1

+

url_encode(Str) -> UrlEncodedStr +

+

URL-encodes a string based on RFC 1738. Returns a flat list.

+ + diff --git a/deps/ibrowse/doc/short-desc b/deps/ibrowse/doc/short-desc new file mode 100644 index 00000000..56fa9091 --- /dev/null +++ b/deps/ibrowse/doc/short-desc @@ -0,0 +1 @@ +A powerful HTTP/1.1 client written in erlang -- cgit v1.2.3