helix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1442295 [29/38] - in /incubator/helix/site-content: ./ apidocs/assets/ apidocs/reference/ apidocs/reference/org/apache/helix/ apidocs/reference/org/apache/helix/manager/zk/ helix-admin-webapp/ helix-core/ involved/ mockservice/ recipes/ re...
Date Mon, 04 Feb 2013 18:40:12 GMT
Modified: incubator/helix/site-content/xref-test/org/apache/helix/store/zk/TestZkHelixPropertyStore.html
URL: http://svn.apache.org/viewvc/incubator/helix/site-content/xref-test/org/apache/helix/store/zk/TestZkHelixPropertyStore.html?rev=1442295&r1=1442294&r2=1442295&view=diff
==============================================================================
--- incubator/helix/site-content/xref-test/org/apache/helix/store/zk/TestZkHelixPropertyStore.html (original)
+++ incubator/helix/site-content/xref-test/org/apache/helix/store/zk/TestZkHelixPropertyStore.html Mon Feb  4 18:40:07 2013
@@ -59,7 +59,7 @@
 <a class="jxr_linenumber" name="49" href="#49">49</a>  
 <a class="jxr_linenumber" name="50" href="#50">50</a>    <em class="jxr_comment">// final int totalNodes = firstLevelNr * secondLevelNr;</em>
 <a class="jxr_linenumber" name="51" href="#51">51</a>  
-<a class="jxr_linenumber" name="52" href="#52">52</a>    <strong class="jxr_keyword">class</strong> <a href="../../../../../org/apache/helix/manager/zk/TestZkCacheSyncOpSingleThread.html">TestListener</a> <strong class="jxr_keyword">implements</strong> HelixPropertyListener
+<a class="jxr_linenumber" name="52" href="#52">52</a>    <strong class="jxr_keyword">class</strong> <a href="../../../../../org/apache/helix/TestListenerCallback.html">TestListener</a> <strong class="jxr_keyword">implements</strong> HelixPropertyListener
 <a class="jxr_linenumber" name="53" href="#53">53</a>    {
 <a class="jxr_linenumber" name="54" href="#54">54</a>      Map&lt;String, Long&gt; _changeKeys = <strong class="jxr_keyword">new</strong> HashMap&lt;String, Long&gt;();
 <a class="jxr_linenumber" name="55" href="#55">55</a>      Map&lt;String, Long&gt; _createKeys = <strong class="jxr_keyword">new</strong> HashMap&lt;String, Long&gt;();
@@ -126,276 +126,285 @@
 <a class="jxr_linenumber" name="116" href="#116">116</a>     }
 <a class="jxr_linenumber" name="117" href="#117">117</a>     <strong class="jxr_keyword">long</strong> endT = System.currentTimeMillis();
 <a class="jxr_linenumber" name="118" href="#118">118</a>     System.out.println(<span class="jxr_string">"1000 Get() time used: "</span> + (endT - startT) + <span class="jxr_string">"ms"</span>);
