trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dia...@apache.org
Subject svn commit: r930056 - in /incubator/trafficserver/site/trunk/docs/v2/sdk: HTTPFunctions.html HTTPHooksAndTransactions.html HTTPSessionFunctions.html HTTPTransactionFunctions.html
Date Thu, 01 Apr 2010 17:55:16 GMT
Author: dianes
Date: Thu Apr  1 17:55:16 2010
New Revision: 930056

URL: http://svn.apache.org/viewvc?rev=930056&view=rev
Log:
merge; closed bugs TS-251, 256, 255

Modified:
    incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPFunctions.html
    incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPHooksAndTransactions.html
    incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPSessionFunctions.html
    incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPTransactionFunctions.html

Modified: incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPFunctions.html
URL: http://svn.apache.org/viewvc/incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPFunctions.html?rev=930056&r1=930055&r2=930056&view=diff
==============================================================================
--- incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPFunctions.html (original)
+++ incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPFunctions.html Thu Apr  1 17:55:16
2010
@@ -16,6 +16,12 @@
 
 <p><b>Table of Contents</b></p>
 <b><ul>
+<li><span class="section"><a href="HTTPFunctions.html#GeneralHTTPFunctions">General
HTTP Functions</a></span></li>
+<ul>
+  <li><a href="HTTPFunctions.html#INKHttpIsInternalRequest">INKHttpIsInternalRequest</a></li>
+   <li><a href="HTTPFunctions.html#INKHttpSchedule">INKHttpSchedule</a></li>
+</ul>
+
 <li><span class="section"><a href="HTTPFunctions.html#HTTPHookFunctions">Hook
Functions</a></span></li>
 <ul><li><a href="HTTPFunctions.html#INKHttpHookAdd">INKHttpHookAdd</a></li></ul>
 
@@ -29,19 +35,14 @@
 
 <ul>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnCacheLookupStatusGet">INKHttpTxnCacheLookupStatusGet</a></li>
-<ul>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnCacheLookupStatusSet">INKHttpTxnCacheLookupStatusSet</a></b></li>
   <li><a href="HTTPTransactionFunctions.html#INKHttpTxnCachedReqGet">INKHttpTxnCachedReqGet</a></li>
-<li><a href="HTTPTransactionFunctions.html#INKHttpTxnCachedRespGet">INKHttpTxnCachedRespGet</a></li></ul>
-
+<li><a href="HTTPTransactionFunctions.html#INKHttpTxnCachedRespGet">INKHttpTxnCachedRespGet</a></li>
 
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIncomingPortGet">INKHttpTxnClientIncomingPortGet</a></li>
-<ul><li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIPGet ">INKHttpTxnClientIPGet</a></li>
-</ul>
-
-
+><li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIPGet ">INKHttpTxnClientIPGet</a></li>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientRemotePortGet">INKHttpTxnClientRemotePortGet</a></li>
-<ul> 
+ 
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientReqGet">INKHttpTxnClientReqGet</a></li>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnClientRespGet">INKHttpTxnClientRespGet</a></li>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnErrorBodySet">INKHttpTxnErrorBodySet</a></li>

@@ -54,13 +55,11 @@
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnServerIPGet">INKHttpTxnServerIPGet</a></li>

 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnServerReqGet">INKHttpTxnServerReqGet</a></li>

 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnServerRespGet">INKHttpTxnServerRespGet</a></li>
-<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnSkipRww">INKHttpTxnSkipRww</a></b></li>
+<li><a href="HTTPTransactionFunctions.html#INKHttpTxnSetRespCacheableSet">INKHttpTxnSetRespCacheableSet</a></li>
+<li><a href="HTTPTransactionFunctions.html#INKHttpTxnSkipRww">INKHttpTxnSkipRww</a></li>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnSsnGet">INKHttpTxnSsnGet</a></li>

-</ul>
-
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformedRespCache">INKHttpTxnTransformedRespCache</a></li>
-<ul><li><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformRespGet">INKHttpTxnTransformRespGet</a></li></ul>
-
+<li><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformRespGet">INKHttpTxnTransformRespGet</a></li>
 <li><a href="HTTPTransactionFunctions.html#INKHttpTxnUntransformedRespCache">INKHttpTxnUntransformedRespCache</a></li>
 
 </ul>
@@ -71,6 +70,80 @@
 
 <div class="section" lang="en">
 <div class="titlepage"><div><div><h3 class="title">
