You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zookeeper.apache.org by bu...@apache.org on 2012/03/21 07:15:16 UTC
svn commit: r809385 [32/37] - in /websites/staging/zookeeper/trunk/content:
./ doc/r3.3.5/ doc/r3.3.5/api/ doc/r3.3.5/api/org/
doc/r3.3.5/api/org/apache/ doc/r3.3.5/api/org/apache/zookeeper/
doc/r3.3.5/api/org/apache/zookeeper/class-use/ doc/r3.3.5/api...
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/jdiff/user_comments_for_zookeeper_3.1.1_to_zookeeper_3.3.5.xml
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/linkmap.html
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/linkmap.html (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/linkmap.html Wed Mar 21 06:15:08 2012
@@ -0,0 +1,434 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<meta content="Apache Forrest" name="Generator">
+<meta name="Forrest-version" content="0.9">
+<meta name="Forrest-skin-name" content="pelt">
+<title>Site Linkmap Table of Contents</title>
+<link type="text/css" href="skin/basic.css" rel="stylesheet">
+<link media="screen" type="text/css" href="skin/screen.css" rel="stylesheet">
+<link media="print" type="text/css" href="skin/print.css" rel="stylesheet">
+<link type="text/css" href="skin/profile.css" rel="stylesheet">
+<script src="skin/getBlank.js" language="javascript" type="text/javascript"></script><script src="skin/getMenu.js" language="javascript" type="text/javascript"></script><script src="skin/fontsize.js" language="javascript" type="text/javascript"></script>
+<link rel="shortcut icon" href="images/favicon.ico">
+</head>
+<body onload="init()">
+<script type="text/javascript">ndeSetTextSize();</script>
+<div id="top">
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+<a href="http://www.apache.org/">Apache</a> > <a href="http://hadoop.apache.org/">Hadoop</a> > <a href="http://hadoop.apache.org/zookeeper/">ZooKeeper</a><script src="skin/breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
+</div>
+<!--+
+ |header
+ +-->
+<div class="header">
+<!--+
+ |start group logo
+ +-->
+<div class="grouplogo">
+<a href="http://hadoop.apache.org/"><img class="logoImage" alt="Hadoop" src="images/hadoop-logo.jpg" title="Apache Hadoop"></a>
+</div>
+<!--+
+ |end group logo
+ +-->
+<!--+
+ |start Project Logo
+ +-->
+<div class="projectlogo">
+<a href="http://hadoop.apache.org/zookeeper/"><img class="logoImage" alt="ZooKeeper" src="images/zookeeper_small.gif" title="ZooKeeper: distributed coordination"></a>
+</div>
+<!--+
+ |end Project Logo
+ +-->
+<!--+
+ |start Search
+ +-->
+<div class="searchbox">
+<form action="http://www.google.com/search" method="get" class="roundtopsmall">
+<input value="hadoop.apache.org" name="sitesearch" type="hidden"><input onFocus="getBlank (this, 'Search the site with google');" size="25" name="q" id="query" type="text" value="Search the site with google">
+ <input name="Search" value="Search" type="submit">
+</form>
+</div>
+<!--+
+ |end search
+ +-->
+<!--+
+ |start Tabs
+ +-->
+<ul id="tabs">
+<li>
+<a class="unselected" href="http://hadoop.apache.org/zookeeper/">Project</a>
+</li>
+<li>
+<a class="unselected" href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</li>
+<li class="current">
+<a class="selected" href="index.html">ZooKeeper 3.3 Documentation</a>
+</li>
+</ul>
+<!--+
+ |end Tabs
+ +-->
+</div>
+</div>
+<div id="main">
+<div id="publishedStrip">
+<!--+
+ |start Subtabs
+ +-->
+<div id="level2tabs"></div>
+<!--+
+ |end Endtabs
+ +-->
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+
+
+ </div>
+<!--+
+ |start Menu, mainarea
+ +-->
+<!--+
+ |start Menu
+ +-->
+<div id="menu">
+<div onclick="SwitchMenu('menu_1.1', 'skin/')" id="menu_1.1Title" class="menutitle">Overview</div>
+<div id="menu_1.1" class="menuitemgroup">
+<div class="menuitem">
+<a href="index.html">Welcome</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperOver.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperStarted.html">Getting Started</a>
+</div>
+<div class="menuitem">
+<a href="releasenotes.html">Release Notes</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.2', 'skin/')" id="menu_1.2Title" class="menutitle">Developer</div>
+<div id="menu_1.2" class="menuitemgroup">
+<div class="menuitem">
+<a href="api/index.html">API Docs</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperProgrammers.html">Programmer's Guide</a>
+</div>
+<div class="menuitem">
+<a href="javaExample.html">Java Example</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperTutorial.html">Barrier and Queue Tutorial</a>
+</div>
+<div class="menuitem">
+<a href="recipes.html">Recipes</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.3', 'skin/')" id="menu_1.3Title" class="menutitle">BookKeeper</div>
+<div id="menu_1.3" class="menuitemgroup">
+<div class="menuitem">
+<a href="bookkeeperStarted.html">Getting started</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperOverview.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperConfig.html">Setup guide</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperProgrammer.html">Programmer's guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.4', 'skin/')" id="menu_1.4Title" class="menutitle">Admin & Ops</div>
+<div id="menu_1.4" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperAdmin.html">Administrator's Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperQuotas.html">Quota Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperJMX.html">JMX</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperObservers.html">Observers Guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.5', 'skin/')" id="menu_1.5Title" class="menutitle">Contributor</div>
+<div id="menu_1.5" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperInternals.html">ZooKeeper Internals</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.6', 'skin/')" id="menu_1.6Title" class="menutitle">Miscellaneous</div>
+<div id="menu_1.6" class="menuitemgroup">
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</div>
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper/FAQ">FAQ</a>
+</div>
+<div class="menuitem">
+<a href="http://hadoop.apache.org/zookeeper/mailing_lists.html">Mailing Lists</a>
+</div>
+</div>
+<div id="credit"></div>
+<div id="roundbottom">
+<img style="display: none" class="corner" height="15" width="15" alt="" src="skin/images/rc-b-l-15-1body-2menu-3menu.png"></div>
+<!--+
+ |alternative credits
+ +-->
+<div id="credit2"></div>
+</div>
+<!--+
+ |end Menu
+ +-->
+<!--+
+ |start content
+ +-->
+<div id="content">
+<div title="Portable Document Format" class="pdflink">
+<a class="dida" href="linkmap.pdf"><img alt="PDF -icon" src="skin/images/pdfdoc.gif" class="skin"><br>
+ PDF</a>
+</div>
+<h1>Site Linkmap Table of Contents</h1>
+<div id="front-matter"></div>
+<p>
+ This is a map of the complete site and its structure.
+ </p>
+<ul>
+<li>
+<a>Hadoop</a> ___________________ <em>site</em>
+</li>
+<ul>
+
+
+<ul>
+<li>
+<a>Overview</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="index.html">Welcome</a> ___________________ <em>welcome</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperOver.html">Overview</a> ___________________ <em>overview</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperStarted.html">Getting Started</a> ___________________ <em>started</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="releasenotes.html">Release Notes</a> ___________________ <em>relnotes</em>
+</li>
+</ul>
+
+</ul>
+</ul>
+
+
+<ul>
+<li>
+<a>Developer</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="api/index.html">API Docs</a> ___________________ <em>api</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperProgrammers.html">Programmer's Guide</a> ___________________ <em>program</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="javaExample.html">Java Example</a> ___________________ <em>javaEx</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperTutorial.html">Barrier and Queue Tutorial</a> ___________________ <em>barTutor</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="recipes.html">Recipes</a> ___________________ <em>recipes</em>
+</li>
+</ul>
+
+</ul>
+</ul>
+
+
+<ul>
+<li>
+<a>BookKeeper</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="bookkeeperStarted.html">Getting started</a> ___________________ <em>bkStarted</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="bookkeeperOverview.html">Overview</a> ___________________ <em>bkOverview</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="bookkeeperConfig.html">Setup guide</a> ___________________ <em>bkProgrammer</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="bookkeeperProgrammer.html">Programmer's guide</a> ___________________ <em>bkProgrammer</em>
+</li>
+</ul>
+
+</ul>
+</ul>
+
+
+<ul>
+<li>
+<a>Admin & Ops</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="zookeeperAdmin.html">Administrator's Guide</a> ___________________ <em>admin</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperQuotas.html">Quota Guide</a> ___________________ <em>quota</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperJMX.html">JMX</a> ___________________ <em>jmx</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="zookeeperObservers.html">Observers Guide</a> ___________________ <em>observers</em>
+</li>
+</ul>
+
+</ul>
+</ul>
+
+
+<ul>
+<li>
+<a>Contributor</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="zookeeperInternals.html">ZooKeeper Internals</a> ___________________ <em>internals</em>
+</li>
+</ul>
+
+</ul>
+</ul>
+
+
+<ul>
+<li>
+<a>Miscellaneous</a> ___________________ <em>docs</em>
+</li>
+<ul>
+
+<ul>
+<li>
+<a href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a> ___________________ <em>wiki</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="http://wiki.apache.org/hadoop/ZooKeeper/FAQ">FAQ</a> ___________________ <em>faq</em>
+</li>
+</ul>
+
+<ul>
+<li>
+<a href="http://hadoop.apache.org/zookeeper/mailing_lists.html">Mailing Lists</a> ___________________ <em>lists</em>
+</li>
+</ul>
+
+
+</ul>
+</ul>
+
+
+
+
+
+
+</ul>
+</ul>
+</div>
+<!--+
+ |end content
+ +-->
+<div class="clearboth"> </div>
+</div>
+<div id="footer">
+<!--+
+ |start bottomstrip
+ +-->
+<div class="lastmodified">
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<div class="copyright">
+ Copyright ©
+ 2008 <a href="http://www.apache.org/licenses/">The Apache Software Foundation.</a>
+</div>
+<!--+
+ |end bottomstrip
+ +-->
+</div>
+</body>
+</html>
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/linkmap.pdf
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/linkmap.pdf
------------------------------------------------------------------------------
svn:mime-type = application/pdf
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/recipes.html
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/recipes.html (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/recipes.html Wed Mar 21 06:15:08 2012
@@ -0,0 +1,974 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<meta content="Apache Forrest" name="Generator">
+<meta name="Forrest-version" content="0.9">
+<meta name="Forrest-skin-name" content="pelt">
+<title>ZooKeeper Recipes and Solutions</title>
+<link type="text/css" href="skin/basic.css" rel="stylesheet">
+<link media="screen" type="text/css" href="skin/screen.css" rel="stylesheet">
+<link media="print" type="text/css" href="skin/print.css" rel="stylesheet">
+<link type="text/css" href="skin/profile.css" rel="stylesheet">
+<script src="skin/getBlank.js" language="javascript" type="text/javascript"></script><script src="skin/getMenu.js" language="javascript" type="text/javascript"></script><script src="skin/fontsize.js" language="javascript" type="text/javascript"></script>
+<link rel="shortcut icon" href="images/favicon.ico">
+</head>
+<body onload="init()">
+<script type="text/javascript">ndeSetTextSize();</script>
+<div id="top">
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+<a href="http://www.apache.org/">Apache</a> > <a href="http://hadoop.apache.org/">Hadoop</a> > <a href="http://hadoop.apache.org/zookeeper/">ZooKeeper</a><script src="skin/breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
+</div>
+<!--+
+ |header
+ +-->
+<div class="header">
+<!--+
+ |start group logo
+ +-->
+<div class="grouplogo">
+<a href="http://hadoop.apache.org/"><img class="logoImage" alt="Hadoop" src="images/hadoop-logo.jpg" title="Apache Hadoop"></a>
+</div>
+<!--+
+ |end group logo
+ +-->
+<!--+
+ |start Project Logo
+ +-->
+<div class="projectlogo">
+<a href="http://hadoop.apache.org/zookeeper/"><img class="logoImage" alt="ZooKeeper" src="images/zookeeper_small.gif" title="ZooKeeper: distributed coordination"></a>
+</div>
+<!--+
+ |end Project Logo
+ +-->
+<!--+
+ |start Search
+ +-->
+<div class="searchbox">
+<form action="http://www.google.com/search" method="get" class="roundtopsmall">
+<input value="hadoop.apache.org" name="sitesearch" type="hidden"><input onFocus="getBlank (this, 'Search the site with google');" size="25" name="q" id="query" type="text" value="Search the site with google">
+ <input name="Search" value="Search" type="submit">
+</form>
+</div>
+<!--+
+ |end search
+ +-->
+<!--+
+ |start Tabs
+ +-->
+<ul id="tabs">
+<li>
+<a class="unselected" href="http://hadoop.apache.org/zookeeper/">Project</a>
+</li>
+<li>
+<a class="unselected" href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</li>
+<li class="current">
+<a class="selected" href="index.html">ZooKeeper 3.3 Documentation</a>
+</li>
+</ul>
+<!--+
+ |end Tabs
+ +-->
+</div>
+</div>
+<div id="main">
+<div id="publishedStrip">
+<!--+
+ |start Subtabs
+ +-->
+<div id="level2tabs"></div>
+<!--+
+ |end Endtabs
+ +-->
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+
+
+ </div>
+<!--+
+ |start Menu, mainarea
+ +-->
+<!--+
+ |start Menu
+ +-->
+<div id="menu">
+<div onclick="SwitchMenu('menu_1.1', 'skin/')" id="menu_1.1Title" class="menutitle">Overview</div>
+<div id="menu_1.1" class="menuitemgroup">
+<div class="menuitem">
+<a href="index.html">Welcome</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperOver.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperStarted.html">Getting Started</a>
+</div>
+<div class="menuitem">
+<a href="releasenotes.html">Release Notes</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_selected_1.2', 'skin/')" id="menu_selected_1.2Title" class="menutitle" style="background-image: url('skin/images/chapter_open.gif');">Developer</div>
+<div id="menu_selected_1.2" class="selectedmenuitemgroup" style="display: block;">
+<div class="menuitem">
+<a href="api/index.html">API Docs</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperProgrammers.html">Programmer's Guide</a>
+</div>
+<div class="menuitem">
+<a href="javaExample.html">Java Example</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperTutorial.html">Barrier and Queue Tutorial</a>
+</div>
+<div class="menupage">
+<div class="menupagetitle">Recipes</div>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.3', 'skin/')" id="menu_1.3Title" class="menutitle">BookKeeper</div>
+<div id="menu_1.3" class="menuitemgroup">
+<div class="menuitem">
+<a href="bookkeeperStarted.html">Getting started</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperOverview.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperConfig.html">Setup guide</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperProgrammer.html">Programmer's guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.4', 'skin/')" id="menu_1.4Title" class="menutitle">Admin & Ops</div>
+<div id="menu_1.4" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperAdmin.html">Administrator's Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperQuotas.html">Quota Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperJMX.html">JMX</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperObservers.html">Observers Guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.5', 'skin/')" id="menu_1.5Title" class="menutitle">Contributor</div>
+<div id="menu_1.5" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperInternals.html">ZooKeeper Internals</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.6', 'skin/')" id="menu_1.6Title" class="menutitle">Miscellaneous</div>
+<div id="menu_1.6" class="menuitemgroup">
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</div>
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper/FAQ">FAQ</a>
+</div>
+<div class="menuitem">
+<a href="http://hadoop.apache.org/zookeeper/mailing_lists.html">Mailing Lists</a>
+</div>
+</div>
+<div id="credit"></div>
+<div id="roundbottom">
+<img style="display: none" class="corner" height="15" width="15" alt="" src="skin/images/rc-b-l-15-1body-2menu-3menu.png"></div>
+<!--+
+ |alternative credits
+ +-->
+<div id="credit2"></div>
+</div>
+<!--+
+ |end Menu
+ +-->
+<!--+
+ |start content
+ +-->
+<div id="content">
+<div title="Portable Document Format" class="pdflink">
+<a class="dida" href="recipes.pdf"><img alt="PDF -icon" src="skin/images/pdfdoc.gif" class="skin"><br>
+ PDF</a>
+</div>
+<h1>ZooKeeper Recipes and Solutions</h1>
+<div id="front-matter">
+<div id="minitoc-area">
+<ul class="minitoc">
+<li>
+<a href="#ch_recipes">A Guide to Creating Higher-level Constructs with ZooKeeper</a>
+<ul class="minitoc">
+<li>
+<a href="#sc_outOfTheBox">Out of the Box Applications: Name Service, Configuration, Group
+ Membership</a>
+</li>
+<li>
+<a href="#sc_recipes_eventHandles">Barriers</a>
+<ul class="minitoc">
+<li>
+<a href="#sc_doubleBarriers">Double Barriers</a>
+</li>
+</ul>
+</li>
+<li>
+<a href="#sc_recipes_Queues">Queues</a>
+<ul class="minitoc">
+<li>
+<a href="#sc_recipes_priorityQueues">Priority Queues</a>
+</li>
+</ul>
+</li>
+<li>
+<a href="#sc_recipes_Locks">Locks</a>
+<ul class="minitoc">
+<li>
+<a href="#Shared+Locks">Shared Locks</a>
+</li>
+<li>
+<a href="#sc_recoverableSharedLocks">Recoverable Shared Locks</a>
+</li>
+</ul>
+</li>
+<li>
+<a href="#sc_recipes_twoPhasedCommit">Two-phased Commit</a>
+</li>
+<li>
+<a href="#sc_leaderElection">Leader Election</a>
+</li>
+</ul>
+</li>
+</ul>
+</div>
+</div>
+
+
+
+
+
+<a name="ch_recipes"></a>
+<h2 class="h3">A Guide to Creating Higher-level Constructs with ZooKeeper</h2>
+<div class="section">
+<p>In this article, you'll find guidelines for using
+ ZooKeeper to implement higher order functions. All of them are conventions
+ implemented at the client and do not require special support from
+ ZooKeeper. Hopfully the community will capture these conventions in client-side libraries
+ to ease their use and to encourage standardization.</p>
+<p>One of the most interesting things about ZooKeeper is that even
+ though ZooKeeper uses <em>asynchronous</em> notifications, you
+ can use it to build <em>synchronous</em> consistency
+ primitives, such as queues and locks. As you will see, this is possible
+ because ZooKeeper imposes an overall order on updates, and has mechanisms
+ to expose this ordering.</p>
+<p>Note that the recipes below attempt to employ best practices. In
+ particular, they avoid polling, timers or anything else that would result
+ in a "herd effect", causing bursts of traffic and limiting
+ scalability.</p>
+<p>There are many useful functions that can be imagined that aren't
+ included here - revocable read-write priority locks, as just one example.
+ And some of the constructs mentioned here - locks, in particular -
+ illustrate certain points, even though you may find other constructs, such
+ as event handles or queues, a more practical means of performing the same
+ function. In general, the examples in this section are designed to
+ stimulate thought.</p>
+<a name="sc_outOfTheBox"></a>
+<h3 class="h4">Out of the Box Applications: Name Service, Configuration, Group
+ Membership</h3>
+<p>Name service and configuration are two of the primary applications
+ of ZooKeeper. These two functions are provided directly by the ZooKeeper
+ API.</p>
+<p>Another function directly provided by ZooKeeper is <em>group
+ membership</em>. The group is represented by a node. Members of the
+ group create ephemeral nodes under the group node. Nodes of the members
+ that fail abnormally will be removed automatically when ZooKeeper detects
+ the failure.</p>
+<a name="sc_recipes_eventHandles"></a>
+<h3 class="h4">Barriers</h3>
+<p>Distributed systems use <em>barriers</em>
+ to block processing of a set of nodes until a condition is met
+ at which time all the nodes are allowed to proceed. Barriers are
+ implemented in ZooKeeper by designating a barrier node. The
+ barrier is in place if the barrier node exists. Here's the
+ pseudo code:</p>
+<ol>
+
+<li>
+
+<p>Client calls the ZooKeeper API's <strong>exists()</strong> function on the barrier node, with
+ <em>watch</em> set to true.</p>
+
+</li>
+
+
+<li>
+
+<p>If <strong>exists()</strong> returns false, the
+ barrier is gone and the client proceeds</p>
+
+</li>
+
+
+<li>
+
+<p>Else, if <strong>exists()</strong> returns true,
+ the clients wait for a watch event from ZooKeeper for the barrier
+ node.</p>
+
+</li>
+
+
+<li>
+
+<p>When the watch event is triggered, the client reissues the
+ <strong>exists( )</strong> call, again waiting until
+ the barrier node is removed.</p>
+
+</li>
+
+</ol>
+<a name="sc_doubleBarriers"></a>
+<h4>Double Barriers</h4>
+<p>Double barriers enable clients to synchronize the beginning and
+ the end of a computation. When enough processes have joined the barrier,
+ processes start their computation and leave the barrier once they have
+ finished. This recipe shows how to use a ZooKeeper node as a
+ barrier.</p>
+<p>The pseudo code in this recipe represents the barrier node as
+ <em>b</em>. Every client process <em>p</em>
+ registers with the barrier node on entry and unregisters when it is
+ ready to leave. A node registers with the barrier node via the <strong>Enter</strong> procedure below, it waits until
+ <em>x</em> client process register before proceeding with
+ the computation. (The <em>x</em> here is up to you to
+ determine for your system.)</p>
+<table class="ForrestTable" cellspacing="1" cellpadding="4">
+
+
+<tr>
+
+<td><strong>Enter</strong></td>
+
+ <td><strong>Leave</strong></td>
+
+</tr>
+
+
+<tr>
+
+<td>
+<ol>
+
+<li>
+
+<p>Create a name <em><em>n</em> =
+ <em>b</em>+“/”+<em>p</em></em>
+</p>
+
+</li>
+
+
+<li>
+
+<p>Set watch: <strong>exists(<em>b</em> + ‘‘/ready’’,
+ true)</strong>
+</p>
+
+</li>
+
+
+<li>
+
+<p>Create child: <strong>create(
+ <em>n</em>, EPHEMERAL)</strong>
+</p>
+
+</li>
+
+
+<li>
+
+<p>
+<strong>L = getChildren(b,
+ false)</strong>
+</p>
+
+</li>
+
+
+<li>
+
+<p>if fewer children in L than<em>
+ x</em>, wait for watch event</p>
+
+</li>
+
+
+<li>
+
+<p>else <strong>create(b + ‘‘/ready’’,
+ REGULAR)</strong>
+</p>
+
+</li>
+
+</ol>
+</td>
+
+ <td>
+<ol>
+
+<li>
+
+<p>
+<strong>L = getChildren(b,
+ false)</strong>
+</p>
+
+</li>
+
+
+<li>
+
+<p>if no children, exit</p>
+
+</li>
+
+
+<li>
+
+<p>if <em>p</em> is only process node in
+ L, delete(n) and exit</p>
+
+</li>
+
+
+<li>
+
+<p>if <em>p</em> is the lowest process
+ node in L, wait on highest process node in P</p>
+
+</li>
+
+
+<li>
+
+<p>else <strong>delete(<em>n</em>) </strong>if
+ still exists and wait on lowest process node in L</p>
+
+</li>
+
+
+<li>
+
+<p>goto 1</p>
+
+</li>
+
+</ol>
+</td>
+
+</tr>
+
+
+</table>
+<p>On entering, all processes watch on a ready node and
+ create an ephemeral node as a child of the barrier node. Each process
+ but the last enters the barrier and waits for the ready node to appear
+ at line 5. The process that creates the xth node, the last process, will
+ see x nodes in the list of children and create the ready node, waking up
+ the other processes. Note that waiting processes wake up only when it is
+ time to exit, so waiting is efficient.
+ </p>
+<p>On exit, you can't use a flag such as <em>ready</em>
+ because you are watching for process nodes to go away. By using
+ ephemeral nodes, processes that fail after the barrier has been entered
+ do not prevent correct processes from finishing. When processes are
+ ready to leave, they need to delete their process nodes and wait for all
+ other processes to do the same.</p>
+<p>Processes exit when there are no process nodes left as children of
+ <em>b</em>. However, as an efficiency, you can use the
+ lowest process node as the ready flag. All other processes that are
+ ready to exit watch for the lowest existing process node to go away, and
+ the owner of the lowest process watches for any other process node
+ (picking the highest for simplicity) to go away. This means that only a
+ single process wakes up on each node deletion except for the last node,
+ which wakes up everyone when it is removed.</p>
+<a name="sc_recipes_Queues"></a>
+<h3 class="h4">Queues</h3>
+<p>Distributed queues are a common data structure. To implement a
+ distributed queue in ZooKeeper, first designate a znode to hold the queue,
+ the queue node. The distributed clients put something into the queue by
+ calling create() with a pathname ending in "queue-", with the
+ <em>sequence</em> and <em>ephemeral</em> flags in
+ the create() call set to true. Because the <em>sequence</em>
+ flag is set, the new pathnames will have the form
+ _path-to-queue-node_/queue-X, where X is a monotonic increasing number. A
+ client that wants to be removed from the queue calls ZooKeeper's <strong>getChildren( )</strong> function, with
+ <em>watch</em> set to true on the queue node, and begins
+ processing nodes with the lowest number. The client does not need to issue
+ another <strong>getChildren( )</strong> until it exhausts
+ the list obtained from the first <strong>getChildren(
+ )</strong> call. If there are are no children in the queue node, the
+ reader waits for a watch notification to check the queue again.</p>
+<div class="note">
+<div class="label">Note</div>
+<div class="content">
+
+<p>There now exists a Queue implementation in ZooKeeper
+ recipes directory. This is distributed with the release --
+ src/recipes/queue directory of the release artifact.
+ </p>
+
+</div>
+</div>
+<a name="sc_recipes_priorityQueues"></a>
+<h4>Priority Queues</h4>
+<p>To implement a priority queue, you need only make two simple
+ changes to the generic <a href="#sc_recipes_Queues">queue
+ recipe</a> . First, to add to a queue, the pathname ends with
+ "queue-YY" where YY is the priority of the element with lower numbers
+ representing higher priority (just like UNIX). Second, when removing
+ from the queue, a client uses an up-to-date children list meaning that
+ the client will invalidate previously obtained children lists if a watch
+ notification triggers for the queue node.</p>
+<a name="sc_recipes_Locks"></a>
+<h3 class="h4">Locks</h3>
+<p>Fully distributed locks that are globally synchronous, meaning at
+ any snapshot in time no two clients think they hold the same lock. These
+ can be implemented using ZooKeeeper. As with priority queues, first define
+ a lock node.</p>
+<div class="note">
+<div class="label">Note</div>
+<div class="content">
+
+<p>There now exists a Lock implementation in ZooKeeper
+ recipes directory. This is distributed with the release --
+ src/recipes/lock directory of the release artifact.
+ </p>
+
+</div>
+</div>
+<p>Clients wishing to obtain a lock do the following:</p>
+<ol>
+
+<li>
+
+<p>Call <strong>create( )</strong> with a pathname
+ of "_locknode_/lock-" and the <em>sequence</em> and
+ <em>ephemeral</em> flags set.</p>
+
+</li>
+
+
+<li>
+
+<p>Call <strong>getChildren( )</strong> on the lock
+ node <em>without</em> setting the watch flag (this is
+ important to avoid the herd effect).</p>
+
+</li>
+
+
+<li>
+
+<p>If the pathname created in step <strong>1</strong> has the lowest sequence number suffix, the
+ client has the lock and the client exits the protocol.</p>
+
+</li>
+
+
+<li>
+
+<p>The client calls <strong>exists( )</strong> with
+ the watch flag set on the path in the lock directory with the next
+ lowest sequence number.</p>
+
+</li>
+
+
+<li>
+
+<p>if <strong>exists( )</strong> returns false, go
+ to step <strong>2</strong>. Otherwise, wait for a
+ notification for the pathname from the previous step before going to
+ step <strong>2</strong>.</p>
+
+</li>
+
+</ol>
+<p>The unlock protocol is very simple: clients wishing to release a
+ lock simply delete the node they created in step 1.</p>
+<p>Here are a few things to notice:</p>
+<ul>
+
+<li>
+
+<p>The removal of a node will only cause one client to wake up
+ since each node is watched by exactly one client. In this way, you
+ avoid the herd effect.</p>
+
+</li>
+
+</ul>
+<ul>
+
+<li>
+
+<p>There is no polling or timeouts.</p>
+
+</li>
+
+</ul>
+<ul>
+
+<li>
+
+<p>Because of the way you implement locking, it is easy to see the
+ amount of lock contention, break locks, debug locking problems,
+ etc.</p>
+
+</li>
+
+</ul>
+<a name="Shared+Locks"></a>
+<h4>Shared Locks</h4>
+<p>You can implement shared locks by with a few changes to the lock
+ protocol:</p>
+<table class="ForrestTable" cellspacing="1" cellpadding="4">
+
+
+<tr>
+
+<td><strong>Obtaining a read
+ lock:</strong></td>
+
+ <td><strong>Obtaining a write
+ lock:</strong></td>
+
+</tr>
+
+
+<tr>
+
+<td>
+<ol>
+
+<li>
+
+<p>Call <strong>create( )</strong> to
+ create a node with pathname
+ "<span class="codefrag filename">_locknode_/read-</span>". This is the
+ lock node use later in the protocol. Make sure to set both
+ the <em>sequence</em> and
+ <em>ephemeral</em> flags.</p>
+
+</li>
+
+
+<li>
+
+<p>Call <strong>getChildren( )</strong>
+ on the lock node <em>without</em> setting the
+ <em>watch</em> flag - this is important, as it
+ avoids the herd effect.</p>
+
+</li>
+
+
+<li>
+
+<p>If there are no children with a pathname starting
+ with "<span class="codefrag filename">write-</span>" and having a lower
+ sequence number than the node created in step <strong>1</strong>, the client has the lock and can
+ exit the protocol. </p>
+
+</li>
+
+
+<li>
+
+<p>Otherwise, call <strong>exists(
+ )</strong>, with <em>watch</em> flag, set on
+ the node in lock directory with pathname staring with
+ "<span class="codefrag filename">write-</span>" having the next lowest
+ sequence number.</p>
+
+</li>
+
+
+<li>
+
+<p>If <strong>exists( )</strong>
+ returns <em>false</em>, goto step <strong>2</strong>.</p>
+
+</li>
+
+
+<li>
+
+<p>Otherwise, wait for a notification for the pathname
+ from the previous step before going to step <strong>2</strong>
+</p>
+
+</li>
+
+</ol>
+</td>
+
+ <td>
+<ol>
+
+<li>
+
+<p>Call <strong>create( )</strong> to
+ create a node with pathname
+ "<span class="codefrag filename">_locknode_/write-</span>". This is the
+ lock node spoken of later in the protocol. Make sure to
+ set both <em>sequence</em> and
+ <em>ephemeral</em> flags.</p>
+
+</li>
+
+
+<li>
+
+<p>Call <strong>getChildren( )
+ </strong> on the lock node <em>without</em>
+ setting the <em>watch</em> flag - this is
+ important, as it avoids the herd effect.</p>
+
+</li>
+
+
+<li>
+
+<p>If there are no children with a lower sequence
+ number than the node created in step <strong>1</strong>, the client has the lock and the
+ client exits the protocol.</p>
+
+</li>
+
+
+<li>
+
+<p>Call <strong>exists( ),</strong>
+ with <em>watch</em> flag set, on the node with
+ the pathname that has the next lowest sequence
+ number.</p>
+
+</li>
+
+
+<li>
+
+<p>If <strong>exists( )</strong>
+ returns <em>false</em>, goto step <strong>2</strong>. Otherwise, wait for a
+ notification for the pathname from the previous step
+ before going to step <strong>2</strong>.</p>
+
+</li>
+
+</ol>
+</td>
+
+</tr>
+
+
+</table>
+<div class="note">
+<div class="label">Note</div>
+<div class="content">
+
+<p>It might appear that this recipe creates a herd effect:
+ when there is a large group of clients waiting for a read
+ lock, and all getting notified more or less simultaneously
+ when the "<span class="codefrag filename">write-</span>" node with the lowest
+ sequence number is deleted. In fact. that's valid behavior:
+ as all those waiting reader clients should be released since
+ they have the lock. The herd effect refers to releasing a
+ "herd" when in fact only a single or a small number of
+ machines can proceed.
+ </p>
+
+</div>
+</div>
+<a name="sc_recoverableSharedLocks"></a>
+<h4>Recoverable Shared Locks</h4>
+<p>With minor modifications to the Shared Lock protocol, you make
+ shared locks revocable by modifying the shared lock protocol:</p>
+<p>In step <strong>1</strong>, of both obtain reader
+ and writer lock protocols, call <strong>getData(
+ )</strong> with <em>watch</em> set, immediately after the
+ call to <strong>create( )</strong>. If the client
+ subsequently receives notification for the node it created in step
+ <strong>1</strong>, it does another <strong>getData( )</strong> on that node, with
+ <em>watch</em> set and looks for the string "unlock", which
+ signals to the client that it must release the lock. This is because,
+ according to this shared lock protocol, you can request the client with
+ the lock give up the lock by calling <strong>setData()
+ </strong> on the lock node, writing "unlock" to that node.</p>
+<p>Note that this protocol requires the lock holder to consent to
+ releasing the lock. Such consent is important, especially if the lock
+ holder needs to do some processing before releasing the lock. Of course
+ you can always implement <em>Revocable Shared Locks with Freaking
+ Laser Beams</em> by stipulating in your protocol that the revoker
+ is allowed to delete the lock node if after some length of time the lock
+ isn't deleted by the lock holder.</p>
+<a name="sc_recipes_twoPhasedCommit"></a>
+<h3 class="h4">Two-phased Commit</h3>
+<p>A two-phase commit protocol is an algorithm that lets all clients in
+ a distributed system agree either to commit a transaction or abort.</p>
+<p>In ZooKeeper, you can implement a two-phased commit by having a
+ coordinator create a transaction node, say "/app/Tx", and one child node
+ per participating site, say "/app/Tx/s_i". When coordinator creates the
+ child node, it leaves the content undefined. Once each site involved in
+ the transaction receives the transaction from the coordinator, the site
+ reads each child node and sets a watch. Each site then processes the query
+ and votes "commit" or "abort" by writing to its respective node. Once the
+ write completes, the other sites are notified, and as soon as all sites
+ have all votes, they can decide either "abort" or "commit". Note that a
+ node can decide "abort" earlier if some site votes for "abort".</p>
+<p>An interesting aspect of this implementation is that the only role
+ of the coordinator is to decide upon the group of sites, to create the
+ ZooKeeper nodes, and to propagate the transaction to the corresponding
+ sites. In fact, even propagating the transaction can be done through
+ ZooKeeper by writing it in the transaction node.</p>
+<p>There are two important drawbacks of the approach described above.
+ One is the message complexity, which is O(n²). The second is the
+ impossibility of detecting failures of sites through ephemeral nodes. To
+ detect the failure of a site using ephemeral nodes, it is necessary that
+ the site create the node.</p>
+<p>To solve the first problem, you can have only the coordinator
+ notified of changes to the transaction nodes, and then notify the sites
+ once coordinator reaches a decision. Note that this approach is scalable,
+ but it's is slower too, as it requires all communication to go through the
+ coordinator.</p>
+<p>To address the second problem, you can have the coordinator
+ propagate the transaction to the sites, and have each site creating its
+ own ephemeral node.</p>
+<a name="sc_leaderElection"></a>
+<h3 class="h4">Leader Election</h3>
+<p>A simple way of doing leader election with ZooKeeper is to use the
+ <strong>SEQUENCE|EPHEMERAL</strong> flags when creating
+ znodes that represent "proposals" of clients. The idea is to have a znode,
+ say "/election", such that each znode creates a child znode "/election/n_"
+ with both flags SEQUENCE|EPHEMERAL. With the sequence flag, ZooKeeper
+ automatically appends a sequence number that is greater that any one
+ previously appended to a child of "/election". The process that created
+ the znode with the smallest appended sequence number is the leader.
+ </p>
+<p>That's not all, though. It is important to watch for failures of the
+ leader, so that a new client arises as the new leader in the case the
+ current leader fails. A trivial solution is to have all application
+ processes watching upon the current smallest znode, and checking if they
+ are the new leader when the smallest znode goes away (note that the
+ smallest znode will go away if the leader fails because the node is
+ ephemeral). But this causes a herd effect: upon of failure of the current
+ leader, all other processes receive a notification, and execute
+ getChildren on "/election" to obtain the current list of children of
+ "/election". If the number of clients is large, it causes a spike on the
+ number of operations that ZooKeeper servers have to process. To avoid the
+ herd effect, it is sufficient to watch for the next znode down on the
+ sequence of znodes. If a client receives a notification that the znode it
+ is watching is gone, then it becomes the new leader in the case that there
+ is no smaller znode. Note that this avoids the herd effect by not having
+ all clients watching the same znode. </p>
+<p>Here's the pseudo code:</p>
+<p>Let ELECTION be a path of choice of the application. To volunteer to
+ be a leader: </p>
+<ol>
+
+<li>
+
+<p>Create znode z with path "ELECTION/n_" with both SEQUENCE and
+ EPHEMERAL flags;</p>
+
+</li>
+
+
+<li>
+
+<p>Let C be the children of "ELECTION", and i be the sequence
+ number of z;</p>
+
+</li>
+
+
+<li>
+
+<p>Watch for changes on "ELECTION/n_j", where j is the smallest
+ sequence number such that j < i and n_j is a znode in C;</p>
+
+</li>
+
+</ol>
+<p>Upon receiving a notification of znode deletion: </p>
+<ol>
+
+<li>
+
+<p>Let C be the new set of children of ELECTION; </p>
+
+</li>
+
+
+<li>
+
+<p>If z is the smallest node in C, then execute leader
+ procedure;</p>
+
+</li>
+
+
+<li>
+
+<p>Otherwise, watch for changes on "ELECTION/n_j", where j is the
+ smallest sequence number such that j < i and n_j is a znode in C;
+ </p>
+
+</li>
+
+</ol>
+<p>Note that the znode having no preceding znode on the list of
+ children does not imply that the creator of this znode is aware that it is
+ the current leader. Applications may consider creating a separate to znode
+ to acknowledge that the leader has executed the leader procedure. </p>
+</div>
+
+<p align="right">
+<font size="-2"></font>
+</p>
+</div>
+<!--+
+ |end content
+ +-->
+<div class="clearboth"> </div>
+</div>
+<div id="footer">
+<!--+
+ |start bottomstrip
+ +-->
+<div class="lastmodified">
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<div class="copyright">
+ Copyright ©
+ 2008 <a href="http://www.apache.org/licenses/">The Apache Software Foundation.</a>
+</div>
+<!--+
+ |end bottomstrip
+ +-->
+</div>
+</body>
+</html>
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/recipes.pdf
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/recipes.pdf
------------------------------------------------------------------------------
svn:mime-type = application/pdf
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/releasenotes.html
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/releasenotes.html (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/releasenotes.html Wed Mar 21 06:15:08 2012
@@ -0,0 +1,349 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<meta content="Apache Forrest" name="Generator">
+<meta name="Forrest-version" content="0.9">
+<meta name="Forrest-skin-name" content="pelt">
+<title>ZooKeeper 3.3.5 Release Notes</title>
+<link type="text/css" href="skin/basic.css" rel="stylesheet">
+<link media="screen" type="text/css" href="skin/screen.css" rel="stylesheet">
+<link media="print" type="text/css" href="skin/print.css" rel="stylesheet">
+<link type="text/css" href="skin/profile.css" rel="stylesheet">
+<script src="skin/getBlank.js" language="javascript" type="text/javascript"></script><script src="skin/getMenu.js" language="javascript" type="text/javascript"></script><script src="skin/fontsize.js" language="javascript" type="text/javascript"></script>
+<link rel="shortcut icon" href="images/favicon.ico">
+</head>
+<body onload="init()">
+<script type="text/javascript">ndeSetTextSize();</script>
+<div id="top">
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+<a href="http://www.apache.org/">Apache</a> > <a href="http://hadoop.apache.org/">Hadoop</a> > <a href="http://hadoop.apache.org/zookeeper/">ZooKeeper</a><script src="skin/breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
+</div>
+<!--+
+ |header
+ +-->
+<div class="header">
+<!--+
+ |start group logo
+ +-->
+<div class="grouplogo">
+<a href="http://hadoop.apache.org/"><img class="logoImage" alt="Hadoop" src="images/hadoop-logo.jpg" title="Apache Hadoop"></a>
+</div>
+<!--+
+ |end group logo
+ +-->
+<!--+
+ |start Project Logo
+ +-->
+<div class="projectlogo">
+<a href="http://hadoop.apache.org/zookeeper/"><img class="logoImage" alt="ZooKeeper" src="images/zookeeper_small.gif" title="ZooKeeper: distributed coordination"></a>
+</div>
+<!--+
+ |end Project Logo
+ +-->
+<!--+
+ |start Search
+ +-->
+<div class="searchbox">
+<form action="http://www.google.com/search" method="get" class="roundtopsmall">
+<input value="hadoop.apache.org" name="sitesearch" type="hidden"><input onFocus="getBlank (this, 'Search the site with google');" size="25" name="q" id="query" type="text" value="Search the site with google">
+ <input name="Search" value="Search" type="submit">
+</form>
+</div>
+<!--+
+ |end search
+ +-->
+<!--+
+ |start Tabs
+ +-->
+<ul id="tabs">
+<li>
+<a class="unselected" href="http://hadoop.apache.org/zookeeper/">Project</a>
+</li>
+<li>
+<a class="unselected" href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</li>
+<li class="current">
+<a class="selected" href="index.html">ZooKeeper 3.3 Documentation</a>
+</li>
+</ul>
+<!--+
+ |end Tabs
+ +-->
+</div>
+</div>
+<div id="main">
+<div id="publishedStrip">
+<!--+
+ |start Subtabs
+ +-->
+<div id="level2tabs"></div>
+<!--+
+ |end Endtabs
+ +-->
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<!--+
+ |breadtrail
+ +-->
+<div class="breadtrail">
+
+
+ </div>
+<!--+
+ |start Menu, mainarea
+ +-->
+<!--+
+ |start Menu
+ +-->
+<div id="menu">
+<div onclick="SwitchMenu('menu_selected_1.1', 'skin/')" id="menu_selected_1.1Title" class="menutitle" style="background-image: url('skin/images/chapter_open.gif');">Overview</div>
+<div id="menu_selected_1.1" class="selectedmenuitemgroup" style="display: block;">
+<div class="menuitem">
+<a href="index.html">Welcome</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperOver.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperStarted.html">Getting Started</a>
+</div>
+<div class="menupage">
+<div class="menupagetitle">Release Notes</div>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.2', 'skin/')" id="menu_1.2Title" class="menutitle">Developer</div>
+<div id="menu_1.2" class="menuitemgroup">
+<div class="menuitem">
+<a href="api/index.html">API Docs</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperProgrammers.html">Programmer's Guide</a>
+</div>
+<div class="menuitem">
+<a href="javaExample.html">Java Example</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperTutorial.html">Barrier and Queue Tutorial</a>
+</div>
+<div class="menuitem">
+<a href="recipes.html">Recipes</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.3', 'skin/')" id="menu_1.3Title" class="menutitle">BookKeeper</div>
+<div id="menu_1.3" class="menuitemgroup">
+<div class="menuitem">
+<a href="bookkeeperStarted.html">Getting started</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperOverview.html">Overview</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperConfig.html">Setup guide</a>
+</div>
+<div class="menuitem">
+<a href="bookkeeperProgrammer.html">Programmer's guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.4', 'skin/')" id="menu_1.4Title" class="menutitle">Admin & Ops</div>
+<div id="menu_1.4" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperAdmin.html">Administrator's Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperQuotas.html">Quota Guide</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperJMX.html">JMX</a>
+</div>
+<div class="menuitem">
+<a href="zookeeperObservers.html">Observers Guide</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.5', 'skin/')" id="menu_1.5Title" class="menutitle">Contributor</div>
+<div id="menu_1.5" class="menuitemgroup">
+<div class="menuitem">
+<a href="zookeeperInternals.html">ZooKeeper Internals</a>
+</div>
+</div>
+<div onclick="SwitchMenu('menu_1.6', 'skin/')" id="menu_1.6Title" class="menutitle">Miscellaneous</div>
+<div id="menu_1.6" class="menuitemgroup">
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper">Wiki</a>
+</div>
+<div class="menuitem">
+<a href="http://wiki.apache.org/hadoop/ZooKeeper/FAQ">FAQ</a>
+</div>
+<div class="menuitem">
+<a href="http://hadoop.apache.org/zookeeper/mailing_lists.html">Mailing Lists</a>
+</div>
+</div>
+<div id="credit"></div>
+<div id="roundbottom">
+<img style="display: none" class="corner" height="15" width="15" alt="" src="skin/images/rc-b-l-15-1body-2menu-3menu.png"></div>
+<!--+
+ |alternative credits
+ +-->
+<div id="credit2"></div>
+</div>
+<!--+
+ |end Menu
+ +-->
+<!--+
+ |start content
+ +-->
+<div id="content">
+<div title="Portable Document Format" class="pdflink">
+<a class="dida" href="releasenotes.pdf"><img alt="PDF -icon" src="skin/images/pdfdoc.gif" class="skin"><br>
+ PDF</a>
+</div>
+<h1>ZooKeeper 3.3.5 Release Notes</h1>
+<div id="front-matter">
+<div id="minitoc-area">
+<ul class="minitoc">
+<li>
+<a href="#changes">Changes Since ZooKeeper 3.3.4</a>
+</li>
+</ul>
+</div>
+</div>
+
+
+
+
+
+<p>
+These release notes include new developer and user facing
+incompatibilities, features, and major improvements.
+</p>
+
+
+<p>See <a href="http://hadoop.apache.org/zookeeper/docs/r3.0.1/releasenotes.html#migration">3.0
+release notes and migration instructions</a> if you are upgrading
+from version 2 of ZooKeeper (SourceForge) to version 3 or
+later.</p>
+
+
+<a name="changes"></a>
+<h2 class="h3">Changes Since ZooKeeper 3.3.4</h2>
+<div class="section">
+<table class="ForrestTable" cellspacing="1" cellpadding="4">
+<caption>Changes Since ZooKeeper 3.3.4</caption>
+
+<title>Changes Since ZooKeeper 3.3.4</title>
+
+
+<tr>
+
+<th>Issue</th>
+ <th>Notes</th>
+
+</tr>
+
+
+
+<tr>
+<td> Bug
+</td><td></td>
+</tr>
+
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-973">ZOOKEEPER-973</a>]</td><td> bind() could fail on Leader because it does not setReuseAddress on its ServerSocket
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1089">ZOOKEEPER-1089</a>]</td><td> zkServer.sh status does not work due to invalid option of nc
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1277">ZOOKEEPER-1277</a>]</td><td> servers stop serving when lower 32bits of zxid roll over
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1309">ZOOKEEPER-1309</a>]</td><td> Creating a new ZooKeeper client can leak file handles
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1352">ZOOKEEPER-1352</a>]</td><td> server.InvalidSnapshotTest is using connection timeouts that are too short
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1353">ZOOKEEPER-1353</a>]</td><td> C client test suite fails consistently
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1367">ZOOKEEPER-1367</a>]</td><td> Data inconsistencies and unexpired ephemeral nodes after cluster restart
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1386">ZOOKEEPER-1386</a>]</td><td> avoid flaky URL redirection in "ant javadoc" : replace "http://java.sun.com/javase/6/docs/api/" with "http://download.oracle.com/javase/6/docs/api/"
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1412">ZOOKEEPER-1412</a>]</td><td> java client watches inconsistently triggered on reconnect
+</td>
+</tr>
+
+
+<tr>
+<td> Improvement
+</td><td></td>
+</tr>
+
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1345">ZOOKEEPER-1345</a>]</td><td> Add a .gitignore file with general exclusions and Eclipse project files excluded
+</td>
+</tr>
+
+<tr>
+<td>[<a href="https://issues.apache.org/jira/browse/ZOOKEEPER-1389">ZOOKEEPER-1389</a>]</td><td> it would be nice if start-foreground used exec $JAVA in order to get rid of the intermediate shell process
+</td>
+</tr>
+
+
+</table>
+</div>
+
+<p align="right">
+<font size="-2"></font>
+</p>
+</div>
+<!--+
+ |end content
+ +-->
+<div class="clearboth"> </div>
+</div>
+<div id="footer">
+<!--+
+ |start bottomstrip
+ +-->
+<div class="lastmodified">
+<script type="text/javascript"><!--
+document.write("Last Published: " + document.lastModified);
+// --></script>
+</div>
+<div class="copyright">
+ Copyright ©
+ 2008 <a href="http://www.apache.org/licenses/">The Apache Software Foundation.</a>
+</div>
+<!--+
+ |end bottomstrip
+ +-->
+</div>
+</body>
+</html>
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/releasenotes.pdf
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/releasenotes.pdf
------------------------------------------------------------------------------
svn:mime-type = application/pdf
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_de.xml
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_de.xml
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_en_US.xml
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_en_US.xml
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_es.xml
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_es.xml
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_fr.xml
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/CommonMessages_fr.xml
------------------------------------------------------------------------------
svn:mime-type = application/xml
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/basic.css
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/basic.css (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/basic.css Wed Mar 21 06:15:08 2012
@@ -0,0 +1,167 @@
+/*
+* 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.
+*/
+/**
+ * General
+ */
+
+img { border: 0; }
+
+#content table {
+ border: 0;
+ width: 100%;
+}
+/*Hack to get IE to render the table at 100%*/
+* html #content table { margin-left: -3px; }
+
+#content th,
+#content td {
+ margin: 0;
+ padding: 0;
+ vertical-align: top;
+}
+
+.clearboth {
+ clear: both;
+}
+
+.note, .warning, .fixme {
+ clear:right;
+ border: solid black 1px;
+ margin: 1em 3em;
+}
+
+.note .label {
+ background: #369;
+ color: white;
+ font-weight: bold;
+ padding: 5px 10px;
+}
+.note .content {
+ background: #F0F0FF;
+ color: black;
+ line-height: 120%;
+ font-size: 90%;
+ padding: 5px 10px;
+}
+.warning .label {
+ background: #C00;
+ color: white;
+ font-weight: bold;
+ padding: 5px 10px;
+}
+.warning .content {
+ background: #FFF0F0;
+ color: black;
+ line-height: 120%;
+ font-size: 90%;
+ padding: 5px 10px;
+}
+.fixme .label {
+ background: #C6C600;
+ color: black;
+ font-weight: bold;
+ padding: 5px 10px;
+}
+.fixme .content {
+ padding: 5px 10px;
+}
+
+/**
+ * Typography
+ */
+
+body {
+ font-family: verdana, "Trebuchet MS", arial, helvetica, sans-serif;
+ font-size: 100%;
+}
+
+#content {
+ font-family: Georgia, Palatino, Times, serif;
+ font-size: 95%;
+}
+#tabs {
+ font-size: 70%;
+}
+#menu {
+ font-size: 80%;
+}
+#footer {
+ font-size: 70%;
+}
+
+h1, h2, h3, h4, h5, h6 {
+ font-family: "Trebuchet MS", verdana, arial, helvetica, sans-serif;
+ font-weight: bold;
+ margin-top: 1em;
+ margin-bottom: .5em;
+}
+
+h1 {
+ margin-top: 0;
+ margin-bottom: 1em;
+ font-size: 1.4em;
+}
+#content h1 {
+ font-size: 160%;
+ margin-bottom: .5em;
+}
+#menu h1 {
+ margin: 0;
+ padding: 10px;
+ background: #336699;
+ color: white;
+}
+h2 { font-size: 120%; }
+h3 { font-size: 100%; }
+h4 { font-size: 90%; }
+h5 { font-size: 80%; }
+h6 { font-size: 75%; }
+
+p {
+ line-height: 120%;
+ text-align: left;
+ margin-top: .5em;
+ margin-bottom: 1em;
+}
+
+#content li,
+#content th,
+#content td,
+#content li ul,
+#content li ol{
+ margin-top: .5em;
+ margin-bottom: .5em;
+}
+
+
+#content li li,
+#minitoc-area li{
+ margin-top: 0em;
+ margin-bottom: 0em;
+}
+
+#content .attribution {
+ text-align: right;
+ font-style: italic;
+ font-size: 85%;
+ margin-top: 1em;
+}
+
+.codefrag {
+ font-family: "Courier New", Courier, monospace;
+ font-size: 110%;
+}
\ No newline at end of file
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs-optimized.js
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs-optimized.js (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs-optimized.js Wed Mar 21 06:15:08 2012
@@ -0,0 +1,90 @@
+/*
+* 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.
+*/
+var PREPREND_CRUMBS=new Array();
+var link1="@skinconfig.trail.link1.name@";
+var link2="@skinconfig.trail.link2.name@";
+var link3="@skinconfig.trail.link3.name@";
+if(!(link1=="")&&!link1.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link1, @skinconfig.trail.link1.href@ ) ); }
+if(!(link2=="")&&!link2.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link2, @skinconfig.trail.link2.href@ ) ); }
+if(!(link3=="")&&!link3.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link3, @skinconfig.trail.link3.href@ ) ); }
+var DISPLAY_SEPARATOR=" > ";
+var DISPLAY_PREPREND=" > ";
+var DISPLAY_POSTPREND=":";
+var CSS_CLASS_CRUMB="breadcrumb";
+var CSS_CLASS_TRAIL="breadcrumbTrail";
+var CSS_CLASS_SEPARATOR="crumbSeparator";
+var FILE_EXTENSIONS=new Array( ".html", ".htm", ".jsp", ".php", ".php3", ".php4" );
+var PATH_SEPARATOR="/";
+
+function sc(s) {
+ var l=s.toLowerCase();
+ return l.substr(0,1).toUpperCase()+l.substr(1);
+}
+function getdirs() {
+ var t=document.location.pathname.split(PATH_SEPARATOR);
+ var lc=t[t.length-1];
+ for(var i=0;i < FILE_EXTENSIONS.length;i++)
+ {
+ if(lc.indexOf(FILE_EXTENSIONS[i]))
+ return t.slice(1,t.length-1); }
+ return t.slice(1,t.length);
+}
+function getcrumbs( d )
+{
+ var pre = "/";
+ var post = "/";
+ var c = new Array();
+ if( d != null )
+ {
+ for(var i=0;i < d.length;i++) {
+ pre+=d[i]+postfix;
+ c.push(new Array(d[i],pre)); }
+ }
+ if(PREPREND_CRUMBS.length > 0 )
+ return PREPREND_CRUMBS.concat( c );
+ return c;
+}
+function gettrail( c )
+{
+ var h=DISPLAY_PREPREND;
+ for(var i=0;i < c.length;i++)
+ {
+ h+='<a href="'+c[i][1]+'" >'+sc(c[i][0])+'</a>';
+ if(i!=(c.length-1))
+ h+=DISPLAY_SEPARATOR; }
+ return h+DISPLAY_POSTPREND;
+}
+
+function gettrailXHTML( c )
+{
+ var h='<span class="'+CSS_CLASS_TRAIL+'">'+DISPLAY_PREPREND;
+ for(var i=0;i < c.length;i++)
+ {
+ h+='<a href="'+c[i][1]+'" class="'+CSS_CLASS_CRUMB+'">'+sc(c[i][0])+'</a>';
+ if(i!=(c.length-1))
+ h+='<span class="'+CSS_CLASS_SEPARATOR+'">'+DISPLAY_SEPARATOR+'</span>'; }
+ return h+DISPLAY_POSTPREND+'</span>';
+}
+
+if(document.location.href.toLowerCase().indexOf("http://")==-1)
+ document.write(gettrail(getcrumbs()));
+else
+ document.write(gettrail(getcrumbs(getdirs())));
+
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs.js
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs.js (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/breadcrumbs.js Wed Mar 21 06:15:08 2012
@@ -0,0 +1,237 @@
+/*
+* 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.
+*/
+/**
+ * This script, when included in a html file, builds a neat breadcrumb trail
+ * based on its url. That is, if it doesn't contains bugs (I'm relatively
+ * sure it does).
+ *
+ * Typical usage:
+ * <script type="text/javascript" language="JavaScript" src="breadcrumbs.js"></script>
+ */
+
+/**
+ * IE 5 on Mac doesn't know Array.push.
+ *
+ * Implement it - courtesy to fritz.
+ */
+var abc = new Array();
+if (!abc.push) {
+ Array.prototype.push = function(what){this[this.length]=what}
+}
+
+/* ========================================================================
+ CONSTANTS
+ ======================================================================== */
+
+/**
+ * Two-dimensional array containing extra crumbs to place at the front of
+ * the trail. Specify first the name of the crumb, then the URI that belongs
+ * to it. You'll need to modify this for every domain or subdomain where
+ * you use this script (you can leave it as an empty array if you wish)
+ */
+var PREPREND_CRUMBS = new Array();
+
+var link1 = "@skinconfig.trail.link1.name@";
+var link2 = "@skinconfig.trail.link2.name@";
+var link3 = "@skinconfig.trail.link3.name@";
+
+var href1 = "@skinconfig.trail.link1.href@";
+var href2 = "@skinconfig.trail.link2.href@";
+var href3 = "@skinconfig.trail.link3.href@";
+
+ if(!(link1=="")&&!link1.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link1, href1 ) );
+ }
+ if(!(link2=="")&&!link2.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link2, href2 ) );
+ }
+ if(!(link3=="")&&!link3.indexOf( "@" ) == 0){
+ PREPREND_CRUMBS.push( new Array( link3, href3 ) );
+ }
+
+/**
+ * String to include between crumbs:
+ */
+var DISPLAY_SEPARATOR = " > ";
+/**
+ * String to include at the beginning of the trail
+ */
+var DISPLAY_PREPREND = " > ";
+/**
+ * String to include at the end of the trail
+ */
+var DISPLAY_POSTPREND = "";
+
+/**
+ * CSS Class to use for a single crumb:
+ */
+var CSS_CLASS_CRUMB = "breadcrumb";
+
+/**
+ * CSS Class to use for the complete trail:
+ */
+var CSS_CLASS_TRAIL = "breadcrumbTrail";
+
+/**
+ * CSS Class to use for crumb separator:
+ */
+var CSS_CLASS_SEPARATOR = "crumbSeparator";
+
+/**
+ * Array of strings containing common file extensions. We use this to
+ * determine what part of the url to ignore (if it contains one of the
+ * string specified here, we ignore it).
+ */
+var FILE_EXTENSIONS = new Array( ".html", ".htm", ".jsp", ".php", ".php3", ".php4" );
+
+/**
+ * String that separates parts of the breadcrumb trail from each other.
+ * When this is no longer a slash, I'm sure I'll be old and grey.
+ */
+var PATH_SEPARATOR = "/";
+
+/* ========================================================================
+ UTILITY FUNCTIONS
+ ======================================================================== */
+/**
+ * Capitalize first letter of the provided string and return the modified
+ * string.
+ */
+function sentenceCase( string )
+{ return string;
+ //var lower = string.toLowerCase();
+ //return lower.substr(0,1).toUpperCase() + lower.substr(1);
+}
+
+/**
+ * Returns an array containing the names of all the directories in the
+ * current document URL
+ */
+function getDirectoriesInURL()
+{
+ var trail = document.location.pathname.split( PATH_SEPARATOR );
+
+ // check whether last section is a file or a directory
+ var lastcrumb = trail[trail.length-1];
+ for( var i = 0; i < FILE_EXTENSIONS.length; i++ )
+ {
+ if( lastcrumb.indexOf( FILE_EXTENSIONS[i] ) )
+ {
+ // it is, remove it and send results
+ return trail.slice( 1, trail.length-1 );
+ }
+ }
+
+ // it's not; send the trail unmodified
+ return trail.slice( 1, trail.length );
+}
+
+/* ========================================================================
+ BREADCRUMB FUNCTIONALITY
+ ======================================================================== */
+/**
+ * Return a two-dimensional array describing the breadcrumbs based on the
+ * array of directories passed in.
+ */
+function getBreadcrumbs( dirs )
+{
+ var prefix = "/";
+ var postfix = "/";
+
+ // the array we will return
+ var crumbs = new Array();
+
+ if( dirs != null )
+ {
+ for( var i = 0; i < dirs.length; i++ )
+ {
+ prefix += dirs[i] + postfix;
+ crumbs.push( new Array( dirs[i], prefix ) );
+ }
+ }
+
+ // preprend the PREPREND_CRUMBS
+ if(PREPREND_CRUMBS.length > 0 )
+ {
+ return PREPREND_CRUMBS.concat( crumbs );
+ }
+
+ return crumbs;
+}
+
+/**
+ * Return a string containing a simple text breadcrumb trail based on the
+ * two-dimensional array passed in.
+ */
+function getCrumbTrail( crumbs )
+{
+ var xhtml = DISPLAY_PREPREND;
+
+ for( var i = 0; i < crumbs.length; i++ )
+ {
+ xhtml += '<a href="' + crumbs[i][1] + '" >';
+ xhtml += unescape( crumbs[i][0] ) + '</a>';
+ if( i != (crumbs.length-1) )
+ {
+ xhtml += DISPLAY_SEPARATOR;
+ }
+ }
+
+ xhtml += DISPLAY_POSTPREND;
+
+ return xhtml;
+}
+
+/**
+ * Return a string containing an XHTML breadcrumb trail based on the
+ * two-dimensional array passed in.
+ */
+function getCrumbTrailXHTML( crumbs )
+{
+ var xhtml = '<span class="' + CSS_CLASS_TRAIL + '">';
+ xhtml += DISPLAY_PREPREND;
+
+ for( var i = 0; i < crumbs.length; i++ )
+ {
+ xhtml += '<a href="' + crumbs[i][1] + '" class="' + CSS_CLASS_CRUMB + '">';
+ xhtml += unescape( crumbs[i][0] ) + '</a>';
+ if( i != (crumbs.length-1) )
+ {
+ xhtml += '<span class="' + CSS_CLASS_SEPARATOR + '">' + DISPLAY_SEPARATOR + '</span>';
+ }
+ }
+
+ xhtml += DISPLAY_POSTPREND;
+ xhtml += '</span>';
+
+ return xhtml;
+}
+
+/* ========================================================================
+ PRINT BREADCRUMB TRAIL
+ ======================================================================== */
+
+// check if we're local; if so, only print the PREPREND_CRUMBS
+if( document.location.href.toLowerCase().indexOf( "http://" ) == -1 )
+{
+ document.write( getCrumbTrail( getBreadcrumbs() ) );
+}
+else
+{
+ document.write( getCrumbTrail( getBreadcrumbs( getDirectoriesInURL() ) ) );
+}
+
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/fontsize.js
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/fontsize.js (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/fontsize.js Wed Mar 21 06:15:08 2012
@@ -0,0 +1,166 @@
+/*
+* 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.
+*/
+function init()
+{ //embedded in the doc
+ //ndeSetTextSize();
+}
+
+function checkBrowser(){
+ if (!document.getElementsByTagName){
+ return true;
+ }
+ else{
+ return false;
+ }
+}
+
+
+function ndeSetTextSize(chgsize,rs)
+{
+ var startSize;
+ var newSize;
+
+ if (!checkBrowser)
+ {
+ return;
+ }
+
+ startSize = parseInt(ndeGetDocTextSize());
+
+ if (!startSize)
+ {
+ startSize = 16;
+ }
+
+ switch (chgsize)
+ {
+ case 'incr':
+ newSize = startSize + 2;
+ break;
+
+ case 'decr':
+ newSize = startSize - 2;
+ break;
+
+ case 'reset':
+ if (rs) {newSize = rs;} else {newSize = 16;}
+ break;
+
+ default:
+ try{
+ newSize = parseInt(ndeReadCookie("nde-textsize"));
+ }
+ catch(e){
+ alert(e);
+ }
+
+ if (!newSize || newSize == 'NaN')
+ {
+ newSize = startSize;
+ }
+ break;
+
+ }
+
+ if (newSize < 10)
+ {
+ newSize = 10;
+ }
+
+ newSize += 'px';
+
+ document.getElementsByTagName('html')[0].style.fontSize = newSize;
+ document.getElementsByTagName('body')[0].style.fontSize = newSize;
+
+ ndeCreateCookie("nde-textsize", newSize, 365);
+}
+
+function ndeGetDocTextSize()
+{
+ if (!checkBrowser)
+ {
+ return 0;
+ }
+
+ var size = 0;
+ var body = document.getElementsByTagName('body')[0];
+
+ if (body.style && body.style.fontSize)
+ {
+ size = body.style.fontSize;
+ }
+ else if (typeof(getComputedStyle) != 'undefined')
+ {
+ size = getComputedStyle(body,'').getPropertyValue('font-size');
+ }
+ else if (body.currentStyle)
+ {
+ size = body.currentStyle.fontSize;
+ }
+
+ //fix IE bug
+ if( isNaN(size)){
+ if(size.substring(size.length-1)=="%"){
+ return
+ }
+
+ }
+
+ return size;
+
+}
+
+
+
+function ndeCreateCookie(name,value,days)
+{
+ var cookie = name + "=" + value + ";";
+
+ if (days)
+ {
+ var date = new Date();
+ date.setTime(date.getTime()+(days*24*60*60*1000));
+ cookie += " expires=" + date.toGMTString() + ";";
+ }
+ cookie += " path=/";
+
+ document.cookie = cookie;
+
+}
+
+function ndeReadCookie(name)
+{
+ var nameEQ = name + "=";
+ var ca = document.cookie.split(';');
+
+
+ for(var i = 0; i < ca.length; i++)
+ {
+ var c = ca[i];
+ while (c.charAt(0) == ' ')
+ {
+ c = c.substring(1, c.length);
+ }
+
+ ctest = c.substring(0,name.length);
+
+ if(ctest == name){
+ return c.substring(nameEQ.length,c.length);
+ }
+ }
+ return null;
+}
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getBlank.js
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getBlank.js (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getBlank.js Wed Mar 21 06:15:08 2012
@@ -0,0 +1,40 @@
+/*
+* 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.
+*/
+/**
+ * getBlank script - when included in a html file and called from a form text field, will set the value of this field to ""
+ * if the text value is still the standard value.
+ * getPrompt script - when included in a html file and called from a form text field, will set the value of this field to the prompt
+ * if the text value is empty.
+ *
+ * Typical usage:
+ * <script type="text/javascript" language="JavaScript" src="getBlank.js"></script>
+ * <input type="text" id="query" value="Search the site:" onFocus="getBlank (this, 'Search the site:');" onBlur="getBlank (this, 'Search the site:');"/>
+ */
+<!--
+function getBlank (form, stdValue){
+if (form.value == stdValue){
+ form.value = '';
+ }
+return true;
+}
+function getPrompt (form, stdValue){
+if (form.value == ''){
+ form.value = stdValue;
+ }
+return true;
+}
+//-->
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getMenu.js
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getMenu.js (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/getMenu.js Wed Mar 21 06:15:08 2012
@@ -0,0 +1,45 @@
+/*
+* 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.
+*/
+/**
+ * This script, when included in a html file, can be used to make collapsible menus
+ *
+ * Typical usage:
+ * <script type="text/javascript" language="JavaScript" src="menu.js"></script>
+ */
+
+if (document.getElementById){
+ document.write('<style type="text/css">.menuitemgroup{display: none;}</style>')
+}
+
+
+function SwitchMenu(obj, thePath)
+{
+var open = 'url("'+thePath + 'images/chapter_open.gif")';
+var close = 'url("'+thePath + 'images/chapter.gif")';
+ if(document.getElementById) {
+ var el = document.getElementById(obj);
+ var title = document.getElementById(obj+'Title');
+
+ if(el.style.display != "block"){
+ title.style.backgroundImage = open;
+ el.style.display = "block";
+ }else{
+ title.style.backgroundImage = close;
+ el.style.display = "none";
+ }
+ }// end - if(document.getElementById)
+}//end - function SwitchMenu(obj)
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/README.txt
==============================================================================
--- websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/README.txt (added)
+++ websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/README.txt Wed Mar 21 06:15:08 2012
@@ -0,0 +1 @@
+The images in this directory are used if the current skin lacks them.
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/add.jpg
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/add.jpg
------------------------------------------------------------------------------
svn:mime-type = image/jpeg
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/apache-thanks.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/apache-thanks.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/built-with-cocoon.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/built-with-cocoon.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/built-with-forrest-button.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/built-with-forrest-button.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/chapter.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/chapter.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/chapter_open.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/chapter_open.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/current.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/current.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/error.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/error.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/external-link.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/external-link.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/fix.jpg
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/fix.jpg
------------------------------------------------------------------------------
svn:mime-type = image/jpeg
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/forrest-credit-logo.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/forrest-credit-logo.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/hack.jpg
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/hack.jpg
------------------------------------------------------------------------------
svn:mime-type = image/jpeg
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/header_white_line.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/header_white_line.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/info.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/info.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/instruction_arrow.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/instruction_arrow.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/label.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/label.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/page.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/page.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/pdfdoc.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/pdfdoc.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/poddoc.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/poddoc.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/printer.gif
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/printer.gif
------------------------------------------------------------------------------
svn:mime-type = image/gif
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/rc-b-l-15-1body-2menu-3menu.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/rc-b-l-15-1body-2menu-3menu.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/rc-b-r-15-1body-2menu-3menu.png
==============================================================================
Binary file - no diff available.
Propchange: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/rc-b-r-15-1body-2menu-3menu.png
------------------------------------------------------------------------------
svn:mime-type = image/png
Added: websites/staging/zookeeper/trunk/content/doc/r3.3.5/skin/images/rc-b-r-5-1header-2tab-selected-3tab-selected.png
==============================================================================
Binary file - no diff available.