-<a class="jxr_linenumber" name="119" href="#119">119</a>     Assert.assertTrue((endT - startT) &lt; 60, <span class="jxr_string">"1000 Gets should be finished within 50ms"</span>);
-<a class="jxr_linenumber" name="120" href="#120">120</a> 
-<a class="jxr_linenumber" name="121" href="#121">121</a>     store.stop();
-<a class="jxr_linenumber" name="122" href="#122">122</a>     System.out.println(<span class="jxr_string">"END testSet() at "</span> + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="123" href="#123">123</a>   }
-<a class="jxr_linenumber" name="124" href="#124">124</a> 
-<a class="jxr_linenumber" name="125" href="#125">125</a>   @Test
-<a class="jxr_linenumber" name="126" href="#126">126</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLocalTriggeredCallback() <strong class="jxr_keyword">throws</strong> Exception
-<a class="jxr_linenumber" name="127" href="#127">127</a>   {
-<a class="jxr_linenumber" name="128" href="#128">128</a>     System.out.println(<span class="jxr_string">"START testLocalTriggeredCallback() at "</span>
-<a class="jxr_linenumber" name="129" href="#129">129</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="130" href="#130">130</a> 
-<a class="jxr_linenumber" name="131" href="#131">131</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"localCallback"</span>;
-<a class="jxr_linenumber" name="132" href="#132">132</a>     List&lt;String&gt; subscribedPaths = <strong class="jxr_keyword">new</strong> ArrayList&lt;String&gt;();
-<a class="jxr_linenumber" name="133" href="#133">133</a>     subscribedPaths.add(subRoot);
-<a class="jxr_linenumber" name="134" href="#134">134</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
-<a class="jxr_linenumber" name="135" href="#135">135</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
-<a class="jxr_linenumber" name="136" href="#136">136</a>                                            subRoot,
-<a class="jxr_linenumber" name="137" href="#137">137</a>                                            subscribedPaths);
-<a class="jxr_linenumber" name="138" href="#138">138</a> 
-<a class="jxr_linenumber" name="139" href="#139">139</a>     <em class="jxr_comment">// change nodes via property store interface</em>
-<a class="jxr_linenumber" name="140" href="#140">140</a>     <em class="jxr_comment">// and verify all notifications have been received</em>
-<a class="jxr_linenumber" name="141" href="#141">141</a>     <a href="../../../../../org/apache/helix/manager/zk/TestZkCacheSyncOpSingleThread.html">TestListener</a> listener = <strong class="jxr_keyword">new</strong> <a href="../../../../../org/apache/helix/manager/zk/TestZkCacheSyncOpSingleThread.html">TestListener</a>();
-<a class="jxr_linenumber" name="142" href="#142">142</a>     store.subscribe(<span class="jxr_string">"/"</span>, listener);
-<a class="jxr_linenumber" name="143" href="#143">143</a> 
-<a class="jxr_linenumber" name="144" href="#144">144</a>     <em class="jxr_comment">// test dataCreate callbacks</em>
-<a class="jxr_linenumber" name="145" href="#145">145</a>     listener.reset();
-<a class="jxr_linenumber" name="146" href="#146">146</a>     setNodes(store, 'a', <strong class="jxr_keyword">true</strong>);
-<a class="jxr_linenumber" name="147" href="#147">147</a> 
-<a class="jxr_linenumber" name="148" href="#148">148</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
-<a class="jxr_linenumber" name="149" href="#149">149</a>     Thread.sleep(500);
-<a class="jxr_linenumber" name="150" href="#150">150</a>     <strong class="jxr_keyword">int</strong> expectCreateNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="151" href="#151">151</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="152" href="#152">152</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="153" href="#153">153</a>     Assert.assertTrue(listener._createKeys.size() == expectCreateNodes, <span class="jxr_string">"Should receive "</span>
-<a class="jxr_linenumber" name="154" href="#154">154</a>         + expectCreateNodes + <span class="jxr_string">" create callbacks"</span>);
-<a class="jxr_linenumber" name="155" href="#155">155</a> 
-<a class="jxr_linenumber" name="156" href="#156">156</a>     <em class="jxr_comment">// test dataChange callbacks</em>
-<a class="jxr_linenumber" name="157" href="#157">157</a>     listener.reset();
-<a class="jxr_linenumber" name="158" href="#158">158</a>     setNodes(store, 'b', <strong class="jxr_keyword">true</strong>);
-<a class="jxr_linenumber" name="159" href="#159">159</a> 
-<a class="jxr_linenumber" name="160" href="#160">160</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
-<a class="jxr_linenumber" name="161" href="#161">161</a>     Thread.sleep(500);
-<a class="jxr_linenumber" name="162" href="#162">162</a>     <strong class="jxr_keyword">int</strong> expectChangeNodes = firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="163" href="#163">163</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="164" href="#164">164</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="165" href="#165">165</a>     Assert.assertTrue(listener._changeKeys.size() &gt;= expectChangeNodes,
-<a class="jxr_linenumber" name="166" href="#166">166</a>                       <span class="jxr_string">"Should receive at least "</span> + expectChangeNodes
-<a class="jxr_linenumber" name="167" href="#167">167</a>                           + <span class="jxr_string">" change callbacks"</span>);
-<a class="jxr_linenumber" name="168" href="#168">168</a> 
-<a class="jxr_linenumber" name="169" href="#169">169</a>     <em class="jxr_comment">// test delete callbacks</em>
-<a class="jxr_linenumber" name="170" href="#170">170</a>     listener.reset();
-<a class="jxr_linenumber" name="171" href="#171">171</a>     <strong class="jxr_keyword">int</strong> expectDeleteNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="172" href="#172">172</a>     store.remove(<span class="jxr_string">"/"</span>, 0);
-<a class="jxr_linenumber" name="173" href="#173">173</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
-<a class="jxr_linenumber" name="174" href="#174">174</a>     Thread.sleep(500);
-<a class="jxr_linenumber" name="175" href="#175">175</a> 
-<a class="jxr_linenumber" name="176" href="#176">176</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="177" href="#177">177</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="178" href="#178">178</a>     Assert.assertTrue(listener._deleteKeys.size() == expectDeleteNodes, <span class="jxr_string">"Should receive "</span>
-<a class="jxr_linenumber" name="179" href="#179">179</a>         + expectDeleteNodes + <span class="jxr_string">" delete callbacks"</span>);
+<a class="jxr_linenumber" name="119" href="#119">119</a>     <strong class="jxr_keyword">long</strong> latency = endT - startT;
+<a class="jxr_linenumber" name="120" href="#120">120</a>     Assert.assertTrue(latency &lt; 100, <span class="jxr_string">"1000 Gets should be finished within 100ms, but was "</span> + latency + <span class="jxr_string">" ms"</span>);
+<a class="jxr_linenumber" name="121" href="#121">121</a> 
+<a class="jxr_linenumber" name="122" href="#122">122</a>     store.stop();
+<a class="jxr_linenumber" name="123" href="#123">123</a>     System.out.println(<span class="jxr_string">"END testSet() at "</span> + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="124" href="#124">124</a>   }
+<a class="jxr_linenumber" name="125" href="#125">125</a> 
+<a class="jxr_linenumber" name="126" href="#126">126</a>   @Test
+<a class="jxr_linenumber" name="127" href="#127">127</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLocalTriggeredCallback() <strong class="jxr_keyword">throws</strong> Exception
+<a class="jxr_linenumber" name="128" href="#128">128</a>   {
+<a class="jxr_linenumber" name="129" href="#129">129</a>     System.out.println(<span class="jxr_string">"START testLocalTriggeredCallback() at "</span>
+<a class="jxr_linenumber" name="130" href="#130">130</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="131" href="#131">131</a> 
+<a class="jxr_linenumber" name="132" href="#132">132</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"localCallback"</span>;
+<a class="jxr_linenumber" name="133" href="#133">133</a>     List&lt;String&gt; subscribedPaths = <strong class="jxr_keyword">new</strong> ArrayList&lt;String&gt;();
+<a class="jxr_linenumber" name="134" href="#134">134</a>     subscribedPaths.add(subRoot);
+<a class="jxr_linenumber" name="135" href="#135">135</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
+<a class="jxr_linenumber" name="136" href="#136">136</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
+<a class="jxr_linenumber" name="137" href="#137">137</a>                                            subRoot,
+<a class="jxr_linenumber" name="138" href="#138">138</a>                                            subscribedPaths);
+<a class="jxr_linenumber" name="139" href="#139">139</a> 
+<a class="jxr_linenumber" name="140" href="#140">140</a>     <em class="jxr_comment">// change nodes via property store interface</em>
+<a class="jxr_linenumber" name="141" href="#141">141</a>     <em class="jxr_comment">// and verify all notifications have been received</em>
+<a class="jxr_linenumber" name="142" href="#142">142</a>     <a href="../../../../../org/apache/helix/TestListenerCallback.html">TestListener</a> listener = <strong class="jxr_keyword">new</strong> <a href="../../../../../org/apache/helix/TestListenerCallback.html">TestListener</a>();
+<a class="jxr_linenumber" name="143" href="#143">143</a>     store.subscribe(<span class="jxr_string">"/"</span>, listener);
+<a class="jxr_linenumber" name="144" href="#144">144</a> 
+<a class="jxr_linenumber" name="145" href="#145">145</a>     <em class="jxr_comment">// test dataCreate callbacks</em>
+<a class="jxr_linenumber" name="146" href="#146">146</a>     listener.reset();
+<a class="jxr_linenumber" name="147" href="#147">147</a>     setNodes(store, 'a', <strong class="jxr_keyword">true</strong>);
+<a class="jxr_linenumber" name="148" href="#148">148</a> 
+<a class="jxr_linenumber" name="149" href="#149">149</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
+<a class="jxr_linenumber" name="150" href="#150">150</a>     Thread.sleep(500);
+<a class="jxr_linenumber" name="151" href="#151">151</a>     <strong class="jxr_keyword">int</strong> expectCreateNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="152" href="#152">152</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="153" href="#153">153</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="154" href="#154">154</a>     Assert.assertTrue(listener._createKeys.size() == expectCreateNodes, <span class="jxr_string">"Should receive "</span>
+<a class="jxr_linenumber" name="155" href="#155">155</a>         + expectCreateNodes + <span class="jxr_string">" create callbacks"</span>);
+<a class="jxr_linenumber" name="156" href="#156">156</a> 
+<a class="jxr_linenumber" name="157" href="#157">157</a>     <em class="jxr_comment">// test dataChange callbacks</em>
+<a class="jxr_linenumber" name="158" href="#158">158</a>     listener.reset();
+<a class="jxr_linenumber" name="159" href="#159">159</a>     setNodes(store, 'b', <strong class="jxr_keyword">true</strong>);
+<a class="jxr_linenumber" name="160" href="#160">160</a> 
+<a class="jxr_linenumber" name="161" href="#161">161</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
+<a class="jxr_linenumber" name="162" href="#162">162</a>     Thread.sleep(500);
+<a class="jxr_linenumber" name="163" href="#163">163</a>     <strong class="jxr_keyword">int</strong> expectChangeNodes = firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="164" href="#164">164</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="165" href="#165">165</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="166" href="#166">166</a>     Assert.assertTrue(listener._changeKeys.size() &gt;= expectChangeNodes,
+<a class="jxr_linenumber" name="167" href="#167">167</a>                       <span class="jxr_string">"Should receive at least "</span> + expectChangeNodes
+<a class="jxr_linenumber" name="168" href="#168">168</a>                           + <span class="jxr_string">" change callbacks"</span>);
+<a class="jxr_linenumber" name="169" href="#169">169</a> 
+<a class="jxr_linenumber" name="170" href="#170">170</a>     <em class="jxr_comment">// test delete callbacks</em>
+<a class="jxr_linenumber" name="171" href="#171">171</a>     listener.reset();
+<a class="jxr_linenumber" name="172" href="#172">172</a>     <strong class="jxr_keyword">int</strong> expectDeleteNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="173" href="#173">173</a>     store.remove(<span class="jxr_string">"/"</span>, 0);
+<a class="jxr_linenumber" name="174" href="#174">174</a>     <em class="jxr_comment">// wait until all callbacks have been received</em>
+<a class="jxr_linenumber" name="175" href="#175">175</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; 10; i++) {
+<a class="jxr_linenumber" name="176" href="#176">176</a>     	<strong class="jxr_keyword">if</strong> (listener._deleteKeys.size() == expectDeleteNodes)
+<a class="jxr_linenumber" name="177" href="#177">177</a>     		<strong class="jxr_keyword">break</strong>;
+<a class="jxr_linenumber" name="178" href="#178">178</a>     	Thread.sleep(500);
+<a class="jxr_linenumber" name="179" href="#179">179</a>     }
 <a class="jxr_linenumber" name="180" href="#180">180</a> 
-<a class="jxr_linenumber" name="181" href="#181">181</a>     store.stop();
-<a class="jxr_linenumber" name="182" href="#182">182</a>     System.out.println(<span class="jxr_string">"END testLocalTriggeredCallback() at "</span>
-<a class="jxr_linenumber" name="183" href="#183">183</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="184" href="#184">184</a>   }
+<a class="jxr_linenumber" name="181" href="#181">181</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="182" href="#182">182</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="183" href="#183">183</a>     Assert.assertTrue(listener._deleteKeys.size() == expectDeleteNodes, <span class="jxr_string">"Should receive "</span>
+<a class="jxr_linenumber" name="184" href="#184">184</a>         + expectDeleteNodes + <span class="jxr_string">" delete callbacks"</span>);
 <a class="jxr_linenumber" name="185" href="#185">185</a> 
-<a class="jxr_linenumber" name="186" href="#186">186</a>   @Test
-<a class="jxr_linenumber" name="187" href="#187">187</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testZkTriggeredCallback() <strong class="jxr_keyword">throws</strong> Exception
-<a class="jxr_linenumber" name="188" href="#188">188</a>   {
-<a class="jxr_linenumber" name="189" href="#189">189</a>     System.out.println(<span class="jxr_string">"START testZkTriggeredCallback() at "</span>
-<a class="jxr_linenumber" name="190" href="#190">190</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="191" href="#191">191</a> 
-<a class="jxr_linenumber" name="192" href="#192">192</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"zkCallback"</span>;
-<a class="jxr_linenumber" name="193" href="#193">193</a>     List&lt;String&gt; subscribedPaths = Arrays.asList(subRoot);
-<a class="jxr_linenumber" name="194" href="#194">194</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
-<a class="jxr_linenumber" name="195" href="#195">195</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
-<a class="jxr_linenumber" name="196" href="#196">196</a>                                            subRoot,
-<a class="jxr_linenumber" name="197" href="#197">197</a>                                            subscribedPaths);
-<a class="jxr_linenumber" name="198" href="#198">198</a> 
-<a class="jxr_linenumber" name="199" href="#199">199</a>     <em class="jxr_comment">// change nodes via property store interface</em>
-<a class="jxr_linenumber" name="200" href="#200">200</a>     <em class="jxr_comment">// and verify all notifications have been received</em>
-<a class="jxr_linenumber" name="201" href="#201">201</a>     <a href="../../../../../org/apache/helix/manager/zk/TestZkCacheSyncOpSingleThread.html">TestListener</a> listener = <strong class="jxr_keyword">new</strong> <a href="../../../../../org/apache/helix/manager/zk/TestZkCacheSyncOpSingleThread.html">TestListener</a>();
-<a class="jxr_linenumber" name="202" href="#202">202</a>     store.subscribe(<span class="jxr_string">"/"</span>, listener);
+<a class="jxr_linenumber" name="186" href="#186">186</a>     store.stop();
+<a class="jxr_linenumber" name="187" href="#187">187</a>     System.out.println(<span class="jxr_string">"END testLocalTriggeredCallback() at "</span>
+<a class="jxr_linenumber" name="188" href="#188">188</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="189" href="#189">189</a>   }
+<a class="jxr_linenumber" name="190" href="#190">190</a> 
+<a class="jxr_linenumber" name="191" href="#191">191</a>   @Test
+<a class="jxr_linenumber" name="192" href="#192">192</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testZkTriggeredCallback() <strong class="jxr_keyword">throws</strong> Exception
+<a class="jxr_linenumber" name="193" href="#193">193</a>   {
+<a class="jxr_linenumber" name="194" href="#194">194</a>     System.out.println(<span class="jxr_string">"START testZkTriggeredCallback() at "</span>
+<a class="jxr_linenumber" name="195" href="#195">195</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="196" href="#196">196</a> 
+<a class="jxr_linenumber" name="197" href="#197">197</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"zkCallback"</span>;
+<a class="jxr_linenumber" name="198" href="#198">198</a>     List&lt;String&gt; subscribedPaths = Arrays.asList(subRoot);
+<a class="jxr_linenumber" name="199" href="#199">199</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
+<a class="jxr_linenumber" name="200" href="#200">200</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
+<a class="jxr_linenumber" name="201" href="#201">201</a>                                            subRoot,
+<a class="jxr_linenumber" name="202" href="#202">202</a>                                            subscribedPaths);
 <a class="jxr_linenumber" name="203" href="#203">203</a> 
-<a class="jxr_linenumber" name="204" href="#204">204</a>     <em class="jxr_comment">// test create callbacks</em>
-<a class="jxr_linenumber" name="205" href="#205">205</a>     listener.reset();
-<a class="jxr_linenumber" name="206" href="#206">206</a>     setNodes(_gZkClient, subRoot, 'a', <strong class="jxr_keyword">true</strong>);
-<a class="jxr_linenumber" name="207" href="#207">207</a>     <strong class="jxr_keyword">int</strong> expectCreateNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="208" href="#208">208</a>     Thread.sleep(500);
-<a class="jxr_linenumber" name="209" href="#209">209</a> 
-<a class="jxr_linenumber" name="210" href="#210">210</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="211" href="#211">211</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="212" href="#212">212</a>     Assert.assertTrue(listener._createKeys.size() == expectCreateNodes, <span class="jxr_string">"Should receive "</span>
-<a class="jxr_linenumber" name="213" href="#213">213</a>         + expectCreateNodes + <span class="jxr_string">" create callbacks"</span>);
+<a class="jxr_linenumber" name="204" href="#204">204</a>     <em class="jxr_comment">// change nodes via property store interface</em>
+<a class="jxr_linenumber" name="205" href="#205">205</a>     <em class="jxr_comment">// and verify all notifications have been received</em>
+<a class="jxr_linenumber" name="206" href="#206">206</a>     <a href="../../../../../org/apache/helix/TestListenerCallback.html">TestListener</a> listener = <strong class="jxr_keyword">new</strong> <a href="../../../../../org/apache/helix/TestListenerCallback.html">TestListener</a>();
+<a class="jxr_linenumber" name="207" href="#207">207</a>     store.subscribe(<span class="jxr_string">"/"</span>, listener);
+<a class="jxr_linenumber" name="208" href="#208">208</a> 
+<a class="jxr_linenumber" name="209" href="#209">209</a>     <em class="jxr_comment">// test create callbacks</em>
+<a class="jxr_linenumber" name="210" href="#210">210</a>     listener.reset();
+<a class="jxr_linenumber" name="211" href="#211">211</a>     setNodes(_gZkClient, subRoot, 'a', <strong class="jxr_keyword">true</strong>);
+<a class="jxr_linenumber" name="212" href="#212">212</a>     <strong class="jxr_keyword">int</strong> expectCreateNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="213" href="#213">213</a>     Thread.sleep(500);
 <a class="jxr_linenumber" name="214" href="#214">214</a> 
-<a class="jxr_linenumber" name="215" href="#215">215</a>     <em class="jxr_comment">// test change callbacks</em>
-<a class="jxr_linenumber" name="216" href="#216">216</a>     listener.reset();
-<a class="jxr_linenumber" name="217" href="#217">217</a>     setNodes(_gZkClient, subRoot, 'b', <strong class="jxr_keyword">true</strong>);
-<a class="jxr_linenumber" name="218" href="#218">218</a>     <strong class="jxr_keyword">int</strong> expectChangeNodes = firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="219" href="#219">219</a>     Thread.sleep(500);
-<a class="jxr_linenumber" name="220" href="#220">220</a> 
-<a class="jxr_linenumber" name="221" href="#221">221</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="222" href="#222">222</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="223" href="#223">223</a>     Assert.assertTrue(listener._changeKeys.size() &gt;= expectChangeNodes,
-<a class="jxr_linenumber" name="224" href="#224">224</a>                       <span class="jxr_string">"Should receive at least "</span> + expectChangeNodes
-<a class="jxr_linenumber" name="225" href="#225">225</a>                           + <span class="jxr_string">" change callbacks"</span>);
-<a class="jxr_linenumber" name="226" href="#226">226</a> 
-<a class="jxr_linenumber" name="227" href="#227">227</a>     <em class="jxr_comment">// test delete callbacks</em>
-<a class="jxr_linenumber" name="228" href="#228">228</a>     listener.reset();
-<a class="jxr_linenumber" name="229" href="#229">229</a>     <strong class="jxr_keyword">int</strong> expectDeleteNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
-<a class="jxr_linenumber" name="230" href="#230">230</a>     _gZkClient.deleteRecursive(subRoot);
-<a class="jxr_linenumber" name="231" href="#231">231</a>     Thread.sleep(1000);
-<a class="jxr_linenumber" name="232" href="#232">232</a> 
-<a class="jxr_linenumber" name="233" href="#233">233</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
-<a class="jxr_linenumber" name="234" href="#234">234</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
-<a class="jxr_linenumber" name="235" href="#235">235</a>     Assert.assertTrue(listener._deleteKeys.size() == expectDeleteNodes, <span class="jxr_string">"Should receive "</span>
-<a class="jxr_linenumber" name="236" href="#236">236</a>         + expectDeleteNodes + <span class="jxr_string">" delete callbacks"</span>);
-<a class="jxr_linenumber" name="237" href="#237">237</a> 
-<a class="jxr_linenumber" name="238" href="#238">238</a>     store.stop();
-<a class="jxr_linenumber" name="239" href="#239">239</a>     System.out.println(<span class="jxr_string">"END testZkTriggeredCallback() at "</span>
-<a class="jxr_linenumber" name="240" href="#240">240</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="241" href="#241">241</a>   }
-<a class="jxr_linenumber" name="242" href="#242">242</a> 
-<a class="jxr_linenumber" name="243" href="#243">243</a>   @Test
-<a class="jxr_linenumber" name="244" href="#244">244</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testBackToBackRemoveAndSet() <strong class="jxr_keyword">throws</strong> Exception
-<a class="jxr_linenumber" name="245" href="#245">245</a>   {
-<a class="jxr_linenumber" name="246" href="#246">246</a>     System.out.println(<span class="jxr_string">"START testBackToBackRemoveAndSet() at "</span>
-<a class="jxr_linenumber" name="247" href="#247">247</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="248" href="#248">248</a> 
-<a class="jxr_linenumber" name="249" href="#249">249</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"backToBackRemoveAndSet"</span>;
-<a class="jxr_linenumber" name="250" href="#250">250</a>     List&lt;String&gt; subscribedPaths = <strong class="jxr_keyword">new</strong> ArrayList&lt;String&gt;();
-<a class="jxr_linenumber" name="251" href="#251">251</a>     subscribedPaths.add(subRoot);
-<a class="jxr_linenumber" name="252" href="#252">252</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
-<a class="jxr_linenumber" name="253" href="#253">253</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
-<a class="jxr_linenumber" name="254" href="#254">254</a>                                            subRoot,
-<a class="jxr_linenumber" name="255" href="#255">255</a>                                            subscribedPaths);
-<a class="jxr_linenumber" name="256" href="#256">256</a> 
-<a class="jxr_linenumber" name="257" href="#257">257</a>     store.set(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">new</strong> ZNRecord(<span class="jxr_string">"child0"</span>), AccessOption.PERSISTENT);
-<a class="jxr_linenumber" name="258" href="#258">258</a> 
-<a class="jxr_linenumber" name="259" href="#259">259</a>     ZNRecord record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, 0); <em class="jxr_comment">// will put the record in cache</em>
-<a class="jxr_linenumber" name="260" href="#260">260</a>     Assert.assertEquals(record.getId(), <span class="jxr_string">"child0"</span>);
-<a class="jxr_linenumber" name="261" href="#261">261</a>     <em class="jxr_comment">// System.out.println("1:get:" + record);</em>
-<a class="jxr_linenumber" name="262" href="#262">262</a> 
-<a class="jxr_linenumber" name="263" href="#263">263</a>     String child0Path = subRoot + <span class="jxr_string">"/child0"</span>;
-<a class="jxr_linenumber" name="264" href="#264">264</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; 2; i++)
-<a class="jxr_linenumber" name="265" href="#265">265</a>     {
-<a class="jxr_linenumber" name="266" href="#266">266</a>       _gZkClient.delete(child0Path);
-<a class="jxr_linenumber" name="267" href="#267">267</a>       _gZkClient.createPersistent(child0Path, <strong class="jxr_keyword">new</strong> ZNRecord(<span class="jxr_string">"child0-new-"</span> + i));
-<a class="jxr_linenumber" name="268" href="#268">268</a>     }
-<a class="jxr_linenumber" name="269" href="#269">269</a> 
-<a class="jxr_linenumber" name="270" href="#270">270</a>     Thread.sleep(500); <em class="jxr_comment">// should wait for zk callback to add "/child0" into cache</em>
-<a class="jxr_linenumber" name="271" href="#271">271</a>     record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, 0);
-<a class="jxr_linenumber" name="272" href="#272">272</a>     Assert.assertEquals(record.getId(),
-<a class="jxr_linenumber" name="273" href="#273">273</a>                         <span class="jxr_string">"child0-new-1"</span>,
-<a class="jxr_linenumber" name="274" href="#274">274</a>                         <span class="jxr_string">"Cache shoulde be updated to latest create"</span>);
-<a class="jxr_linenumber" name="275" href="#275">275</a>     <em class="jxr_comment">// System.out.println("2:get:" + record);</em>
-<a class="jxr_linenumber" name="276" href="#276">276</a> 
-<a class="jxr_linenumber" name="277" href="#277">277</a>     _gZkClient.delete(child0Path);
-<a class="jxr_linenumber" name="278" href="#278">278</a>     Thread.sleep(500); <em class="jxr_comment">// should wait for zk callback to remove "/child0" from cache</em>
-<a class="jxr_linenumber" name="279" href="#279">279</a>     <strong class="jxr_keyword">try</strong>
-<a class="jxr_linenumber" name="280" href="#280">280</a>     {
-<a class="jxr_linenumber" name="281" href="#281">281</a>       record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, AccessOption.THROW_EXCEPTION_IFNOTEXIST);
-<a class="jxr_linenumber" name="282" href="#282">282</a>       Assert.fail(<span class="jxr_string">"/child0 should have been removed"</span>);
-<a class="jxr_linenumber" name="283" href="#283">283</a>     }
-<a class="jxr_linenumber" name="284" href="#284">284</a>     <strong class="jxr_keyword">catch</strong> (ZkNoNodeException e)
-<a class="jxr_linenumber" name="285" href="#285">285</a>     {
-<a class="jxr_linenumber" name="286" href="#286">286</a>       <em class="jxr_comment">// OK.</em>
-<a class="jxr_linenumber" name="287" href="#287">287</a>     }
-<a class="jxr_linenumber" name="288" href="#288">288</a>     <em class="jxr_comment">// System.out.println("3:get:" + record);</em>
-<a class="jxr_linenumber" name="289" href="#289">289</a> 
-<a class="jxr_linenumber" name="290" href="#290">290</a>     store.stop();
-<a class="jxr_linenumber" name="291" href="#291">291</a>     System.out.println(<span class="jxr_string">"END testBackToBackRemoveAndSet() at "</span>
-<a class="jxr_linenumber" name="292" href="#292">292</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
-<a class="jxr_linenumber" name="293" href="#293">293</a>   }
-<a class="jxr_linenumber" name="294" href="#294">294</a> 
-<a class="jxr_linenumber" name="295" href="#295">295</a>   <strong class="jxr_keyword">private</strong> String getNodeId(<strong class="jxr_keyword">int</strong> i, <strong class="jxr_keyword">int</strong> j)
-<a class="jxr_linenumber" name="296" href="#296">296</a>   {
-<a class="jxr_linenumber" name="297" href="#297">297</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"childNode_"</span> + i + <span class="jxr_string">"_"</span> + j;
-<a class="jxr_linenumber" name="298" href="#298">298</a>   }
-<a class="jxr_linenumber" name="299" href="#299">299</a> 
-<a class="jxr_linenumber" name="300" href="#300">300</a>   <strong class="jxr_keyword">private</strong> String getSecondLevelKey(<strong class="jxr_keyword">int</strong> i, <strong class="jxr_keyword">int</strong> j)
-<a class="jxr_linenumber" name="301" href="#301">301</a>   {
-<a class="jxr_linenumber" name="302" href="#302">302</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"/node_"</span> + i + <span class="jxr_string">"/"</span> + getNodeId(i, j);
-<a class="jxr_linenumber" name="303" href="#303">303</a>   }
-<a class="jxr_linenumber" name="304" href="#304">304</a> 
-<a class="jxr_linenumber" name="305" href="#305">305</a>   <strong class="jxr_keyword">private</strong> String getFirstLevelKey(<strong class="jxr_keyword">int</strong> i)
-<a class="jxr_linenumber" name="306" href="#306">306</a>   {
-<a class="jxr_linenumber" name="307" href="#307">307</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"/node_"</span> + i;
-<a class="jxr_linenumber" name="308" href="#308">308</a>   }
-<a class="jxr_linenumber" name="309" href="#309">309</a> 
-<a class="jxr_linenumber" name="310" href="#310">310</a>   <strong class="jxr_keyword">private</strong> <strong class="jxr_keyword">void</strong> setNodes(ZkHelixPropertyStore&lt;ZNRecord&gt; store,
-<a class="jxr_linenumber" name="311" href="#311">311</a>                         <strong class="jxr_keyword">char</strong> c,
-<a class="jxr_linenumber" name="312" href="#312">312</a>                         <strong class="jxr_keyword">boolean</strong> needTimestamp)
-<a class="jxr_linenumber" name="313" href="#313">313</a>   {
-<a class="jxr_linenumber" name="314" href="#314">314</a>     <strong class="jxr_keyword">char</strong>[] data = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[bufSize];
-<a class="jxr_linenumber" name="315" href="#315">315</a> 
-<a class="jxr_linenumber" name="316" href="#316">316</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; bufSize; i++)
-<a class="jxr_linenumber" name="317" href="#317">317</a>     {
-<a class="jxr_linenumber" name="318" href="#318">318</a>       data[i] = c;
-<a class="jxr_linenumber" name="319" href="#319">319</a>     }
-<a class="jxr_linenumber" name="320" href="#320">320</a> 
-<a class="jxr_linenumber" name="321" href="#321">321</a>     Map&lt;String, String&gt; map = <strong class="jxr_keyword">new</strong> TreeMap&lt;String, String&gt;();
-<a class="jxr_linenumber" name="322" href="#322">322</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; mapNr; i++)
-<a class="jxr_linenumber" name="323" href="#323">323</a>     {
-<a class="jxr_linenumber" name="324" href="#324">324</a>       map.put(<span class="jxr_string">"key_"</span> + i, <strong class="jxr_keyword">new</strong> String(data));
-<a class="jxr_linenumber" name="325" href="#325">325</a>     }
-<a class="jxr_linenumber" name="326" href="#326">326</a> 
-<a class="jxr_linenumber" name="327" href="#327">327</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; firstLevelNr; i++)
-<a class="jxr_linenumber" name="328" href="#328">328</a>     {
-<a class="jxr_linenumber" name="329" href="#329">329</a>       <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> j = 0; j &lt; secondLevelNr; j++)
-<a class="jxr_linenumber" name="330" href="#330">330</a>       {
-<a class="jxr_linenumber" name="331" href="#331">331</a>         String nodeId = getNodeId(i, j);
-<a class="jxr_linenumber" name="332" href="#332">332</a>         ZNRecord record = <strong class="jxr_keyword">new</strong> ZNRecord(nodeId);
-<a class="jxr_linenumber" name="333" href="#333">333</a>         record.setSimpleFields(map);
-<a class="jxr_linenumber" name="334" href="#334">334</a>         <strong class="jxr_keyword">if</strong> (needTimestamp)
-<a class="jxr_linenumber" name="335" href="#335">335</a>         {
-<a class="jxr_linenumber" name="336" href="#336">336</a>           <strong class="jxr_keyword">long</strong> now = System.currentTimeMillis();
-<a class="jxr_linenumber" name="337" href="#337">337</a>           record.setSimpleField(<span class="jxr_string">"SetTimestamp"</span>, Long.toString(now));
-<a class="jxr_linenumber" name="338" href="#338">338</a>         }
-<a class="jxr_linenumber" name="339" href="#339">339</a>         String key = getSecondLevelKey(i, j);
-<a class="jxr_linenumber" name="340" href="#340">340</a>         store.set(key, record, AccessOption.PERSISTENT);
-<a class="jxr_linenumber" name="341" href="#341">341</a>       }
-<a class="jxr_linenumber" name="342" href="#342">342</a>     }
-<a class="jxr_linenumber" name="343" href="#343">343</a>   }
-<a class="jxr_linenumber" name="344" href="#344">344</a> 
-<a class="jxr_linenumber" name="345" href="#345">345</a>   <strong class="jxr_keyword">private</strong> <strong class="jxr_keyword">void</strong> setNodes(ZkClient zkClient, String root, <strong class="jxr_keyword">char</strong> c, <strong class="jxr_keyword">boolean</strong> needTimestamp)
-<a class="jxr_linenumber" name="346" href="#346">346</a>   {
-<a class="jxr_linenumber" name="347" href="#347">347</a>     <strong class="jxr_keyword">char</strong>[] data = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[bufSize];
-<a class="jxr_linenumber" name="348" href="#348">348</a> 
-<a class="jxr_linenumber" name="349" href="#349">349</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; bufSize; i++)
-<a class="jxr_linenumber" name="350" href="#350">350</a>     {
-<a class="jxr_linenumber" name="351" href="#351">351</a>       data[i] = c;
-<a class="jxr_linenumber" name="352" href="#352">352</a>     }
+<a class="jxr_linenumber" name="215" href="#215">215</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="216" href="#216">216</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="217" href="#217">217</a>     Assert.assertTrue(listener._createKeys.size() == expectCreateNodes, <span class="jxr_string">"Should receive "</span>
+<a class="jxr_linenumber" name="218" href="#218">218</a>         + expectCreateNodes + <span class="jxr_string">" create callbacks"</span>);
+<a class="jxr_linenumber" name="219" href="#219">219</a> 
+<a class="jxr_linenumber" name="220" href="#220">220</a>     <em class="jxr_comment">// test change callbacks</em>
+<a class="jxr_linenumber" name="221" href="#221">221</a>     listener.reset();
+<a class="jxr_linenumber" name="222" href="#222">222</a>     setNodes(_gZkClient, subRoot, 'b', <strong class="jxr_keyword">true</strong>);
+<a class="jxr_linenumber" name="223" href="#223">223</a>     <strong class="jxr_keyword">int</strong> expectChangeNodes = firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="224" href="#224">224</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; 10; i++) {
+<a class="jxr_linenumber" name="225" href="#225">225</a>     	<strong class="jxr_keyword">if</strong> (listener._changeKeys.size() &gt;= expectChangeNodes)
+<a class="jxr_linenumber" name="226" href="#226">226</a>     		<strong class="jxr_keyword">break</strong>;
+<a class="jxr_linenumber" name="227" href="#227">227</a>     	Thread.sleep(500);
+<a class="jxr_linenumber" name="228" href="#228">228</a>     }
+<a class="jxr_linenumber" name="229" href="#229">229</a> 
+<a class="jxr_linenumber" name="230" href="#230">230</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="231" href="#231">231</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="232" href="#232">232</a>     Assert.assertTrue(listener._changeKeys.size() &gt;= expectChangeNodes,
+<a class="jxr_linenumber" name="233" href="#233">233</a>                       <span class="jxr_string">"Should receive at least "</span> + expectChangeNodes
+<a class="jxr_linenumber" name="234" href="#234">234</a>                           + <span class="jxr_string">" change callbacks"</span>);
+<a class="jxr_linenumber" name="235" href="#235">235</a> 
+<a class="jxr_linenumber" name="236" href="#236">236</a>     <em class="jxr_comment">// test delete callbacks</em>
+<a class="jxr_linenumber" name="237" href="#237">237</a>     listener.reset();
+<a class="jxr_linenumber" name="238" href="#238">238</a>     <strong class="jxr_keyword">int</strong> expectDeleteNodes = 1 + firstLevelNr + firstLevelNr * secondLevelNr;
+<a class="jxr_linenumber" name="239" href="#239">239</a>     _gZkClient.deleteRecursive(subRoot);
+<a class="jxr_linenumber" name="240" href="#240">240</a>     Thread.sleep(1000);
+<a class="jxr_linenumber" name="241" href="#241">241</a> 
+<a class="jxr_linenumber" name="242" href="#242">242</a>     System.out.println(<span class="jxr_string">"createKey#:"</span> + listener._createKeys.size() + <span class="jxr_string">", changeKey#:"</span>
+<a class="jxr_linenumber" name="243" href="#243">243</a>         + listener._changeKeys.size() + <span class="jxr_string">", deleteKey#:"</span> + listener._deleteKeys.size());
+<a class="jxr_linenumber" name="244" href="#244">244</a>     Assert.assertTrue(listener._deleteKeys.size() == expectDeleteNodes, <span class="jxr_string">"Should receive "</span>
+<a class="jxr_linenumber" name="245" href="#245">245</a>         + expectDeleteNodes + <span class="jxr_string">" delete callbacks"</span>);
+<a class="jxr_linenumber" name="246" href="#246">246</a> 
+<a class="jxr_linenumber" name="247" href="#247">247</a>     store.stop();
+<a class="jxr_linenumber" name="248" href="#248">248</a>     System.out.println(<span class="jxr_string">"END testZkTriggeredCallback() at "</span>
+<a class="jxr_linenumber" name="249" href="#249">249</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="250" href="#250">250</a>   }
+<a class="jxr_linenumber" name="251" href="#251">251</a> 
+<a class="jxr_linenumber" name="252" href="#252">252</a>   @Test
+<a class="jxr_linenumber" name="253" href="#253">253</a>   <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testBackToBackRemoveAndSet() <strong class="jxr_keyword">throws</strong> Exception
+<a class="jxr_linenumber" name="254" href="#254">254</a>   {
+<a class="jxr_linenumber" name="255" href="#255">255</a>     System.out.println(<span class="jxr_string">"START testBackToBackRemoveAndSet() at "</span>
+<a class="jxr_linenumber" name="256" href="#256">256</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="257" href="#257">257</a> 
+<a class="jxr_linenumber" name="258" href="#258">258</a>     String subRoot = _root + <span class="jxr_string">"/"</span> + <span class="jxr_string">"backToBackRemoveAndSet"</span>;
+<a class="jxr_linenumber" name="259" href="#259">259</a>     List&lt;String&gt; subscribedPaths = <strong class="jxr_keyword">new</strong> ArrayList&lt;String&gt;();
+<a class="jxr_linenumber" name="260" href="#260">260</a>     subscribedPaths.add(subRoot);
+<a class="jxr_linenumber" name="261" href="#261">261</a>     ZkHelixPropertyStore&lt;ZNRecord&gt; store =
+<a class="jxr_linenumber" name="262" href="#262">262</a>         <strong class="jxr_keyword">new</strong> ZkHelixPropertyStore&lt;ZNRecord&gt;(<strong class="jxr_keyword">new</strong> ZkBaseDataAccessor&lt;ZNRecord&gt;(_gZkClient),
+<a class="jxr_linenumber" name="263" href="#263">263</a>                                            subRoot,
+<a class="jxr_linenumber" name="264" href="#264">264</a>                                            subscribedPaths);
+<a class="jxr_linenumber" name="265" href="#265">265</a> 
+<a class="jxr_linenumber" name="266" href="#266">266</a>     store.set(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">new</strong> ZNRecord(<span class="jxr_string">"child0"</span>), AccessOption.PERSISTENT);
+<a class="jxr_linenumber" name="267" href="#267">267</a> 
+<a class="jxr_linenumber" name="268" href="#268">268</a>     ZNRecord record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, 0); <em class="jxr_comment">// will put the record in cache</em>
+<a class="jxr_linenumber" name="269" href="#269">269</a>     Assert.assertEquals(record.getId(), <span class="jxr_string">"child0"</span>);
+<a class="jxr_linenumber" name="270" href="#270">270</a>     <em class="jxr_comment">// System.out.println("1:get:" + record);</em>
+<a class="jxr_linenumber" name="271" href="#271">271</a> 
+<a class="jxr_linenumber" name="272" href="#272">272</a>     String child0Path = subRoot + <span class="jxr_string">"/child0"</span>;
+<a class="jxr_linenumber" name="273" href="#273">273</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; 2; i++)
+<a class="jxr_linenumber" name="274" href="#274">274</a>     {
+<a class="jxr_linenumber" name="275" href="#275">275</a>       _gZkClient.delete(child0Path);
+<a class="jxr_linenumber" name="276" href="#276">276</a>       _gZkClient.createPersistent(child0Path, <strong class="jxr_keyword">new</strong> ZNRecord(<span class="jxr_string">"child0-new-"</span> + i));
+<a class="jxr_linenumber" name="277" href="#277">277</a>     }
+<a class="jxr_linenumber" name="278" href="#278">278</a> 
+<a class="jxr_linenumber" name="279" href="#279">279</a>     Thread.sleep(500); <em class="jxr_comment">// should wait for zk callback to add "/child0" into cache</em>
+<a class="jxr_linenumber" name="280" href="#280">280</a>     record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, 0);
+<a class="jxr_linenumber" name="281" href="#281">281</a>     Assert.assertEquals(record.getId(),
+<a class="jxr_linenumber" name="282" href="#282">282</a>                         <span class="jxr_string">"child0-new-1"</span>,
+<a class="jxr_linenumber" name="283" href="#283">283</a>                         <span class="jxr_string">"Cache shoulde be updated to latest create"</span>);
+<a class="jxr_linenumber" name="284" href="#284">284</a>     <em class="jxr_comment">// System.out.println("2:get:" + record);</em>
+<a class="jxr_linenumber" name="285" href="#285">285</a> 
+<a class="jxr_linenumber" name="286" href="#286">286</a>     _gZkClient.delete(child0Path);
+<a class="jxr_linenumber" name="287" href="#287">287</a>     Thread.sleep(500); <em class="jxr_comment">// should wait for zk callback to remove "/child0" from cache</em>
+<a class="jxr_linenumber" name="288" href="#288">288</a>     <strong class="jxr_keyword">try</strong>
+<a class="jxr_linenumber" name="289" href="#289">289</a>     {
+<a class="jxr_linenumber" name="290" href="#290">290</a>       record = store.get(<span class="jxr_string">"/child0"</span>, <strong class="jxr_keyword">null</strong>, AccessOption.THROW_EXCEPTION_IFNOTEXIST);
+<a class="jxr_linenumber" name="291" href="#291">291</a>       Assert.fail(<span class="jxr_string">"/child0 should have been removed"</span>);
+<a class="jxr_linenumber" name="292" href="#292">292</a>     }
+<a class="jxr_linenumber" name="293" href="#293">293</a>     <strong class="jxr_keyword">catch</strong> (ZkNoNodeException e)
+<a class="jxr_linenumber" name="294" href="#294">294</a>     {
+<a class="jxr_linenumber" name="295" href="#295">295</a>       <em class="jxr_comment">// OK.</em>
+<a class="jxr_linenumber" name="296" href="#296">296</a>     }
+<a class="jxr_linenumber" name="297" href="#297">297</a>     <em class="jxr_comment">// System.out.println("3:get:" + record);</em>
+<a class="jxr_linenumber" name="298" href="#298">298</a> 
+<a class="jxr_linenumber" name="299" href="#299">299</a>     store.stop();
+<a class="jxr_linenumber" name="300" href="#300">300</a>     System.out.println(<span class="jxr_string">"END testBackToBackRemoveAndSet() at "</span>
+<a class="jxr_linenumber" name="301" href="#301">301</a>         + <strong class="jxr_keyword">new</strong> Date(System.currentTimeMillis()));
+<a class="jxr_linenumber" name="302" href="#302">302</a>   }
+<a class="jxr_linenumber" name="303" href="#303">303</a> 
+<a class="jxr_linenumber" name="304" href="#304">304</a>   <strong class="jxr_keyword">private</strong> String getNodeId(<strong class="jxr_keyword">int</strong> i, <strong class="jxr_keyword">int</strong> j)
+<a class="jxr_linenumber" name="305" href="#305">305</a>   {
+<a class="jxr_linenumber" name="306" href="#306">306</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"childNode_"</span> + i + <span class="jxr_string">"_"</span> + j;
+<a class="jxr_linenumber" name="307" href="#307">307</a>   }
+<a class="jxr_linenumber" name="308" href="#308">308</a> 
+<a class="jxr_linenumber" name="309" href="#309">309</a>   <strong class="jxr_keyword">private</strong> String getSecondLevelKey(<strong class="jxr_keyword">int</strong> i, <strong class="jxr_keyword">int</strong> j)
+<a class="jxr_linenumber" name="310" href="#310">310</a>   {
+<a class="jxr_linenumber" name="311" href="#311">311</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"/node_"</span> + i + <span class="jxr_string">"/"</span> + getNodeId(i, j);
+<a class="jxr_linenumber" name="312" href="#312">312</a>   }
+<a class="jxr_linenumber" name="313" href="#313">313</a> 
+<a class="jxr_linenumber" name="314" href="#314">314</a>   <strong class="jxr_keyword">private</strong> String getFirstLevelKey(<strong class="jxr_keyword">int</strong> i)
+<a class="jxr_linenumber" name="315" href="#315">315</a>   {
+<a class="jxr_linenumber" name="316" href="#316">316</a>     <strong class="jxr_keyword">return</strong> <span class="jxr_string">"/node_"</span> + i;
+<a class="jxr_linenumber" name="317" href="#317">317</a>   }
+<a class="jxr_linenumber" name="318" href="#318">318</a> 
+<a class="jxr_linenumber" name="319" href="#319">319</a>   <strong class="jxr_keyword">private</strong> <strong class="jxr_keyword">void</strong> setNodes(ZkHelixPropertyStore&lt;ZNRecord&gt; store,
+<a class="jxr_linenumber" name="320" href="#320">320</a>                         <strong class="jxr_keyword">char</strong> c,
+<a class="jxr_linenumber" name="321" href="#321">321</a>                         <strong class="jxr_keyword">boolean</strong> needTimestamp)
+<a class="jxr_linenumber" name="322" href="#322">322</a>   {
+<a class="jxr_linenumber" name="323" href="#323">323</a>     <strong class="jxr_keyword">char</strong>[] data = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[bufSize];
+<a class="jxr_linenumber" name="324" href="#324">324</a> 
+<a class="jxr_linenumber" name="325" href="#325">325</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; bufSize; i++)
+<a class="jxr_linenumber" name="326" href="#326">326</a>     {
+<a class="jxr_linenumber" name="327" href="#327">327</a>       data[i] = c;
+<a class="jxr_linenumber" name="328" href="#328">328</a>     }
+<a class="jxr_linenumber" name="329" href="#329">329</a> 
+<a class="jxr_linenumber" name="330" href="#330">330</a>     Map&lt;String, String&gt; map = <strong class="jxr_keyword">new</strong> TreeMap&lt;String, String&gt;();
+<a class="jxr_linenumber" name="331" href="#331">331</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; mapNr; i++)
+<a class="jxr_linenumber" name="332" href="#332">332</a>     {
+<a class="jxr_linenumber" name="333" href="#333">333</a>       map.put(<span class="jxr_string">"key_"</span> + i, <strong class="jxr_keyword">new</strong> String(data));
+<a class="jxr_linenumber" name="334" href="#334">334</a>     }
+<a class="jxr_linenumber" name="335" href="#335">335</a> 
+<a class="jxr_linenumber" name="336" href="#336">336</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; firstLevelNr; i++)
+<a class="jxr_linenumber" name="337" href="#337">337</a>     {
+<a class="jxr_linenumber" name="338" href="#338">338</a>       <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> j = 0; j &lt; secondLevelNr; j++)
+<a class="jxr_linenumber" name="339" href="#339">339</a>       {
+<a class="jxr_linenumber" name="340" href="#340">340</a>         String nodeId = getNodeId(i, j);
+<a class="jxr_linenumber" name="341" href="#341">341</a>         ZNRecord record = <strong class="jxr_keyword">new</strong> ZNRecord(nodeId);
+<a class="jxr_linenumber" name="342" href="#342">342</a>         record.setSimpleFields(map);
+<a class="jxr_linenumber" name="343" href="#343">343</a>         <strong class="jxr_keyword">if</strong> (needTimestamp)
+<a class="jxr_linenumber" name="344" href="#344">344</a>         {
+<a class="jxr_linenumber" name="345" href="#345">345</a>           <strong class="jxr_keyword">long</strong> now = System.currentTimeMillis();
+<a class="jxr_linenumber" name="346" href="#346">346</a>           record.setSimpleField(<span class="jxr_string">"SetTimestamp"</span>, Long.toString(now));
+<a class="jxr_linenumber" name="347" href="#347">347</a>         }
+<a class="jxr_linenumber" name="348" href="#348">348</a>         String key = getSecondLevelKey(i, j);
+<a class="jxr_linenumber" name="349" href="#349">349</a>         store.set(key, record, AccessOption.PERSISTENT);
+<a class="jxr_linenumber" name="350" href="#350">350</a>       }
+<a class="jxr_linenumber" name="351" href="#351">351</a>     }
+<a class="jxr_linenumber" name="352" href="#352">352</a>   }
 <a class="jxr_linenumber" name="353" href="#353">353</a> 