+<a name="GeneralHTTPFunctions"></a>General HTTP Functions</h3></div></div></div>
+
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="INKHttpIsInternalRequest"></a>INKHttpIsInternalRequest</h4></div></div></div>
+<p>Checks if the state machine/request is internal.</p>
+<div class="variablelist"><dl>
+<dt><span class="term"><b>Prototype</b></span></dt>
+<dd>
+  <p><code class="code">bool INKHttpIsInternalRequest (INKHttpTxn <span class="replaceable">txnp</span>);</code></p></dd>
+<dt><span class="term"><b>Description</b></span></dt>
+<dd>
+  <p>Checks if the request being handled originated  from a Traffic Server process;
provides an API to distinguish between internal and external requests. 
+An internal request is any request that comes in through a connection created by <code>INKHttpConnect</code>.</p>
+<p><u><i>Background Info:</i></u>  Some plugins (like those
modifying cache-control behaviors) need to know whether the current state machine  they are
running within was originated by an external connection (through the HTTP port) or by an internal
one (such as one created by   <code>INKHttpConnect</code>). Formerly there was
no way for the  state machine to know whether it was created by an external or internal connection.
Since the state machine itself didn't know how it was created, plugins had no way of knowing,
either.  <span class="title"><code>INKHttpIsInternalRequest</code></span>
solves this problem.</p>
+</dd>
+
+
+<dt><span class="term"><b>Returns</b></span></dt>
+<dd>
+<p><code class="code">true </code>if the request originated from within
a Traffic Server process.</p>
+</dd>
+
+<dt><span class="term"><b>Example Use-Case Scenario</b></span></dt>
+<dd>
+<p>A plugin that implements stale-while-revalidate (SWR) makes a background fetch request
when the data in cache is stale. The background fetch request is made on the <code>INKVConn</code>
returned by <code>INKHttpConnect</code>. When the SWR plugin sees this background
fetch request, it needs to turn off read while write. </p>
+<p>In addition to checking for the special header that is inserted for the background
fetch request, the plugin must 
+  check to see if the request was internal or not (this is because the header can be spoofed).</p>
+</dd>
+
+<dd>
+  
+</dd>
+</dl>
+</div>
+</div>
+
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h4 class="title">
+<a name="INKHttpSchedule"></a>INKHttpSchedule</h4></div></div></div>
+<p>Schedules an HTTP continuation to receive an event.</p>
+<div class="variablelist"><dl>
+<dt><span class="term"><b>Prototype</b></span></dt>
+<dd>
+  <p><code class="code"> INKAction     INKHttpSchedule (INKCont <span class="replaceable">contp</span>,
INKHttpTxn <span class="replaceable">txnp</span>, unsigned int <span class="replaceable">
time</span>)  </code></p></dd>
+
+<dt><span class="term"><b>Description</b></span></dt>
+<dd>
+  <p>Schedules the HTTP continuation (represented by <code class="code"><span
class="replaceable"> contp </span></code>) to receive an event.</p></dd>
+<dd>
+  <p> The timeout refers to a time from the present (in milliseconds)  at which to
send the 
+    event. </p>
+</dd>
+<dd>
+  <p>If the timeout is 0 when <code class="code"><span class="replaceable">
contp </span></code> is called back, then the event sent is 
+     <code>INK_EVENT_IMMEDIATE</code>. If timeout is greater than 0, then the
event sent is
+    <code>INK_EVENT_TIMEOUT</code>. </p>
+</dd>
+
+<dt><span class="term"><b>Returns</b></span></dt>
+<dd>
+<p>An <code>INKAction</code> object.</p>
+<p><code class="code">INK_ERROR_PTR</code> if there is an error.</p>
+</dd>
+
+</dl></div>
+</div>
+
+</div>
+</div>
+
+
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h3 class="title">
 <a name="HTTPHookFunctions"></a>Hook Functions</h3></div></div></div>
 
 <div class="section" lang="en">
@@ -101,5 +174,7 @@
 </div>
 </div>
 </div>
+
+
 </body>
 </html>

Modified: incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPHooksAndTransactions.html
URL: http://svn.apache.org/viewvc/incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPHooksAndTransactions.html?rev=930056&r1=930055&r2=930056&view=diff
==============================================================================
--- incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPHooksAndTransactions.html (original)
+++ incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPHooksAndTransactions.html Thu Apr 
1 17:55:16 2010
@@ -3,7 +3,7 @@
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
 <title>Chapter 8. HTTP Hooks and Transactions</title>
 <!--#include file="top.html" -->
