You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@avalon.apache.org by ha...@apache.org on 2002/04/02 20:54:17 UTC

cvs commit: jakarta-avalon-site/docs/phoenix making-phoenix-compatible-comps.html administrator-guide.html afuture.html assemblers-guide.html assembly-xml-specification.html block-developers-guide.html blockinfo-specification.html changes.html config-xml-specification.html creating-a-block.html creating-a-server-application.html deployers-guide.html environment-xml-specification.html example-configuration.html features.html getting-started.html index.html install.html todo.html what-is-a-block-listener.html what-is-a-block.html what-is-a-server-application.html what-is-an-application-listener.html

hammant     02/04/02 10:54:17

  Modified:    docs/phoenix administrator-guide.html afuture.html
                        assemblers-guide.html
                        assembly-xml-specification.html
                        block-developers-guide.html
                        blockinfo-specification.html changes.html
                        config-xml-specification.html creating-a-block.html
                        creating-a-server-application.html
                        deployers-guide.html
                        environment-xml-specification.html
                        example-configuration.html features.html
                        getting-started.html index.html install.html
                        todo.html what-is-a-block-listener.html
                        what-is-a-block.html
                        what-is-a-server-application.html
                        what-is-an-application-listener.html
  Added:       docs/phoenix making-phoenix-compatible-comps.html
  Log:
  new page and revised words for getting started
  
  Revision  Changes    Path
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/administrator-guide.html
  
  Index: administrator-guide.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/administrator-guide.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- administrator-guide.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ administrator-guide.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.3       +3 -0      jakarta-avalon-site/docs/phoenix/afuture.html
  
  Index: afuture.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/afuture.html,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- afuture.html	2 Apr 2002 17:21:25 -0000	1.2
  +++ afuture.html	2 Apr 2002 18:54:16 -0000	1.3
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/assemblers-guide.html
  
  Index: assemblers-guide.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/assemblers-guide.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- assemblers-guide.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ assemblers-guide.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/assembly-xml-specification.html
  
  Index: assembly-xml-specification.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/assembly-xml-specification.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- assembly-xml-specification.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ assembly-xml-specification.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/block-developers-guide.html
  
  Index: block-developers-guide.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/block-developers-guide.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- block-developers-guide.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ block-developers-guide.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/blockinfo-specification.html
  
  Index: blockinfo-specification.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/blockinfo-specification.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- blockinfo-specification.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ blockinfo-specification.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.6       +3 -0      jakarta-avalon-site/docs/phoenix/changes.html
  
  Index: changes.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/changes.html,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- changes.html	2 Apr 2002 14:42:32 -0000	1.5
  +++ changes.html	2 Apr 2002 18:54:16 -0000	1.6
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/config-xml-specification.html
  
  Index: config-xml-specification.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/config-xml-specification.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- config-xml-specification.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ config-xml-specification.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/creating-a-block.html
  
  Index: creating-a-block.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/creating-a-block.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- creating-a-block.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ creating-a-block.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/creating-a-server-application.html
  
  Index: creating-a-server-application.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/creating-a-server-application.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- creating-a-server-application.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ creating-a-server-application.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/deployers-guide.html
  
  Index: deployers-guide.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/deployers-guide.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- deployers-guide.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ deployers-guide.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.4       +3 -0      jakarta-avalon-site/docs/phoenix/environment-xml-specification.html
  
  Index: environment-xml-specification.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/environment-xml-specification.html,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- environment-xml-specification.html	2 Apr 2002 17:21:25 -0000	1.3
  +++ environment-xml-specification.html	2 Apr 2002 18:54:16 -0000	1.4
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.4       +3 -0      jakarta-avalon-site/docs/phoenix/example-configuration.html
  
  Index: example-configuration.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/example-configuration.html,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- example-configuration.html	2 Apr 2002 17:21:25 -0000	1.3
  +++ example-configuration.html	2 Apr 2002 18:54:16 -0000	1.4
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/features.html
  
  Index: features.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/features.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- features.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ features.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +132 -5    jakarta-avalon-site/docs/phoenix/getting-started.html
  
  Index: getting-started.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/getting-started.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- getting-started.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ getting-started.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  @@ -159,7 +162,7 @@
   </center>
   <br>
   <font size="-2" face="arial,helvetica,sanserif" color="#000000">
  -<p>by <a href="mailto:avalon-dev@jakarta.apache.org">Avalon Documentation Team</a>, <a href="mailto:email@leosimons.com">Leo Simons</a>
  +<p>by <a href="mailto:avalon-dev@jakarta.apache.org">Avalon Documentation Team</a>, <a href="mailto:email@leosimons.com">Leo Simons</a>, <a href="mailto:Paul_Hammant@yahoo.com">Paul Hammant</a>
   </p>
   </font><font face="arial,helvetica,sanserif" color="#000000"></font>
   <br>
  @@ -239,7 +242,7 @@
   <div align="right">
   <table cellspacing="0" cellpadding="2" border="0" width="100%">
   <tr>
  -<td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Run the examples</b></font></td>
  +<td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Run the HelloWorld example</b></font></td>
   </tr>
   <tr>
   <td><font face="arial,helvetica,sanserif" color="#000000">
  @@ -248,8 +251,18 @@
   
   <p align="justify">
       After you have successfully built Phoenix, you can verify that it 
  -    has compiled correctly by running the demo Service Application. To 
  -    do so, fire up phoenix with the following command:
  +    has compiled correctly by running the HelloWorld demo Service Application. 
  +</p>
  +
  +<p align="justify">   
  +    Firstly you will need to get the demo-helloword.sar file and drop it into
  +    the apps directory of Phoenix.  Get it from <a href="TODO">TODO</a> or build 
  +    it from its CVS - <a href="http://cvs.apache.org/viewcvs/jakarta-avalon-apps/demo/">
  +    http://cvs.apache.org/viewcvs/jakarta-avalon-apps/demo/</a>.
  +</p>
  +
  +<p align="justify">   
  +    Then fire up phoenix with the following command:
   
       <div align="center">
   <table cellspacing="2" cellpadding="2" border="1">
  @@ -281,7 +294,7 @@
   <pre>
   
       Hello World!
  -    Requests so far = 9
  +    Requests so far = 1
       you are 127.0.0.1 at 127.0.0.1
   
       </pre>
  @@ -292,6 +305,120 @@
   
   </p>
   
  +<p align="justify">   
  +    This shows that Phoenix has unpacked and launched the server application contained 
  +    within the demo-helloworld.sar file.  If you close and relaunch Phoenix, it should 
  +    restart the application.  
  +</p>
  +
  +<p align="justify">
  +    As examples go this is a fairly simple one.  You should ignore the altrmihelloworldserver, 
  +    rmihelloworldserver and soaphelloworldserver packages as they are retrofitting the 
  +    helloworld demo with remote capability using three technologies.  HelloWorld uses 
  +    connection management from the Avalon-Cornerstone project, which is good as it allows us to 
  +    share connection pooling across multiple servers.
  +</p>
  +
  +</font></td>
  +</tr>
  +</table>
  +</div>
  +<br>
  +<div align="right">
  +<table cellspacing="0" cellpadding="2" border="0" width="100%">
  +<tr>
  +<td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>The Phoenix Developer Kit - A different example</b></font></td>
  +</tr>
  +<tr>
  +<td><font face="arial,helvetica,sanserif" color="#000000">
  +<br>
  +
  +<p align="justify">
  +    This self contained kit could be considered a starter project for someone wanting to make a 
  +    Phoenix compatible application.  The idea is that you start with this skeleton including 
  +    Ant build script and then add in more and more as your se code to copy from elsewhere.  
  +</p>
  +
  +<p align="justify">    
  +    This  also demonstrates that it is possible to make a server application that is dual mode. 
  +    Dual mode to us is the ability for the server application to run inside Phoenix and to 
  +    stand-alone from the command line.  It is a little bit of a sleight of hand as the codebase 
  +    would be zipped into two forms - the sar file for phoenix and a jar file for standalone.
  +</p>
  +
  +<p align="justify">
  +    The Phoenix development kit originates in Phoenix's CVS, but for convenience is downloadable 
  +    from <a href="TODO">TODO</a>.  When you have that file, unzip it and immediately launch 
  +    ant to make the jars and sars.  There are four:
  +    <ol>
  +      
  +<li>phoenix-demo.sar - the server app in Phoenix form</li>
  +      
  +<li>phoenix-demo-block.sar - used inside the sar</li>
  +      
  +<li>phoenix-demo-client.sar - a client app to test the server</li>
  +      
  +<li>phoenix-demo-server.sar - the server app in standalone form</li>
  +    
  +</ol>
  +
  +    The Server app in standalone mode after being tested with the client app(see below):
  +  
  +    <div align="center">
  +<table cellspacing="2" cellpadding="2" border="1">
  +<tr>
  +<td>
  +<pre>
  +java -jar phoenix-demo-server.jar
  +PDK Demo listening on port 7654
  +Ctrl-C to exit
  +String passed = Hello!!!!!
  +    </pre>
  +</td>
  +</tr>
  +</table>
  +</div>
  +    
  +    The Server app running inside Phoenix and after being tested with the client app (see below):
  +    
  +    <div align="center">
  +<table cellspacing="2" cellpadding="2" border="1">
  +<tr>
  +<td>
  +<pre>
  +Phoenix 4.0a4
  +
  +Server started on port 1234    
  +String passed = Hello!!!!!
  +    </pre>
  +</td>
  +</tr>
  +</table>
  +</div>
  +    
  +    The client application being used to poke the server :
  +    
  +    <div align="center">
  +<table cellspacing="2" cellpadding="2" border="1">
  +<tr>
  +<td>
  +<pre>
  +java -jar phoenix-demo-client.jar localhost 7654 Hello!!!!!
  +    </pre>
  +</td>
  +</tr>
  +</table>
  +</div>
  +    
  +    (Change the port to 1234 from 7654 to poke the in-Phoenix server).
  +    
  +</p>    
  +
  +<p align="justify">
  +    Note - because of the need to make this dual mode, the PDK does not use Cornerstone 
  +    components.  We normally recommend that people should reuse components from cornerstone as 
  +    the potential for sharing will be much higher.
  +</p>
   
   </font></td>
   </tr>
  
  
  
  1.8       +3 -0      jakarta-avalon-site/docs/phoenix/index.html
  
  Index: index.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/index.html,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- index.html	2 Apr 2002 17:21:25 -0000	1.7
  +++ index.html	2 Apr 2002 18:54:16 -0000	1.8
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/install.html
  
  Index: install.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/install.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- install.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ install.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/todo.html
  
  Index: todo.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/todo.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- todo.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ todo.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.4       +3 -0      jakarta-avalon-site/docs/phoenix/what-is-a-block-listener.html
  
  Index: what-is-a-block-listener.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/what-is-a-block-listener.html,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- what-is-a-block-listener.html	2 Apr 2002 17:21:25 -0000	1.3
  +++ what-is-a-block-listener.html	2 Apr 2002 18:54:16 -0000	1.4
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/what-is-a-block.html
  
  Index: what-is-a-block.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/what-is-a-block.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- what-is-a-block.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ what-is-a-block.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.7       +3 -0      jakarta-avalon-site/docs/phoenix/what-is-a-server-application.html
  
  Index: what-is-a-server-application.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/what-is-a-server-application.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- what-is-a-server-application.html	2 Apr 2002 17:21:25 -0000	1.6
  +++ what-is-a-server-application.html	2 Apr 2002 18:54:16 -0000	1.7
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.3       +3 -0      jakarta-avalon-site/docs/phoenix/what-is-an-application-listener.html
  
  Index: what-is-an-application-listener.html
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-site/docs/phoenix/what-is-an-application-listener.html,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- what-is-an-application-listener.html	2 Apr 2002 17:21:25 -0000	1.2
  +++ what-is-an-application-listener.html	2 Apr 2002 18:54:16 -0000	1.3
  @@ -41,6 +41,9 @@
   <a href="getting-started.html"><font size="-1">Getting Started</font></a>
   </li>
   <li>
  +<a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  +</li>
  +<li>
   <a href="install.html"><font size="-1">Installation</font></a>
   </li>
   <li>
  
  
  
  1.1                  jakarta-avalon-site/docs/phoenix/making-phoenix-compatible-comps.html
  
  Index: making-phoenix-compatible-comps.html
  ===================================================================
  <html>
  <head>
  <META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
  <title>Phoenix - Making components that are Phoenix compatible</title>
  </head>
  <body bgcolor="#ffffff" marginheight="4" marginwidth="4" leftmargin="4" topmargin="4" alink="#023264" vlink="#023264" link="#525D76" text="#000000">
  <table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
  <td align="left" valign="top"><a href="http://jakarta.apache.org/index.html"><img src="images/jakarta-logo.gif" border="0" vspace="0" hspace="0"></a></td><td bgcolor="#ffffff" align="left" valign="top" width="100%"><img src="images/header.gif" align="right" border="0" vspace="0" hspace="0"></td>
  </tr>
  <tr>
  <td colspan="2" height="2" width="100%">
  <hr size="1" noshade="">
  </td>
  </tr>
  </table>
  <table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
  <td valign="top" width="1%"></td><td nowrap="1" valign="top" width="14%">
  <br>
  <font face="arial,helvetica,sanserif">
  <br>
  <br>
  <a href="http://jakarta.apache.org/avalon"><font size="+1" color="#778899">Back to Avalon</font></a>
  <br>
  <br>
  <font size="+1" color="#000000">About</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="index.html"><font size="-1">Overview</font></a>
  </li>
  <li>
  <a href="features.html"><font size="-1">Features</font></a>
  </li>
  <li>
  <a href="http://jakarta.apache.org/builds/jakarta-avalon/release/phoenix"><font size="-1">Download</font></a>
  </li>
  <li>
  <a href="getting-started.html"><font size="-1">Getting Started</font></a>
  </li>
  <li>
  <a href="making-phoenix-compatible-comps.html"><font size="-1">Making compatible components</font></a>
  </li>
  <li>
  <a href="install.html"><font size="-1">Installation</font></a>
  </li>
  <li>
  <a href="afuture.html"><font size="-1">A Future</font></a>
  </li>
  <li>
  <a href="todo.html"><font size="-1">Todo</font></a>
  </li>
  <li>
  <a href="changes.html"><font size="-1">Changes</font></a>
  </li>
  <li>
  <a href="api/index.html.xml"><font size="-1">API Docs</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  <font size="+1" color="#000000">Administrators Guide</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="administrator-guide.html"><font size="-1">Overview</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  <font size="+1" color="#000000">Deployers Guide</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="deployers-guide.html"><font size="-1">Overview</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  <font size="+1" color="#000000">Assembler's Guide</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="assemblers-guide.html"><font size="-1">Overview</font></a>
  </li>
  <li>
  <a href="what-is-a-server-application.html"><font size="-1">What is a Server Application?</font></a>
  </li>
  <li>
  <a href="creating-a-server-application.html"><font size="-1">Creating a Server Application</font></a>
  </li>
  <li>
  <a href="config-xml-specification.html"><font size="-1">config.xml Specification</font></a>
  </li>
  <li>
  <a href="assembly-xml-specification.html"><font size="-1">assembly.xml Specification</font></a>
  </li>
  <li>
  <a href="environment-xml-specification.html"><font size="-1">environment.xml Specification</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  <font size="+1" color="#000000">Block Developer's Guide</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="block-developers-guide.html"><font size="-1">Overview</font></a>
  </li>
  <li>
  <a href="what-is-a-block.html"><font size="-1">What is a Block?</font></a>
  </li>
  <li>
  <a href="what-is-a-block-listener.html"><font size="-1">What is a Block Listener?</font></a>
  </li>
  <li>
  <a href="what-is-an-application-listener.html"><font size="-1">What is an Application Listener?</font></a>
  </li>
  <li>
  <a href="blockinfo-specification.html"><font size="-1">BlockInfo Specification</font></a>
  </li>
  <li>
  <a href="creating-a-block.html"><font size="-1">Creating a Block</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  <font size="+1" color="#000000">All together</font>
  <br>
  <font size="-1">
  <ul>
  <li>
  <a href="example-configuration.html"><font size="-1">Example configuration</font></a>
  </li>
  </ul>
  </font>
  <br>
  <br>
  </font></td><td align="left" valign="top" width="*">
  <title>Phoenix - Making components that are Phoenix compatible</title>
  <center>
  <table width="100%">
  <tr>
  <td bgcolor="#99aabb">
  <center>
  <b><font face="arial,helvetica,sanserif" color="#000000" size="+2">Phoenix - Making components that are Phoenix compatible</font></b>
  </center>
  </td>
  </tr>
  </table>
  </center>
  <br>
  <font size="-2" face="arial,helvetica,sanserif" color="#000000">
  <p>by <a href="mailto:hammant@apache.org">Paul Hammant</a>
  </p>
  </font><font face="arial,helvetica,sanserif" color="#000000"></font>
  <br>
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="100%">
  <tr>
  <td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Introduction</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
        
  <p align="justify">
        Quite often reusable components are made elsewhere.  Apache has a number 
        of places where this activity is going on.  While we get it right most of
        the time, some components developer elsewhere are harder to use in Phoenix
        </p>
      
  </font></td>
  </tr>
  </table>
  </div>
  <br>
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="100%">
  <tr>
  <td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Things to remember</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
        
  <p align="justify">
          There are a number of common sense things to remember when making or 
          adapting a Java component to be reusable in Phoenix as block.
        </p>
        
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="99%">
  <tr>
  <td bgcolor="ddeeff"><font face="arial,helvetica,sanserif" color="#000000" size="+0"><b>Beanification</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>      
          
  <p align="justify">
            
  <ul>
              
  <li>Have a public empty constructor for your main class</li>
              
  <li>Have setters for its configuration.</li>
              
  <li>Do not assume that the File is where dependancies are - people may reuse this in jars, applets etc.</li>
              
  <li>Divorce your main method (if appl) from your main class - Phoenix does not call main methods.</li>            
              
  <li>Consider that the setup and initialization of the bean does not happen in the 
                  constructor - as a convenience to the user, have an initialize() method</li>            
              
  <li>If the comp has start/stop functinality consider having start() and stop() methods.</li>  
              
  <li>Try to avoid Singleton concepts.  There could be multiple blocks in one sar using differnt (by design) instances of your bean</li>
            
  </ul>
          
  </p>
        
  </font></td>
  </tr>
  </table>
  </div>
  <br>              
        
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="99%">
  <tr>
  <td bgcolor="ddeeff"><font face="arial,helvetica,sanserif" color="#000000" size="+0"><b>Inversion of Control Pattern</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
           The IoC pattern is described <a href="http://jakarta.apache.org/avalon/framework/inversion-of-control.html">
           here</a>.  This means for Phoenix avoiding static concepts including loggers.
        </font></td>
  </tr>
  </table>
  </div>
  <br>
        
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="99%">
  <tr>
  <td bgcolor="ddeeff"><font face="arial,helvetica,sanserif" color="#000000" size="+0"><b>Sepearation of interface and implementation</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
          
  <p align="justify">
           The separation of interface/impl pattern is described <a href="http://jakarta.apache.org/avalon/framework/separation-of-interface-and-implementation.html">here</a>.  
           For Phoenix is means we can (if done completely) mount the implementation jar in place where hosted client compoennts (beans, servlets etc) can use the API, bit not see the implementation.  We can also reimplement or wrap 
           bits of the implementation.  For example we could write a pluggable implementation that could, for a certain API 
           journal some methods, but still delegate to the real impl.  Which pluggable impl is used by Phoenix when it 
           boots is determined in assembly.xml of course.
          </p>
        
  </font></td>
  </tr>
  </table>
  </div>
  <br>
        
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="99%">
  <tr>
  <td bgcolor="ddeeff"><font face="arial,helvetica,sanserif" color="#000000" size="+0"><b>Opening up the API</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
          
  <p align="justify">
           Given that you have divided into interface and impl, there are probably plenty of methods you 
           can put method in the interface you never though might be used.  For example if you are making JDBC 
           compliant relational database, and it is a bean, you could easily think that the only use would be 
           clients via JDBC over sockets.  Well, given that Phoenix can now mount the RDBMS block, it might want 
           to be reused by other blocks that other people have developed inside the the same SAR file.  In that case
           have beanlike methods of ...
          <ol>
            
  <li>Database createDatabase(String name)</li>
            
  <li>Database cloneDatabase(String name)</li>      
          
  </ol>         
          .. might be useful.  Just because you can only see a ServerSocket interface does not mean that others do.
          </p>
        
  </font></td>
  </tr>
  </table>
  </div>
  <br> 
      
  </font></td>
  </tr>
  </table>
  </div>
  <br>
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="100%">
  <tr>
  <td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Example compatible comp</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>
      
  <p align="justify">
        Below are an interface and implemmentation that are suitably separated, are beanlike and is in accordance 
        with the IoC pattern...
  <div align="center">
  <table cellspacing="2" cellpadding="2" border="1">
  <tr>
  <td>
  <pre>
  package examplecomp;
  public interface StockQuoteService {
      Quote getQuote(String symbol);
  }
  
  package examplecomp;
  public class Quote {
     public final BigDecimal ...
     public Quote(...);
     public BigDecimal getXXX() {
         ...
     }
  }
  
  package examplecomp.impl;
  public class DefaultStockQuoteService implements StockQuoteService {
  
      public DefaultStockQuoteService() {
          // whatever.
      }
      public void setConfiguration(Properties props) {
          // not very beanlike but OK for reuse.    
      }
      public void initialize() {
          // whatever.
      }
      public Quote getQuote(String symbol) {
          // whatever.
          return new Quote(...);
      }
  }
  </pre>
  </td>
  </tr>
  </table>
  </div>      
        The interface is from the clients reuse point of view. The setConfiguration(..) and intialize(..) 
        are something that the container will do after instantiating the bean abd are implementation specific.  
        This is the IoC pattern at work - the bean is instantiated then decorated with additonal stuff 
        until it is instructed to go.
      </p>
      
  </font></td>
  </tr>
  </table>
  </div>
  <br>
  <div align="right">
  <table cellspacing="0" cellpadding="2" border="0" width="100%">
  <tr>
  <td bgcolor="bbccdd"><font face="arial,helvetica,sanserif" color="#000000" size="+1"><b>Misconceptions</b></font></td>
  </tr>
  <tr>
  <td><font face="arial,helvetica,sanserif" color="#000000">
  <br>    
        
  <p align="justify">
          The following are worth stating:
          <ul>
            
  <li>You do not have to implement any Avalon interfaces to be reusable inside Avalon.</li>
            
  <li>Being Phoenix compatible is just as useful for whole servers as it is for small components.</li>
            
  <li>Being Phoenix compatible can be for tools that are intended for client-side as well as server use.</li>
          
  </ul>
        
  </p>    
      
  </font></td>
  </tr>
  </table>
  </div>
  <br>
  </td>
  </tr>
  </table>
  <br>
  <table cellpadding="0" cellspacing="0" border="0" width="100%">
  <tr>
  <td>
  <hr size="1" noshade="">
  </td>
  </tr>
  <tr>
  <td align="center"><font color="#525D76" size="-1" face="arial,helvetica,sanserif"><i>
                Copyright &copy;1999-2002 by the Apache Software Foundation.
                All Rights Reserved.
              </i></font></td>
  </tr>
  </table>
  </body>
  </html>
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>