-<a class="jxr_linenumber" name="354" href="#354">354</a>     Map&lt;String, String&gt; map = <strong class="jxr_keyword">new</strong> TreeMap&lt;String, String&gt;();
-<a class="jxr_linenumber" name="355" href="#355">355</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; mapNr; i++)
-<a class="jxr_linenumber" name="356" href="#356">356</a>     {
-<a class="jxr_linenumber" name="357" href="#357">357</a>       map.put(<span class="jxr_string">"key_"</span> + i, <strong class="jxr_keyword">new</strong> String(data));
-<a class="jxr_linenumber" name="358" href="#358">358</a>     }
-<a class="jxr_linenumber" name="359" href="#359">359</a> 
-<a class="jxr_linenumber" name="360" href="#360">360</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; firstLevelNr; i++)
-<a class="jxr_linenumber" name="361" href="#361">361</a>     {
-<a class="jxr_linenumber" name="362" href="#362">362</a>       String firstLevelKey = getFirstLevelKey(i);
-<a class="jxr_linenumber" name="363" href="#363">363</a> 
-<a class="jxr_linenumber" name="364" href="#364">364</a>       <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> j = 0; j &lt; secondLevelNr; j++)
-<a class="jxr_linenumber" name="365" href="#365">365</a>       {
-<a class="jxr_linenumber" name="366" href="#366">366</a>         String nodeId = getNodeId(i, j);
-<a class="jxr_linenumber" name="367" href="#367">367</a>         ZNRecord record = <strong class="jxr_keyword">new</strong> ZNRecord(nodeId);
-<a class="jxr_linenumber" name="368" href="#368">368</a>         record.setSimpleFields(map);
-<a class="jxr_linenumber" name="369" href="#369">369</a>         <strong class="jxr_keyword">if</strong> (needTimestamp)
-<a class="jxr_linenumber" name="370" href="#370">370</a>         {
-<a class="jxr_linenumber" name="371" href="#371">371</a>           <strong class="jxr_keyword">long</strong> now = System.currentTimeMillis();
-<a class="jxr_linenumber" name="372" href="#372">372</a>           record.setSimpleField(<span class="jxr_string">"SetTimestamp"</span>, Long.toString(now));
-<a class="jxr_linenumber" name="373" href="#373">373</a>         }
-<a class="jxr_linenumber" name="374" href="#374">374</a>         String key = getSecondLevelKey(i, j);
-<a class="jxr_linenumber" name="375" href="#375">375</a>         <strong class="jxr_keyword">try</strong>
-<a class="jxr_linenumber" name="376" href="#376">376</a>         {
-<a class="jxr_linenumber" name="377" href="#377">377</a>           zkClient.writeData(root + key, record);
-<a class="jxr_linenumber" name="378" href="#378">378</a>         }
-<a class="jxr_linenumber" name="379" href="#379">379</a>         <strong class="jxr_keyword">catch</strong> (ZkNoNodeException e)
-<a class="jxr_linenumber" name="380" href="#380">380</a>         {
-<a class="jxr_linenumber" name="381" href="#381">381</a>           zkClient.createPersistent(root + firstLevelKey, <strong class="jxr_keyword">true</strong>);
-<a class="jxr_linenumber" name="382" href="#382">382</a>           zkClient.createPersistent(root + key, record);
-<a class="jxr_linenumber" name="383" href="#383">383</a>         }
-<a class="jxr_linenumber" name="384" href="#384">384</a>       }
-<a class="jxr_linenumber" name="385" href="#385">385</a>     }
-<a class="jxr_linenumber" name="386" href="#386">386</a>   }
-<a class="jxr_linenumber" name="387" href="#387">387</a> 
-<a class="jxr_linenumber" name="388" href="#388">388</a> }
+<a class="jxr_linenumber" name="354" href="#354">354</a>   <strong class="jxr_keyword">private</strong> <strong class="jxr_keyword">void</strong> setNodes(ZkClient zkClient, String root, <strong class="jxr_keyword">char</strong> c, <strong class="jxr_keyword">boolean</strong> needTimestamp)
+<a class="jxr_linenumber" name="355" href="#355">355</a>   {
+<a class="jxr_linenumber" name="356" href="#356">356</a>     <strong class="jxr_keyword">char</strong>[] data = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[bufSize];
+<a class="jxr_linenumber" name="357" href="#357">357</a> 
+<a class="jxr_linenumber" name="358" href="#358">358</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; bufSize; i++)
+<a class="jxr_linenumber" name="359" href="#359">359</a>     {
+<a class="jxr_linenumber" name="360" href="#360">360</a>       data[i] = c;
+<a class="jxr_linenumber" name="361" href="#361">361</a>     }
+<a class="jxr_linenumber" name="362" href="#362">362</a> 
+<a class="jxr_linenumber" name="363" href="#363">363</a>     Map&lt;String, String&gt; map = <strong class="jxr_keyword">new</strong> TreeMap&lt;String, String&gt;();
+<a class="jxr_linenumber" name="364" href="#364">364</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; mapNr; i++)
+<a class="jxr_linenumber" name="365" href="#365">365</a>     {
+<a class="jxr_linenumber" name="366" href="#366">366</a>       map.put(<span class="jxr_string">"key_"</span> + i, <strong class="jxr_keyword">new</strong> String(data));
+<a class="jxr_linenumber" name="367" href="#367">367</a>     }
+<a class="jxr_linenumber" name="368" href="#368">368</a> 
+<a class="jxr_linenumber" name="369" href="#369">369</a>     <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> i = 0; i &lt; firstLevelNr; i++)
+<a class="jxr_linenumber" name="370" href="#370">370</a>     {
+<a class="jxr_linenumber" name="371" href="#371">371</a>       String firstLevelKey = getFirstLevelKey(i);
+<a class="jxr_linenumber" name="372" href="#372">372</a> 
+<a class="jxr_linenumber" name="373" href="#373">373</a>       <strong class="jxr_keyword">for</strong> (<strong class="jxr_keyword">int</strong> j = 0; j &lt; secondLevelNr; j++)
+<a class="jxr_linenumber" name="374" href="#374">374</a>       {
+<a class="jxr_linenumber" name="375" href="#375">375</a>         String nodeId = getNodeId(i, j);
+<a class="jxr_linenumber" name="376" href="#376">376</a>         ZNRecord record = <strong class="jxr_keyword">new</strong> ZNRecord(nodeId);
+<a class="jxr_linenumber" name="377" href="#377">377</a>         record.setSimpleFields(map);
+<a class="jxr_linenumber" name="378" href="#378">378</a>         <strong class="jxr_keyword">if</strong> (needTimestamp)
+<a class="jxr_linenumber" name="379" href="#379">379</a>         {
+<a class="jxr_linenumber" name="380" href="#380">380</a>           <strong class="jxr_keyword">long</strong> now = System.currentTimeMillis();
+<a class="jxr_linenumber" name="381" href="#381">381</a>           record.setSimpleField(<span class="jxr_string">"SetTimestamp"</span>, Long.toString(now));
+<a class="jxr_linenumber" name="382" href="#382">382</a>         }
+<a class="jxr_linenumber" name="383" href="#383">383</a>         String key = getSecondLevelKey(i, j);
+<a class="jxr_linenumber" name="384" href="#384">384</a>         <strong class="jxr_keyword">try</strong>
+<a class="jxr_linenumber" name="385" href="#385">385</a>         {
+<a class="jxr_linenumber" name="386" href="#386">386</a>           zkClient.writeData(root + key, record);
+<a class="jxr_linenumber" name="387" href="#387">387</a>         }
+<a class="jxr_linenumber" name="388" href="#388">388</a>         <strong class="jxr_keyword">catch</strong> (ZkNoNodeException e)
+<a class="jxr_linenumber" name="389" href="#389">389</a>         {
+<a class="jxr_linenumber" name="390" href="#390">390</a>           zkClient.createPersistent(root + firstLevelKey, <strong class="jxr_keyword">true</strong>);
+<a class="jxr_linenumber" name="391" href="#391">391</a>           zkClient.createPersistent(root + key, record);
+<a class="jxr_linenumber" name="392" href="#392">392</a>         }
+<a class="jxr_linenumber" name="393" href="#393">393</a>       }
+<a class="jxr_linenumber" name="394" href="#394">394</a>     }
+<a class="jxr_linenumber" name="395" href="#395">395</a>   }
+<a class="jxr_linenumber" name="396" href="#396">396</a> 
+<a class="jxr_linenumber" name="397" href="#397">397</a> }
 </pre>
 <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
 </html>