-<div class="navheader">
+</head><div class="navheader">
 <div class="navprev">
 <a accesskey="p" href="ch07s05.html">Prev</a> — Cache Events</div>
 <div class="navnext">Adding Hooks — <a accesskey="n" href="AddingHooks.html">Next</a>
@@ -20,12 +20,12 @@
     transactions.</p>
 <p>This chapter contains the following sections:</p>
 <div class="itemizedlist"><ul type="disc">
-<li><p><a href="AddingHooks.html" title="Adding Hooks">Adding Hooks</a></p></li>
-<li><p><a href="HTTPSessions.html" title="HTTP Sessions">HTTP Sessions</a></p></li>
-<li><p><a href="HTTP_Transactions.html" title="HTTP Transactions">HTTP
Transactions</a></p></li>
-<li><p><a href="InterceptingHTTPTransactionFuncs.html" title="Intercepting
HTTP Transaction Functions">Intercepting HTTP Transaction Functions</a></p></li>
-<li><p><a href="InitiateHTTPConnection.html" title="Initiate HTTP Connection">Initiate
HTTP Connection</a></p></li>
-<li><p><a href="HTTPAlternateSelection.html" title="HTTP Alternate Selection">HTTP
Alternate Selection</a></p></li>
+<li><a href="AddingHooks.html" title="Adding Hooks">Adding Hooks</a></li>
+<li><a href="HTTPSessions.html" title="HTTP Sessions">HTTP Sessions</a></li>
+<li><a href="HTTP_Transactions.html" title="HTTP Transactions">HTTP Transactions</a></li>
+<li><a href="InterceptingHTTPTransactionFuncs.html" title="Intercepting HTTP Transaction
Functions">Intercepting HTTP Transaction Functions</a></li>
+<li><a href="InitiateHTTPConnection.html" title="Initiate HTTP Connection">Initiate
HTTP Connection</a></li>
+<li><a href="HTTPAlternateSelection.html" title="HTTP Alternate Selection">HTTP
Alternate Selection</a></li>
 </ul></div>
 <div class="section" lang="en">
 <div class="titlepage"><div><div><h2 class="title" style="clear: both">

Modified: incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPSessionFunctions.html
URL: http://svn.apache.org/viewvc/incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPSessionFunctions.html?rev=930056&r1=930055&r2=930056&view=diff
==============================================================================
--- incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPSessionFunctions.html (original)
+++ incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPSessionFunctions.html Thu Apr  1 17:55:16
2010
@@ -16,8 +16,8 @@
 
 
 <ul>
-  <li><a href="HTTPSessionFunctions.html#INKHttpSsnHookAdd"><b>INKHttpSsnHookAdd</b></a>
 </li>  
-  <li><b><a href="HTTPSessionFunctions.html#INKHttpSsnReenable">INKHttpSsnReenable</a>
</b></li>  
+  <li><b><a href="HTTPSessionFunctions.html#INKHttpSsnHookAdd">INKHttpSsnHookAdd</a></b></li>
 
+  <li><b><a href="HTTPSessionFunctions.html#INKHttpSsnReenable">INKHttpSsnReenable</a></b><a
href="HTTPSessionFunctions.html#INKHttpSsnReenable"></a></li>  
 </ul>
 
 <div class="section" lang="en">
@@ -42,7 +42,7 @@
                 session, it is not possible to call
                 <code class="function">INKHttpSsnHookAdd</code> from the plugin
                 initialization routine. Therefore, the plugin needs a handle to an HTTP
-        session (see the  example below).</p></dd>
+        session (see the <a href="HTTPSessionFunctions.html#INKEvent_1">example</a>
below).</p></dd>
 <dt><span class="term"><a name="INKEvent_1"></a><b>Example</b></span></dt>
 <dd><pre class="programlisting">#include InkAPI.h
 
