Author: laubai
Date: 2010-02-09 00:15:57 -0500 (Tue, 09 Feb 2010)
New Revision: 8334
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.xml
Removed:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.ent
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.xml
Modified:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Book_Info.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Revision_History.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Book_Info.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Revision_History.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Book_Info.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Revision_History.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/cache_loaders.xml
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/replication.xml
Log:
Updated book details for 5.0.1.
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Book_Info.xml
===================================================================
--- enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Book_Info.xml 2010-02-09 05:14:07
UTC (rev 8333)
+++ enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Book_Info.xml 2010-02-09 05:15:57
UTC (rev 8334)
@@ -2,11 +2,11 @@
<!DOCTYPE bookinfo PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
<bookinfo>
- <title>JBoss Cache Frequently Asked Questions</title>
- <subtitle>for Use with JBoss Enterprise Web Platform 5.0</subtitle>
+ <title>JBoss Cache Frequently Asked Questions CP01</title>
+ <subtitle>for Use with JBoss Enterprise Application Platform 5.0 Cumulative Patch
1</subtitle>
<edition>2.0</edition>
<pubsnumber>1</pubsnumber>
- <productname>JBoss Enterprise Web Platform</productname>
+ <productname>JBoss Enterprise Application Platform</productname>
<productnumber>5.0</productnumber>
<abstract>
<para>This book is a compilation of frequently asked questions about JBoss
Cache.</para>
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.ent 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,3 +0,0 @@
-<!ENTITY HOLDER "Red Hat, Inc">
-<!ENTITY YEAR "2010">
-<!ENTITY VERSION "">
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
-]>
-<book id="JBoss_Cache_FAQ">
-<xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-<xi:include href="General_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="TreeCache_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="Eviction_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="CacheLoader_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="Troubleshooting.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include
xmlns:xi="http://www.w3.org/2001/XInclude"
href="Revision_History.xml"/>
-</book>
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.ent
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,3 @@
+<!ENTITY HOLDER "Red Hat, Inc">
+<!ENTITY YEAR "2010">
+<!ENTITY VERSION "5.0">
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.ent
___________________________________________________________________
Name: svn:executable
+ *
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.xml
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
+]>
+<book id="JBoss_Cache_FAQ">
+<xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+<xi:include href="General_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="TreeCache_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="Eviction_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="CacheLoader_FAQ.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="Troubleshooting.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include
xmlns:xi="http://www.w3.org/2001/XInclude"
href="Revision_History.xml"/>
+</book>
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/JBoss_Cache_Frequently_Asked_Questions_CP01.xml
___________________________________________________________________
Name: svn:executable
+ *
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Revision_History.xml
===================================================================
--- enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Revision_History.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++ enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_FAQ/en-US/Revision_History.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -8,7 +8,7 @@
<revhistory>
<revision>
<revnumber>1.0</revnumber>
- <date>Tue Dec 15 2009</date>
+ <date>Tue Feb 09 2010</date>
<author>
<firstname>Laura</firstname>
<surname>Bailey</surname>
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Book_Info.xml
===================================================================
--- enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Book_Info.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++ enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Book_Info.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,11 +1,11 @@
<?xml version='1.0'?>
<!DOCTYPE bookinfo PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-<bookinfo id="JBoss_Cache">
- <title>JBoss Cache Tutorial</title>
- <subtitle>for Use with JBoss Enterprise Application Platform 5.0</subtitle>
+<bookinfo id="JBoss_Cache_Tutorial_CP01">
+ <title>JBoss Cache Tutorial CP01</title>
+ <subtitle>for Use with JBoss Enterprise Application Platform 5.0 Cumulative Patch
1</subtitle>
<edition>2.0</edition>
- <pubsnumber>2</pubsnumber>
+ <pubsnumber>1</pubsnumber>
<productname>JBoss Enterprise Application Platform</productname>
<productnumber>5.0</productnumber>
<abstract>
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.ent 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,3 +0,0 @@
-<!ENTITY HOLDER "Red Hat, Inc">
-<!ENTITY YEAR "2009">
-<!ENTITY VERSION "">
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,228 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-<book id="JBossCache_Tutorial">
- <xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <chapter id="JBossCache_Tutorial-Introduction">
- <title>Introduction</title>
-
- <para>
- JBoss Cache is an in-memory replicated, transactional, and fine-grained cache.
- This tutorial focuses on the core Cache API. Please refer to the accompanying
tutorial
- for POJO Cache, if it is the POJO Cache API you are interested in.
- </para>
- <para>
- For details about configuration, usage and APIs, please refer to the JBoss Cache
User Guide for JBoss Enterprise Application Platform 5.0, available from <ulink
url="http://www.redhat.com/docs/en-US/JBoss_Enterprise_Application_P...;.
- </para>
-
- <section>
- <title>What You Will Learn</title>
-
- <itemizedlist>
- <listitem>
- <para>Cache creation and modification</para>
- </listitem>
-
- <listitem>
- <para>Replication of state</para>
- </listitem>
-
- <listitem>
- <para>Transactions</para>
- </listitem>
- </itemizedlist>
- </section>
-</chapter>
- <chapter>
- <title>Configuration</title>
-
- <para>First download the JBoss Cache 3.x distribution from
- <ulink
url="http://labs.jboss.org/jbosscache/download/index.html">the download
page</ulink>. You will need the <emphasis>all</emphasis> distribution
(<literal>jbosscache-core-3.X.Y.GA-all.zip</literal>). Unzip it, and you will
get a directory containing the distribution, such as
<literal>jbosscache-core-3.X.Y</literal>. For the sake of this tutorial, I
will refer to this as <literal>${JBOSSCACHE_HOME}</literal>.
- </para>
-
- <para>The configuration files are located in
<literal>${JBOSSCACHE_HOME}/etc</literal>. You can modify the behavior of the
cache by editing the various configuration files.
- </para>
-
- <itemizedlist>
- <listitem>
- <para>
- <literal>log4j.xml</literal>: Logging output. You can enable
logging, specify log levels or
- change the name and path to the log file.
- </para>
- </listitem>
-
- <listitem>
- <para>
- <literal>config-samples/total-replication.xml</literal>: Cache
configuration file used for this tutorial.
- </para>
- </listitem>
- </itemizedlist>
- </chapter>
-
- <chapter>
- <title>Script</title>
-
- <para>The only script needed for this tutorial is the
- <literal>${JBOSSCACHE_HOME}/tutorial/build.xml</literal>
- ant script. You also need to have
- <ulink
url="http://ant.apache.org/">Apache Ant</ulink>
- installed for running the tutorial GUI.
- </para>
- </chapter>
-
- <chapter>
- <title>Running The Tutorial GUI</title>
-
- <para>
- The GUI is run by:
- <itemizedlist>
- <listitem><para>Changing to the
- <literal>${JBOSSCACHE_HOME}/tutorial</literal>
- directory (e.g.,<literal>cd
${JBOSSCACHE_HOME}/tutorial</literal>)</para></listitem>
- <listitem><para>And then running the ant script (e.g.,
<literal>ant run</literal>)</para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- This will cause a GUI window to appear, giving you a tree view of the cache in
the top pane and a BeanShell
- view of the JVM in the lower pane.
- </para>
- <para>
- The BeanShell view is preset with the following variables:</para>
- <itemizedlist>
- <listitem><para>
- <literal>cache</literal>: a reference to the
<literal>org.jboss.cache.Cache</literal> interface, used by the GUI
instance.</para>
- </listitem>
- <listitem><para>
- <literal>root</literal>: a reference to the root
<literal>org.jboss.cache.Node</literal> instance for the above
cache.</para>
- </listitem>
- <listitem><para>
- <literal>transactionManager</literal>: a reference to the
registered <literal>javax.transaction.TransactionManager</literal>
instance.</para>
- </listitem>
- </itemizedlist>
- <para> The references made available to the BeanShell window point to the
same cache instance used by the tree view in
- the
- GUI above.
- </para>
-
- <para>
- To run the GUI as a replicated tutorial, it is useful to start another command
line window and run the ant script
- again as you did above. Now you will have two cache instances running in two
separate GUIs, replicating state
- to each other.
- </para>
-
- </chapter>
-
- <chapter>
- <title>Tutorials</title>
- <important><para> It is recommended that you shut down and restart the
GUI for each of the following tutorials, to
- ensure clean caches every time.</para></important>
- <section>
- <title>Caches and Nodes</title>
- <para>
- For this tutorial, start a single instance of the GUI. In this tutorial, we
will:</para>
-
- <itemizedlist>
- <listitem><para>Create nodes under the root
node.</para></listitem>
- <listitem><para>Remove nodes under the root node, both
individually and recursively.</para></listitem>
- <listitem><para>Add and remove data from
nodes.</para></listitem>
- </itemizedlist>
-
- <para>1. Set up the Fqns you need. In the BeanShell pane, create 3 Fqn
variables:</para>
- <programlisting role="JAVA"><![CDATA[
- childFqn1 = Fqn.fromString("/child1");
- childFqn2 = Fqn.fromString("/child2");
- childFqn3 = Fqn.fromString("/child2/child3");
- ]]></programlisting>
-
- <para>2. Create child nodes under the root node.</para>
- <programlisting role="JAVA"><![CDATA[
- child1 = root.addChild(childFqn1);
- child2 = root.addChild(childFqn2);
- child3 = root.addChild(childFqn3);
- ]]></programlisting>
-
-
- <para>3. Query the nodes.</para>
- <programlisting role="JAVA"><![CDATA[
- root.hasChild(childFqn1); // should return true
- child2.hasChild(childFqn3.getLastElement()); // should return true
- child3.getParent(); // should return child2
- child2.getParent(); // should return root
- ]]></programlisting>
-
- <para>4. Put some data in the nodes. By selecting the nodes in the tree
view, you should see the contents of
- each node.
- </para>
- <programlisting role="JAVA"><![CDATA[
- child1.put("key1", "value1");
- child1.put("key2", "value2");
- child2.put("key3", "value3");
- child2.put("key4", "value4");
- child3.put("key5", "value5");
- child3.put("key6", "value6");
- ]]></programlisting>
-
- <para>5. Query some of the data.</para>
-
- <programlisting role="JAVA"><![CDATA[
- child1.getKeys();
- child2.getData();
- ]]></programlisting>
-
- <para>6. Remove some data in the nodes.</para>
-
- <programlisting role="JAVA"><![CDATA[
- child1.remove("key1");
- child2.remove("key3");
- child3.clearData();
- ]]></programlisting>
-
- <para>7. Delete nodes</para>
-
- <programlisting role="JAVA"><![CDATA[
-root.removeChild(childFqn1); // will also remove any data held under child1
-root.removeChild(childFqn2); // will recursively remove child3 as well
- ]]></programlisting>
-
- <!-- <para>
- In addition to the above, you should refer to the
- <literal>Cache</literal>
- and
- <literal>Node</literal>
- <ulink
url="http://labs.jboss.org/portal/jbosscache/docs/index.html"&g...
docs</ulink>
- and try out the APIs in the BeanShell script.
- </para>-->
- </section>
-
- <section>
- <title>Replication</title>
- <para>
- For this tutorial, start two instances of the GUI. Repeat the exercises in
the previous
- tutorial,
- only alternating between the two GUI windows when creating/removing nodes or
adding/removing data. This
- demonstrates
- how the two cache instances in the two GUIs are kept in sync.
- </para>
- </section>
-
- <section>
- <title>Transactions</title>
- <para>
- For this tutorial, start two instances of the GUI. Repeat the exercises in
the previous
- tutorial,
- only starting transactions before creating/removing nodes or adding/removing
data. This will depict how
- replication only occurs on transaction boundaries. Try rolling back a few
transactions as well, to see how
- nothing gets replicated in these cases.
- Below is the sample code for managing transactions:
- </para>
- <programlisting role="JAVA"><![CDATA[
- tm = cache.getTransactionManager();
- tm.begin();
- // do operations here
- tm.commit(); // or tm.rollback();
- ]]></programlisting>
- </section>
-
- </chapter>
-<xi:include
xmlns:xi="http://www.w3.org/2001/XInclude"
href="Revision_History.xml"/>
-</book>
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.ent
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,3 @@
+<!ENTITY HOLDER "Red Hat, Inc">
+<!ENTITY YEAR "2010">
+<!ENTITY VERSION "5.0">
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.ent
___________________________________________________________________
Name: svn:executable
+ *
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.xml
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,228 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
+<book id="JBossCache_Tutorial">
+ <xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <chapter id="JBossCache_Tutorial-Introduction">
+ <title>Introduction</title>
+
+ <para>
+ JBoss Cache is an in-memory replicated, transactional, and fine-grained cache.
+ This tutorial focuses on the core Cache API. Please refer to the accompanying
tutorial
+ for POJO Cache, if it is the POJO Cache API you are interested in.
+ </para>
+ <para>
+ For details about configuration, usage and APIs, please refer to the JBoss Cache
User Guide for JBoss Enterprise Application Platform 5.0, available from <ulink
url="http://www.redhat.com/docs/en-US/JBoss_Enterprise_Application_P...;.
+ </para>
+
+ <section>
+ <title>What You Will Learn</title>
+
+ <itemizedlist>
+ <listitem>
+ <para>Cache creation and modification</para>
+ </listitem>
+
+ <listitem>
+ <para>Replication of state</para>
+ </listitem>
+
+ <listitem>
+ <para>Transactions</para>
+ </listitem>
+ </itemizedlist>
+ </section>
+</chapter>
+ <chapter>
+ <title>Configuration</title>
+
+ <para>First download the JBoss Cache 3.x distribution from
+ <ulink
url="http://labs.jboss.org/jbosscache/download/index.html">the download
page</ulink>. You will need the <emphasis>all</emphasis> distribution
(<literal>jbosscache-core-3.X.Y.GA-all.zip</literal>). Unzip it, and you will
get a directory containing the distribution, such as
<literal>jbosscache-core-3.X.Y</literal>. For the sake of this tutorial, I
will refer to this as <literal>${JBOSSCACHE_HOME}</literal>.
+ </para>
+
+ <para>The configuration files are located in
<literal>${JBOSSCACHE_HOME}/etc</literal>. You can modify the behavior of the
cache by editing the various configuration files.
+ </para>
+
+ <itemizedlist>
+ <listitem>
+ <para>
+ <literal>log4j.xml</literal>: Logging output. You can enable
logging, specify log levels or
+ change the name and path to the log file.
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
+ <literal>config-samples/total-replication.xml</literal>: Cache
configuration file used for this tutorial.
+ </para>
+ </listitem>
+ </itemizedlist>
+ </chapter>
+
+ <chapter>
+ <title>Script</title>
+
+ <para>The only script needed for this tutorial is the
+ <literal>${JBOSSCACHE_HOME}/tutorial/build.xml</literal>
+ ant script. You also need to have
+ <ulink
url="http://ant.apache.org/">Apache Ant</ulink>
+ installed for running the tutorial GUI.
+ </para>
+ </chapter>
+
+ <chapter>
+ <title>Running The Tutorial GUI</title>
+
+ <para>
+ The GUI is run by:
+ <itemizedlist>
+ <listitem><para>Changing to the
+ <literal>${JBOSSCACHE_HOME}/tutorial</literal>
+ directory (e.g.,<literal>cd
${JBOSSCACHE_HOME}/tutorial</literal>)</para></listitem>
+ <listitem><para>And then running the ant script (e.g.,
<literal>ant run</literal>)</para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ This will cause a GUI window to appear, giving you a tree view of the cache in
the top pane and a BeanShell
+ view of the JVM in the lower pane.
+ </para>
+ <para>
+ The BeanShell view is preset with the following variables:</para>
+ <itemizedlist>
+ <listitem><para>
+ <literal>cache</literal>: a reference to the
<literal>org.jboss.cache.Cache</literal> interface, used by the GUI
instance.</para>
+ </listitem>
+ <listitem><para>
+ <literal>root</literal>: a reference to the root
<literal>org.jboss.cache.Node</literal> instance for the above
cache.</para>
+ </listitem>
+ <listitem><para>
+ <literal>transactionManager</literal>: a reference to the
registered <literal>javax.transaction.TransactionManager</literal>
instance.</para>
+ </listitem>
+ </itemizedlist>
+ <para> The references made available to the BeanShell window point to the
same cache instance used by the tree view in
+ the
+ GUI above.
+ </para>
+
+ <para>
+ To run the GUI as a replicated tutorial, it is useful to start another command
line window and run the ant script
+ again as you did above. Now you will have two cache instances running in two
separate GUIs, replicating state
+ to each other.
+ </para>
+
+ </chapter>
+
+ <chapter>
+ <title>Tutorials</title>
+ <important><para> It is recommended that you shut down and restart the
GUI for each of the following tutorials, to
+ ensure clean caches every time.</para></important>
+ <section>
+ <title>Caches and Nodes</title>
+ <para>
+ For this tutorial, start a single instance of the GUI. In this tutorial, we
will:</para>
+
+ <itemizedlist>
+ <listitem><para>Create nodes under the root
node.</para></listitem>
+ <listitem><para>Remove nodes under the root node, both
individually and recursively.</para></listitem>
+ <listitem><para>Add and remove data from
nodes.</para></listitem>
+ </itemizedlist>
+
+ <para>1. Set up the Fqns you need. In the BeanShell pane, create 3 Fqn
variables:</para>
+ <programlisting role="JAVA"><![CDATA[
+ childFqn1 = Fqn.fromString("/child1");
+ childFqn2 = Fqn.fromString("/child2");
+ childFqn3 = Fqn.fromString("/child2/child3");
+ ]]></programlisting>
+
+ <para>2. Create child nodes under the root node.</para>
+ <programlisting role="JAVA"><![CDATA[
+ child1 = root.addChild(childFqn1);
+ child2 = root.addChild(childFqn2);
+ child3 = root.addChild(childFqn3);
+ ]]></programlisting>
+
+
+ <para>3. Query the nodes.</para>
+ <programlisting role="JAVA"><![CDATA[
+ root.hasChild(childFqn1); // should return true
+ child2.hasChild(childFqn3.getLastElement()); // should return true
+ child3.getParent(); // should return child2
+ child2.getParent(); // should return root
+ ]]></programlisting>
+
+ <para>4. Put some data in the nodes. By selecting the nodes in the tree
view, you should see the contents of
+ each node.
+ </para>
+ <programlisting role="JAVA"><![CDATA[
+ child1.put("key1", "value1");
+ child1.put("key2", "value2");
+ child2.put("key3", "value3");
+ child2.put("key4", "value4");
+ child3.put("key5", "value5");
+ child3.put("key6", "value6");
+ ]]></programlisting>
+
+ <para>5. Query some of the data.</para>
+
+ <programlisting role="JAVA"><![CDATA[
+ child1.getKeys();
+ child2.getData();
+ ]]></programlisting>
+
+ <para>6. Remove some data in the nodes.</para>
+
+ <programlisting role="JAVA"><![CDATA[
+ child1.remove("key1");
+ child2.remove("key3");
+ child3.clearData();
+ ]]></programlisting>
+
+ <para>7. Delete nodes</para>
+
+ <programlisting role="JAVA"><![CDATA[
+root.removeChild(childFqn1); // will also remove any data held under child1
+root.removeChild(childFqn2); // will recursively remove child3 as well
+ ]]></programlisting>
+
+ <!-- <para>
+ In addition to the above, you should refer to the
+ <literal>Cache</literal>
+ and
+ <literal>Node</literal>
+ <ulink
url="http://labs.jboss.org/portal/jbosscache/docs/index.html"&g...
docs</ulink>
+ and try out the APIs in the BeanShell script.
+ </para>-->
+ </section>
+
+ <section>
+ <title>Replication</title>
+ <para>
+ For this tutorial, start two instances of the GUI. Repeat the exercises in
the previous
+ tutorial,
+ only alternating between the two GUI windows when creating/removing nodes or
adding/removing data. This
+ demonstrates
+ how the two cache instances in the two GUIs are kept in sync.
+ </para>
+ </section>
+
+ <section>
+ <title>Transactions</title>
+ <para>
+ For this tutorial, start two instances of the GUI. Repeat the exercises in
the previous
+ tutorial,
+ only starting transactions before creating/removing nodes or adding/removing
data. This will depict how
+ replication only occurs on transaction boundaries. Try rolling back a few
transactions as well, to see how
+ nothing gets replicated in these cases.
+ Below is the sample code for managing transactions:
+ </para>
+ <programlisting role="JAVA"><![CDATA[
+ tm = cache.getTransactionManager();
+ tm.begin();
+ // do operations here
+ tm.commit(); // or tm.rollback();
+ ]]></programlisting>
+ </section>
+
+ </chapter>
+<xi:include
xmlns:xi="http://www.w3.org/2001/XInclude"
href="Revision_History.xml"/>
+</book>
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/JBoss_Cache_Tutorial_CP01.xml
___________________________________________________________________
Name: svn:executable
+ *
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Revision_History.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Revision_History.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_Tutorial/en-US/Revision_History.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -8,7 +8,7 @@
<revhistory>
<revision>
<revnumber>1.0</revnumber>
- <date>Thu Oct 22 2009</date>
+ <date>Tue Feb 09 2010</date>
<author>
<firstname>Laura</firstname>
<surname>Bailey</surname>
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Book_Info.xml
===================================================================
--- enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Book_Info.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++ enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Book_Info.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,9 +1,9 @@
<?xml version='1.0'?>
<!DOCTYPE bookinfo PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-<bookinfo id="JBoss_Cache">
- <title>JBoss Cache User Guide</title>
- <subtitle>for Use with JBoss Enterprise Application Platform 5.0</subtitle>
+<bookinfo id="JBoss_Cache_User_Guide_CP01">
+ <title>JBoss Cache User Guide CP01</title>
+ <subtitle>for Use with JBoss Enterprise Application Platform 5.0 Cumulative Patch
1</subtitle>
<edition>2.0</edition>
<pubsnumber>1</pubsnumber>
<productname>JBoss Enterprise Application Platform</productname>
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.ent 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,3 +0,0 @@
-<!ENTITY HOLDER "Red Hat, Inc">
-<!ENTITY YEAR "2009">
-<!ENTITY VERSION "">
Deleted:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
- "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
- ]>
-<book>
-
-<xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="preface.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-
- <part label="I">
- <title>Introduction to JBoss Cache</title>
- <partintro>
- <para>
- This section covers what developers would need to quickly start using JBoss
Cache in their projects. It
- covers an overview of the concepts and API, configuration and deployment
information.
- </para>
- </partintro>
- <xi:include href="introduction.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-<xi:include href="basic_api.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="configuration.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="batching.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="deployment.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="compatibility.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-
- </part>
-
- <part label="II">
- <title>JBoss Cache Architecture</title>
- <partintro>
- <para>
- This section digs deeper into the JBoss Cache architecture, and is meant for
developers wishing to use the more
- advanced cache features,extend or enhance the cache, write plugins, or are
just looking for detailed knowledge
- of how things work under the hood.
- </para>
- </partintro>
-<xi:include href="architecture.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="replication.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="cache_loaders.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="eviction_policies.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="transactions.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-
- </part>
-
- <part label="III">
- <title>JBoss Cache Configuration References</title>
- <partintro>
- <para>
- This section contains technical references for easy looking up.
- </para>
- </partintro>
-
-<xi:include href="configuration_reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="jmx_reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
-
- </part>
-</book>
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.ent
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.ent
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.ent 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,3 @@
+<!ENTITY HOLDER "Red Hat, Inc">
+<!ENTITY YEAR "2010">
+<!ENTITY VERSION "5.0">
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.ent
___________________________________________________________________
Name: svn:executable
+ *
Added:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.xml
(rev 0)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
+ ]>
+<book>
+
+<xi:include href="Book_Info.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="preface.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+
+ <part label="I">
+ <title>Introduction to JBoss Cache</title>
+ <partintro>
+ <para>
+ This section covers what developers would need to quickly start using JBoss
Cache in their projects. It
+ covers an overview of the concepts and API, configuration and deployment
information.
+ </para>
+ </partintro>
+ <xi:include href="introduction.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+<xi:include href="basic_api.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="configuration.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="batching.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="deployment.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="compatibility.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+
+ </part>
+
+ <part label="II">
+ <title>JBoss Cache Architecture</title>
+ <partintro>
+ <para>
+ This section digs deeper into the JBoss Cache architecture, and is meant for
developers wishing to use the more
+ advanced cache features,extend or enhance the cache, write plugins, or are
just looking for detailed knowledge
+ of how things work under the hood.
+ </para>
+ </partintro>
+<xi:include href="architecture.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="replication.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="cache_loaders.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="eviction_policies.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="transactions.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+
+ </part>
+
+ <part label="III">
+ <title>JBoss Cache Configuration References</title>
+ <partintro>
+ <para>
+ This section contains technical references for easy looking up.
+ </para>
+ </partintro>
+
+<xi:include href="configuration_reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+ <xi:include href="jmx_reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
+
+ </part>
+</book>
Property changes on:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/JBoss_Cache_User_Guide_CP01.xml
___________________________________________________________________
Name: svn:executable
+ *
Modified:
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Revision_History.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Revision_History.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/Revision_History.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -8,7 +8,7 @@
<revhistory>
<revision>
<revnumber>1.0</revnumber>
- <date>Thu Oct 22 2009</date>
+ <date>Tue Feb 09 2010</date>
<author>
<firstname>Laura</firstname>
<surname>Bailey</surname>
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/cache_loaders.xml
===================================================================
---
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/cache_loaders.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++
enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/cache_loaders.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -247,7 +247,7 @@
<note>
<title>Using the <literal>async</literal>
element</title>
- </para>
+ <para>
There is always the possibility of dirty reads since
all writes are performed asynchronously, and it is thus impossible to
guarantee when (and even if) a write succeeds. This needs to be kept in
Modified: enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/replication.xml
===================================================================
--- enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/replication.xml 2010-02-09
05:14:07 UTC (rev 8333)
+++ enterprise-docs/tags/JBoss_EAP_5_0_1/Cache_User_Guide/en-US/replication.xml 2010-02-09
05:15:57 UTC (rev 8334)
@@ -657,7 +657,7 @@
</orderedlist>
</section>
- <section>
+<!-- <section>
<title>Non-Blocking State Transfer</title>
<para>
New in JBoss Cache 3.1.0, Non-Blocking State Transfer (NBST) allows senders
to generate and stream state while
@@ -670,7 +670,7 @@
configuration reference), and you need to be using MVCC as a node locking
scheme. In addition, you need to
use JGroups' STREAMING_STATE_TRANSFER protocol in your cluster
properties.
</para>
- </section>
+ </section>-->
<section>
<title>Configuring State Transfer</title>