Modified: incubator/helix/site-content/xref/allclasses-frame.html
URL: http://svn.apache.org/viewvc/incubator/helix/site-content/xref/allclasses-frame.html?rev=1442295&r1=1442294&r2=1442295&view=diff
==============================================================================
--- incubator/helix/site-content/xref/allclasses-frame.html (original)
+++ incubator/helix/site-content/xref/allclasses-frame.html Mon Feb  4 18:40:07 2013
@@ -648,6 +648,9 @@
 				<a href="org/apache/helix/model/InstanceConfig.html" target="classFrame">InstanceConfig</a>
 			</li>
 						<li>
+				<a href="org/apache/helix/InstanceConfigChangeListener.html" target="classFrame">InstanceConfigChangeListener</a>
+			</li>
+						<li>
 				<a href="org/apache/helix/model/InstanceConfig.html" target="classFrame">InstanceConfigProperty</a>
 			</li>
 						<li>
@@ -972,6 +975,9 @@
 				<a href="org/apache/helix/webapp/resources/SchedulerTasksResource.html" target="classFrame">SchedulerTasksResource</a>
 			</li>
 						<li>
+				<a href="org/apache/helix/ScopedConfigChangeListener.html" target="classFrame">ScopedConfigChangeListener</a>
+			</li>
+						<li>
 				<a href="org/apache/helix/model/IdealState.html" target="classFrame">SemiAutoBuilder</a>
 			</li>
 						<li>