@@ -114,7 +114,7 @@ void INKPluginInit (int argc, const char
                 <code class="code"><em class="replaceable"><code>event</code></em></code>,
then the plugin
                 wants the session to continue. If
                 <code class="code">INK_EVENT_HTTP_ERROR</code> is specified for
-                <code class="code"><em class="replaceable"><code>event</code></em></code>,
then the plugin
+                <code class="code"><em class="replaceable"><code> event</code></em></code>,
then the plugin
                 wants the session to be terminated. An error  is then sent
                 back to the client if no response has already been
                 sent.</p></dd>

Modified: incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPTransactionFunctions.html
URL: http://svn.apache.org/viewvc/incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPTransactionFunctions.html?rev=930056&r1=930055&r2=930056&view=diff
==============================================================================
--- incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPTransactionFunctions.html (original)
+++ incubator/trafficserver/site/trunk/docs/v2/sdk/HTTPTransactionFunctions.html Thu Apr 
1 17:55:16 2010
@@ -16,20 +16,13 @@
 
 <ul>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnCacheLookupStatusGet">INKHttpTxnCacheLookupStatusGet</a></b></li>
-<ul>
   <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnCacheLookupStatusSet">INKHttpTxnCacheLookupStatusSet</a></b></li>
   <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnCachedReqGet">INKHttpTxnCachedReqGet</a></b></li>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnCachedRespGet">INKHttpTxnCachedRespGet</a></b></li>
-</ul>
-
-
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIncomingPortGet">INKHttpTxnClientIncomingPortGet</a></b></li>
-<ul><li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIPGet
">INKHttpTxnClientIPGet</a></b></li>
-</ul>
-
-
-<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientRemotePortGet">INKHttpTxnClientRemotePortGet</a></b></li>
-<ul> <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientReqGet">INKHttpTxnClientReqGet</a></b></li>
+<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientIPGet ">INKHttpTxnClientIPGet</a></b></li>
+<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientRemotePortGet">INKHttpTxnClientRemotePortGet</a></b></li>

+<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientReqGet">INKHttpTxnClientReqGet</a></b></li>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnClientRespGet">INKHttpTxnClientRespGet</a></b></li>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnErrorBodySet">INKHttpTxnErrorBodySet</a></b></li>

 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnHookAdd">INKHttpTxnHookAdd</a></b></li>

@@ -41,13 +34,11 @@
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnServerIPGet">INKHttpTxnServerIPGet</a></b></li>

 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnServerReqGet">INKHttpTxnServerReqGet</a></b></li>

 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnServerRespGet">INKHttpTxnServerRespGet</a></b></li>
+<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnSetRespCacheableSet">INKHttpTxnSetRespCacheableSet</a></b></li>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnSkipRww">INKHttpTxnSkipRww</a></b></li>

 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnSsnGet">INKHttpTxnSsnGet</a></b></li>
-</ul>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformedRespCache">INKHttpTxnTransformedRespCache</a></b></li>
-<ul><li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformRespGet">INKHttpTxnTransformRespGet</a></b></li>
-</ul>
-
+<li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnTransformRespGet">INKHttpTxnTransformRespGet</a></b></li>
 <li><b><a href="HTTPTransactionFunctions.html#INKHttpTxnUntransformedRespCache">INKHttpTxnUntransformedRespCache</a></b></li>
 </ul>
 <div class="section" lang="en">
@@ -826,6 +817,29 @@
 <div class="section" lang="en">
 <div class="titlepage"><div><div>
   <h4 class="title">
+<a name="INKHttpTxnSetRespCacheableSet"></a>INKHttpTxnSetRespCacheableSet</h4></div></div></div>
+<p>Makes a request/response cacheable.</p>
+<div class="variablelist"><dl>
+<dt><span class="term"><b>Prototype</b></span></dt>
+<dd>
+  <p><code>void INKHttpTxnSetRespCacheableSet (INKHttpTxn <span class="replaceable">txnp</span>)</code></p>
+<p><code>void INKHttpTxnSetReqCacheableSet (INKHttpTxn <span class="replaceable">txnp</span>);</code></p>
+</dd>
+<dt><span class="term"><b>Description</b></span></dt>
+<dd>
+<p>Sets the request/response as cacheable for a given transaction <code><span
class="replaceable"> txnp</span></code>.</p>
+</dd>
+<dt><span class="term"><b>Returns</b></span></dt>
+<dd>
+<p>No values are returned by this function.</p>
+</dd>
+</dl></div>
+</div>
+
+
+<div class="section" lang="en">
+<div class="titlepage"><div><div>
+  <h4 class="title">
 <a name="INKHttpTxnSkipRww"></a>INKHttpTxnSkipRww</h4></div></div></div>
 <p>Turns off read while writing for a transaction.</p>
 <div class="variablelist"><dl>



Mime
View raw message