Modified: incubator/helix/site-content/xref/org/apache/helix/ConfigChangeListener.html
URL: http://svn.apache.org/viewvc/incubator/helix/site-content/xref/org/apache/helix/ConfigChangeListener.html?rev=1442295&r1=1442294&r2=1442295&view=diff
==============================================================================
--- incubator/helix/site-content/xref/org/apache/helix/ConfigChangeListener.html (original)
+++ incubator/helix/site-content/xref/org/apache/helix/ConfigChangeListener.html Mon Feb  4 18:40:07 2013
@@ -36,20 +36,21 @@
 <a class="jxr_linenumber" name="26" href="#26">26</a>  
 <a class="jxr_linenumber" name="27" href="#27">27</a>  <em class="jxr_javadoccomment">/**</em>
 <a class="jxr_linenumber" name="28" href="#28">28</a>  <em class="jxr_javadoccomment"> * </em>
-<a class="jxr_linenumber" name="29" href="#29">29</a>  <em class="jxr_javadoccomment"> */</em>
-<a class="jxr_linenumber" name="30" href="#30">30</a>  <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">interface</strong> <a href="../../../org/apache/helix/ConfigChangeListener.html">ConfigChangeListener</a>
-<a class="jxr_linenumber" name="31" href="#31">31</a>  {
-<a class="jxr_linenumber" name="32" href="#32">32</a>  
-<a class="jxr_linenumber" name="33" href="#33">33</a>    <em class="jxr_javadoccomment">/**</em>
-<a class="jxr_linenumber" name="34" href="#34">34</a>  <em class="jxr_javadoccomment">   * Invoked when participant config changes</em>
-<a class="jxr_linenumber" name="35" href="#35">35</a>  <em class="jxr_javadoccomment">   * </em>
-<a class="jxr_linenumber" name="36" href="#36">36</a>  <em class="jxr_javadoccomment">   * @param configs</em>
-<a class="jxr_linenumber" name="37" href="#37">37</a>  <em class="jxr_javadoccomment">   * @param changeContext</em>
-<a class="jxr_linenumber" name="38" href="#38">38</a>  <em class="jxr_javadoccomment">   */</em>
-<a class="jxr_linenumber" name="39" href="#39">39</a>    <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> onConfigChange(List&lt;InstanceConfig&gt; configs,
-<a class="jxr_linenumber" name="40" href="#40">40</a>                               <a href="../../../org/apache/helix/NotificationContext.html">NotificationContext</a> changeContext);
-<a class="jxr_linenumber" name="41" href="#41">41</a>  
-<a class="jxr_linenumber" name="42" href="#42">42</a>  }
+<a class="jxr_linenumber" name="29" href="#29">29</a>  <em class="jxr_javadoccomment"> * @deprecated replaced by InstanceConfigChangeListener</em>
+<a class="jxr_linenumber" name="30" href="#30">30</a>  <em class="jxr_javadoccomment"> */</em>
+<a class="jxr_linenumber" name="31" href="#31">31</a>  <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">interface</strong> <a href="../../../org/apache/helix/ConfigChangeListener.html">ConfigChangeListener</a>
+<a class="jxr_linenumber" name="32" href="#32">32</a>  {
+<a class="jxr_linenumber" name="33" href="#33">33</a>  
+<a class="jxr_linenumber" name="34" href="#34">34</a>    <em class="jxr_javadoccomment">/**</em>
+<a class="jxr_linenumber" name="35" href="#35">35</a>  <em class="jxr_javadoccomment">   * Invoked when participant config changes</em>
+<a class="jxr_linenumber" name="36" href="#36">36</a>  <em class="jxr_javadoccomment">   * </em>
+<a class="jxr_linenumber" name="37" href="#37">37</a>  <em class="jxr_javadoccomment">   * @param configs</em>
+<a class="jxr_linenumber" name="38" href="#38">38</a>  <em class="jxr_javadoccomment">   * @param changeContext</em>
+<a class="jxr_linenumber" name="39" href="#39">39</a>  <em class="jxr_javadoccomment">   */</em>
+<a class="jxr_linenumber" name="40" href="#40">40</a>    <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> onConfigChange(List&lt;InstanceConfig&gt; configs,
+<a class="jxr_linenumber" name="41" href="#41">41</a>                               <a href="../../../org/apache/helix/NotificationContext.html">NotificationContext</a> changeContext);
+<a class="jxr_linenumber" name="42" href="#42">42</a>  
+<a class="jxr_linenumber" name="43" href="#43">43</a>  }
 </pre>
 <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
 </html>

Modified: incubator/helix/site-content/xref/org/apache/helix/HelixConstants.html
URL: http://svn.apache.org/viewvc/incubator/helix/site-content/xref/org/apache/helix/HelixConstants.html?rev=1442295&r1=1442294&r2=1442295&view=diff
==============================================================================
--- incubator/helix/site-content/xref/org/apache/helix/HelixConstants.html (original)
+++ incubator/helix/site-content/xref/org/apache/helix/HelixConstants.html Mon Feb  4 18:40:07 2013
@@ -37,28 +37,29 @@
 <a class="jxr_linenumber" name="27" href="#27">27</a>      <em class="jxr_comment">// @formatter:off</em>
 <a class="jxr_linenumber" name="28" href="#28">28</a>      IDEAL_STATE,
 <a class="jxr_linenumber" name="29" href="#29">29</a>      CONFIG,
-<a class="jxr_linenumber" name="30" href="#30">30</a>      LIVE_INSTANCE,
-<a class="jxr_linenumber" name="31" href="#31">31</a>      CURRENT_STATE,
-<a class="jxr_linenumber" name="32" href="#32">32</a>      MESSAGE,
-<a class="jxr_linenumber" name="33" href="#33">33</a>      EXTERNAL_VIEW,
-<a class="jxr_linenumber" name="34" href="#34">34</a>      CONTROLLER,
-<a class="jxr_linenumber" name="35" href="#35">35</a>      MESSAGES_CONTROLLER,
-<a class="jxr_linenumber" name="36" href="#36">36</a>      HEALTH
-<a class="jxr_linenumber" name="37" href="#37">37</a>      <em class="jxr_comment">// @formatter:on</em>
-<a class="jxr_linenumber" name="38" href="#38">38</a>    }
-<a class="jxr_linenumber" name="39" href="#39">39</a>  
-<a class="jxr_linenumber" name="40" href="#40">40</a>    enum <a href="../../../org/apache/helix/HelixConstants.html">StateModelToken</a>
-<a class="jxr_linenumber" name="41" href="#41">41</a>    {
-<a class="jxr_linenumber" name="42" href="#42">42</a>      ANY_LIVEINSTANCE
-<a class="jxr_linenumber" name="43" href="#43">43</a>    }
-<a class="jxr_linenumber" name="44" href="#44">44</a>  
-<a class="jxr_linenumber" name="45" href="#45">45</a>    enum <a href="../../../org/apache/helix/HelixConstants.html">ClusterConfigType</a>
-<a class="jxr_linenumber" name="46" href="#46">46</a>    {
-<a class="jxr_linenumber" name="47" href="#47">47</a>      HELIX_DISABLE_PIPELINE_TRIGGERS
-<a class="jxr_linenumber" name="48" href="#48">48</a>    }
-<a class="jxr_linenumber" name="49" href="#49">49</a>  
-<a class="jxr_linenumber" name="50" href="#50">50</a>    <strong class="jxr_keyword">static</strong> <strong class="jxr_keyword">final</strong> String DEFAULT_STATE_MODEL_FACTORY = <span class="jxr_string">"DEFAULT"</span>;
-<a class="jxr_linenumber" name="51" href="#51">51</a>  }
+<a class="jxr_linenumber" name="30" href="#30">30</a>      INSTANCE_CONFIG,
+<a class="jxr_linenumber" name="31" href="#31">31</a>      LIVE_INSTANCE,
+<a class="jxr_linenumber" name="32" href="#32">32</a>      CURRENT_STATE,
+<a class="jxr_linenumber" name="33" href="#33">33</a>      MESSAGE,
+<a class="jxr_linenumber" name="34" href="#34">34</a>      EXTERNAL_VIEW,
+<a class="jxr_linenumber" name="35" href="#35">35</a>      CONTROLLER,
+<a class="jxr_linenumber" name="36" href="#36">36</a>      MESSAGES_CONTROLLER,
+<a class="jxr_linenumber" name="37" href="#37">37</a>      HEALTH
+<a class="jxr_linenumber" name="38" href="#38">38</a>      <em class="jxr_comment">// @formatter:on</em>
+<a class="jxr_linenumber" name="39" href="#39">39</a>    }
+<a class="jxr_linenumber" name="40" href="#40">40</a>  
+<a class="jxr_linenumber" name="41" href="#41">41</a>    enum <a href="../../../org/apache/helix/HelixConstants.html">StateModelToken</a>
+<a class="jxr_linenumber" name="42" href="#42">42</a>    {
+<a class="jxr_linenumber" name="43" href="#43">43</a>      ANY_LIVEINSTANCE
+<a class="jxr_linenumber" name="44" href="#44">44</a>    }
+<a class="jxr_linenumber" name="45" href="#45">45</a>  
+<a class="jxr_linenumber" name="46" href="#46">46</a>    enum <a href="../../../org/apache/helix/HelixConstants.html">ClusterConfigType</a>
+<a class="jxr_linenumber" name="47" href="#47">47</a>    {
+<a class="jxr_linenumber" name="48" href="#48">48</a>      HELIX_DISABLE_PIPELINE_TRIGGERS
+<a class="jxr_linenumber" name="49" href="#49">49</a>    }
+<a class="jxr_linenumber" name="50" href="#50">50</a>  
+<a class="jxr_linenumber" name="51" href="#51">51</a>    <strong class="jxr_keyword">static</strong> <strong class="jxr_keyword">final</strong> String DEFAULT_STATE_MODEL_FACTORY = <span class="jxr_string">"DEFAULT"</span>;
+<a class="jxr_linenumber" name="52" href="#52">52</a>  }
 </pre>
 <hr/><div id="footer">This page was automatically generated by <a href="http://maven.apache.org/">Maven</a></div></body>
 </html>



Mime
View raw message