Return-Path: X-Original-To: apmail-cayenne-commits-archive@www.apache.org Delivered-To: apmail-cayenne-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B3163D2F2 for ; Wed, 26 Dec 2012 18:38:56 +0000 (UTC) Received: (qmail 50386 invoked by uid 500); 26 Dec 2012 18:38:56 -0000 Delivered-To: apmail-cayenne-commits-archive@cayenne.apache.org Received: (qmail 50352 invoked by uid 500); 26 Dec 2012 18:38:56 -0000 Mailing-List: contact commits-help@cayenne.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cayenne.apache.org Delivered-To: mailing list commits@cayenne.apache.org Received: (qmail 50336 invoked by uid 99); 26 Dec 2012 18:38:56 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Dec 2012 18:38:56 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Dec 2012 18:38:42 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id E35102388A4A; Wed, 26 Dec 2012 18:38:19 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1425988 [4/4] - in /cayenne/main/branches/STABLE-3.1/docs/docbook: cayenne-guide/src/docbkx/ getting-started-rop/src/docbkx/ getting-started/src/docbkx/ stylesheets/ Date: Wed, 26 Dec 2012 18:38:18 -0000 To: commits@cayenne.apache.org From: aadamchik@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20121226183819.E35102388A4A@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/cayenne-guide/src/docbkx/starting-cayenne.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/cayenne-guide/src/docbkx/starting-cayenne.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/cayenne-guide/src/docbkx/starting-cayenne.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/cayenne-guide/src/docbkx/starting-cayenne.xml Wed Dec 26 18:38:17 2012 @@ -1,146 +1,146 @@ - Starting Cayenne -
- Starting and Stopping ServerRuntime - In runtime Cayenne is accessed via - org.apache.cayenne.configuration.server.ServerRuntime. ServerRuntime is - created simply by calling a - constructor:ServerRuntime runtime = - new ServerRuntime("com/example/cayenne-project.xml"); - The parameter you pass to the constructor is a location of the main project file. Location - is a '/'-separated path (same path separator is used on UNIX and Windows) that is - resolved relative to the application classpath. The project file can be placed in the - root package or in a subpackage (e.g. in the code above it is in "com/example" - subpackage). - ServerRuntime encapsulates a single Cayenne stack. Most applications will just have one - ServerRuntime using it to create as many ObjectContexts as needed, access the Dependency - Injection (DI) container and work with other Cayenne features. Internally ServerRuntime - is just a thin wrapper around the DI container. Detailed features of the container are - discussed in "Customizing Cayenne Runtime" chapter. Here we'll just show an example of - how an application might replace a default implementation of a built-in Cayenne service - (in this case - QueryCache) with a different - class:public class MyExtensionsModule implements Module { - public void configure(Binder binder) { - binder.bind(QueryCache.class).to(EhCacheQueryCache.class); - } + version="5.0" xml:id="starting-cayenne"> + Starting Cayenne +
+ Starting and Stopping ServerRuntime + In runtime Cayenne is accessed via + org.apache.cayenne.configuration.server.ServerRuntime. ServerRuntime is + created simply by calling a + constructor:ServerRuntime runtime = + new ServerRuntime("com/example/cayenne-project.xml"); + The parameter you pass to the constructor is a location of the main project file. Location + is a '/'-separated path (same path separator is used on UNIX and Windows) that is + resolved relative to the application classpath. The project file can be placed in the + root package or in a subpackage (e.g. in the code above it is in "com/example" + subpackage). + ServerRuntime encapsulates a single Cayenne stack. Most applications will just have one + ServerRuntime using it to create as many ObjectContexts as needed, access the Dependency + Injection (DI) container and work with other Cayenne features. Internally ServerRuntime + is just a thin wrapper around the DI container. Detailed features of the container are + discussed in "Customizing Cayenne Runtime" chapter. Here we'll just show an example of + how an application might replace a default implementation of a built-in Cayenne service + (in this case - QueryCache) with a different + class:public class MyExtensionsModule implements Module { + public void configure(Binder binder) { + binder.bind(QueryCache.class).to(EhCacheQueryCache.class); + } }Module extensions = new MyExtensionsModule(); ServerRuntime runtime = - new ServerRuntime("com/example/cayenne-project.xml", extensions); - It is a good idea to shut down the runtime when it is no longer needed, usually before the - application itself is shutdown: runtime.shutdown();When - a runtime object has the same scope as the application, this may not be always - necessary, however in some cases it is essential, and is generally considered a good - practice. E.g. in a web container hot redeploy of a webapp will cause resource leaks and - eventual OutOfMemoryError if the application fails to shutdown CayenneRuntime. -
-
- Merging Multiple Projects - ServerRuntime requires at least one mapping project to run. But it can also take multiple - projects and merge them together in a single configuration. This way different parts of - a database can be mapped independenlty from each other (even by different software - providers), and combined in runtime when assembling an application. Doing it is as easy - as passing multiple project locations to ServerRuntime constructor:ServerRuntime runtime = - new ServerRuntime(new String[] { - "com/example/cayenne-project.xml", - "org/foo/cayenne-library1.xml", - "org/foo/cayenne-library2.xml" - } + new ServerRuntime("com/example/cayenne-project.xml", extensions); + It is a good idea to shut down the runtime when it is no longer needed, usually before the + application itself is shutdown: runtime.shutdown();When + a runtime object has the same scope as the application, this may not be always + necessary, however in some cases it is essential, and is generally considered a good + practice. E.g. in a web container hot redeploy of a webapp will cause resource leaks and + eventual OutOfMemoryError if the application fails to shutdown CayenneRuntime. +
+
+ Merging Multiple Projects + ServerRuntime requires at least one mapping project to run. But it can also take multiple + projects and merge them together in a single configuration. This way different parts of + a database can be mapped independenlty from each other (even by different software + providers), and combined in runtime when assembling an application. Doing it is as easy + as passing multiple project locations to ServerRuntime constructor:ServerRuntime runtime = + new ServerRuntime(new String[] { + "com/example/cayenne-project.xml", + "org/foo/cayenne-library1.xml", + "org/foo/cayenne-library2.xml" + } ); - When the projects are merged, the following rules are applied: - - The order of projects matters during merge. If there are two conflicting - metadata objects belonging to two projects, an object from the last project takes precedence over the object - from the first one. This makes possible to override pieces of metadata. This - is also similar to how DI modules are merged in Cayenne. - - - Runtime DataDomain name is set to the name of the last project in the - list. - - - Runtime DataDomain properties are the same as the properties of the last - project in the list. I.e. properties are not - merged to avoid invalid combinations and unexpected runtime - behavior. - - - If there are two or more DataMaps with the same name, only one DataMap is - used in the merged project, the rest are discarded. Same precedence rules - apply - DataMap from the project with the highest index in the project list - overrides all other DataMaps with the same name. - - - If there are two or more DataNodes with the same name, only one DataNodes - is used in the merged project, the rest are discarded. DataNode coming from - project with the highest index in the project list is chosen per precedence - rule above. - - - There is a notion of "default" DataNode. After the merge if any DataMaps - are not explicitly linked to DataNodes, their queries will be executed via a - default DataNode. This makes it possible to build mapping "libraries" that - are only associated with a specific database in runtime. If there's only one - DataNode in the merged project, it will be automatically chosen as default. - A possible way to explicitly designate a specific node as default is to - override DataDomainProvider.createAndInitDataDomain(). - - -
-
- Web Applications - Web applications can use a variety of mechanisms to configure and start the "services" - they need, Cayenne being one of such services. Configuration can be done within standard - Servlet specification objects like Servlets, Filters, or ServletContextListeners, or can - use Spring, JEE CDI, etc. This is a user's architectural choice and Cayenne is agnostic - to it and will happily work in any environment. As described above, all that is needed - is to create an instance of ServerRuntime somewhere and provide the application code - with means to access it. And shut it down when the application ends to avoid container - leaks. - Still Cayenne includes a piece of web app configuration code that can assist in - quickly setting up simple Cayenne-enabled web applications. We are talking about - CayenneFilter. It is declared in - web.xml:<web-app> - ... - <filter> - <filter-name>cayenne-project</filter-name> - <filter-class>org.apache.cayenne.configuration.web.CayenneFilter</filter-class> + When the projects are merged, the following rules are applied: + + The order of projects matters during merge. If there are two conflicting + metadata objects belonging to two projects, an object from the last project takes precedence over the object + from the first one. This makes possible to override pieces of metadata. This + is also similar to how DI modules are merged in Cayenne. + + + Runtime DataDomain name is set to the name of the last project in the + list. + + + Runtime DataDomain properties are the same as the properties of the last + project in the list. I.e. properties are not + merged to avoid invalid combinations and unexpected runtime + behavior. + + + If there are two or more DataMaps with the same name, only one DataMap is + used in the merged project, the rest are discarded. Same precedence rules + apply - DataMap from the project with the highest index in the project list + overrides all other DataMaps with the same name. + + + If there are two or more DataNodes with the same name, only one DataNodes + is used in the merged project, the rest are discarded. DataNode coming from + project with the highest index in the project list is chosen per precedence + rule above. + + + There is a notion of "default" DataNode. After the merge if any DataMaps + are not explicitly linked to DataNodes, their queries will be executed via a + default DataNode. This makes it possible to build mapping "libraries" that + are only associated with a specific database in runtime. If there's only one + DataNode in the merged project, it will be automatically chosen as default. + A possible way to explicitly designate a specific node as default is to + override DataDomainProvider.createAndInitDataDomain(). + + +
+
+ Web Applications + Web applications can use a variety of mechanisms to configure and start the "services" + they need, Cayenne being one of such services. Configuration can be done within standard + Servlet specification objects like Servlets, Filters, or ServletContextListeners, or can + use Spring, JEE CDI, etc. This is a user's architectural choice and Cayenne is agnostic + to it and will happily work in any environment. As described above, all that is needed + is to create an instance of ServerRuntime somewhere and provide the application code + with means to access it. And shut it down when the application ends to avoid container + leaks. + Still Cayenne includes a piece of web app configuration code that can assist in + quickly setting up simple Cayenne-enabled web applications. We are talking about + CayenneFilter. It is declared in + web.xml:<web-app> + ... + <filter> + <filter-name>cayenne-project</filter-name> + <filter-class>org.apache.cayenne.configuration.web.CayenneFilter</filter-class> </filter> <filter-mapping> <filter-name>cayenne-project</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> - ... + ... </web-app> - When started by the web container, it creates a instance of ServerRuntime and stores - it in the ServletContext. Note that the name of Cayenne XML project file is derived from - the "filter-name". In the example above CayenneFilter will look for an XML file - "cayenne-project.xml". This can be overridden with "configuration-location" init - parameter. - When the application runs, all HTTP requests matching the filter url-pattern will have - access to a session-scoped ObjectContext like - this:ObjectContext context = BaseContext.getThreadObjectContext();Of - course the ObjectContext scope, and other behavior of the Cayenne runtime can be - customized via dependency injection. For this another filter init parameter called - "extra-modules" is used. "extra-modules" is a comma or space-separated list of class - names, with each class implementing Module interface. These optional custom modules are - loaded after the the standard ones, which allows users to override all standard - definitions. - For those interested in the DI container contents of the runtime created by CayenneFilter, - it is the same ServerRuntime as would've been created by other means, but with an extra - org.apache.cayenne.configuration.web.WebModule module that provides - org.apache.cayenne.configuration.web.RequestHandler service. This is - the service to override in the custom modules if you need to provide a different - ObjectContext scope, etc. - - - You should not think of CayenneFilter as the only way to start and use Cayenne in a web - application. In fact CayenneFilter is entirely optional. Use it if you don't - have any special design for application service management. If you do, simply - integrate Cayenne into that design. - - -
+ When started by the web container, it creates a instance of ServerRuntime and stores + it in the ServletContext. Note that the name of Cayenne XML project file is derived from + the "filter-name". In the example above CayenneFilter will look for an XML file + "cayenne-project.xml". This can be overridden with "configuration-location" init + parameter. + When the application runs, all HTTP requests matching the filter url-pattern will have + access to a session-scoped ObjectContext like + this:ObjectContext context = BaseContext.getThreadObjectContext();Of + course the ObjectContext scope, and other behavior of the Cayenne runtime can be + customized via dependency injection. For this another filter init parameter called + "extra-modules" is used. "extra-modules" is a comma or space-separated list of class + names, with each class implementing Module interface. These optional custom modules are + loaded after the the standard ones, which allows users to override all standard + definitions. + For those interested in the DI container contents of the runtime created by CayenneFilter, + it is the same ServerRuntime as would've been created by other means, but with an extra + org.apache.cayenne.configuration.web.WebModule module that provides + org.apache.cayenne.configuration.web.RequestHandler service. This is + the service to override in the custom modules if you need to provide a different + ObjectContext scope, etc. + + + You should not think of CayenneFilter as the only way to start and use Cayenne in a web + application. In fact CayenneFilter is entirely optional. Use it if you don't + have any special design for application service management. If you do, simply + integrate Cayenne into that design. + + +
Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/authentification.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/authentification.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/authentification.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/authentification.xml Wed Dec 26 18:38:17 2012 @@ -26,7 +26,7 @@ <auth-method>BASIC</auth-method> <realm-name>Cayenne Realm</realm-name> </login-config> - + <security-role> <role-name>cayenne-service-user</role-name> </security-role> @@ -54,20 +54,20 @@ Open pom.xml in the server project and configure a "userRealm" for the Jetty plugin: <plugin> - <groupId>org.mortbay.jetty</groupId> - <artifactId>maven-jetty-plugin</artifactId> - <version>6.1.22</version> - <!-- adding configuration below: --> - <configuration> - <userRealms> - <userRealm implementation="org.mortbay.jetty.security.HashUserRealm"> - <!-- this name must match the realm-name in web.xml --> - <name>Cayenne Realm</name> - <config>realm.properties</config> - </userRealm> - </userRealms> - </configuration> - </plugin> + <groupId>org.mortbay.jetty</groupId> + <artifactId>maven-jetty-plugin</artifactId> + <version>6.1.22</version> + <!-- adding configuration below: --> + <configuration> + <userRealms> + <userRealm implementation="org.mortbay.jetty.security.HashUserRealm"> + <!-- this name must match the realm-name in web.xml --> + <name>Cayenne Realm</name> + <config>realm.properties</config> + </userRealm> + </userRealms> + </configuration> + </plugin> </plugins> Now create a new file called {["realm.properties"}} at the root of the server project and put user login/password in there: @@ -89,30 +89,30 @@ org.apache.cayenne.remote.hessian.Hessia INFO: Error establishing remote session. URL - http://localhost:8080/tutorial/cayenne-service; CAUSE - cannot retry due to server authentication, in streaming mode java.net.HttpRetryException: cannot retry due to server authentication, in streaming mode - at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1257) - at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) - at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:168) - at $Proxy0.establishSession(Unknown Source) - at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:210) - at org.apache.cayenne.remote.hessian.HessianConnection.getServerEventBridge(HessianConnection.java:114) - at org.apache.cayenne.remote.ClientChannel.setupRemoteChannelListener(ClientChannel.java:337) - at org.apache.cayenne.remote.ClientChannel.<init>(ClientChannel.java:108) - at org.example.cayenne.Main.main(Main.java:25) + at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1257) + at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) + at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:168) + at $Proxy0.establishSession(Unknown Source) + at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:210) + at org.apache.cayenne.remote.hessian.HessianConnection.getServerEventBridge(HessianConnection.java:114) + at org.apache.cayenne.remote.ClientChannel.setupRemoteChannelListener(ClientChannel.java:337) + at org.apache.cayenne.remote.ClientChannel.<init>(ClientChannel.java:108) + at org.example.cayenne.Main.main(Main.java:25) Exception in thread "main" org.apache.cayenne.CayenneRuntimeException: [v.3.1M3 Sep 19 2011 07:12:41] Error establishing remote session. URL - http://localhost:8080/tutorial/cayenne-service; CAUSE - cannot retry due to server authentication, in streaming mode - at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:229) - at org.apache.cayenne.remote.hessian.HessianConnection.getServerEventBridge(HessianConnection.java:114) - at org.apache.cayenne.remote.ClientChannel.setupRemoteChannelListener(ClientChannel.java:337) - at org.apache.cayenne.remote.ClientChannel.<init>(ClientChannel.java:108) - at org.example.cayenne.Main.main(Main.java:25) + at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:229) + at org.apache.cayenne.remote.hessian.HessianConnection.getServerEventBridge(HessianConnection.java:114) + at org.apache.cayenne.remote.ClientChannel.setupRemoteChannelListener(ClientChannel.java:337) + at org.apache.cayenne.remote.ClientChannel.<init>(ClientChannel.java:108) + at org.example.cayenne.Main.main(Main.java:25) Caused by: java.net.HttpRetryException: cannot retry due to server authentication, in streaming mode - at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1257) - at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) - at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:168) - at $Proxy0.establishSession(Unknown Source) - at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:210) - ... 4 more + at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1257) + at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) + at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:168) + at $Proxy0.establishSession(Unknown Source) + at org.apache.cayenne.remote.hessian.HessianConnection.connect(HessianConnection.java:210) + ... 4 more Which is exactly what you'd expect, as the client is not authenticating itself. So change the line in Main.java where we obtained an ROP connection to this: ClientConnection connection = new HessianConnection( Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/web-service.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/web-service.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/web-service.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started-rop/src/docbkx/web-service.xml Wed Dec 26 18:38:17 2012 @@ -7,36 +7,36 @@ Now lets get back to the "tutorial" project that contains a web application and set up dependencies. The only extra one that we don't have yet is resin-hessian.jar, just like the client, so let's add it (and the caucho repo declaration) to the pom.xml. - <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> - ... - <dependencies> - ... - <dependency> - <groupId>com.caucho</groupId> - <artifactId>resin-hessian</artifactId> - <version>3.1.6</version> - </dependency> - </dependencies> + ... + <dependencies> + ... + <dependency> + <groupId>com.caucho</groupId> + <artifactId>resin-hessian</artifactId> + <version>3.1.6</version> + </dependency> + </dependencies> - <build> - ... - </build> - - <repositories> - <repository> - <id>caucho</id> - <name>Caucho Repository</name> - <url>http://caucho.com/m2</url> - <layout>default</layout> - <snapshots> - <enabled>false</enabled> - </snapshots> - <releases> - <enabled>true</enabled> - </releases> - </repository> - </repositories> + <build> + ... + </build> + + <repositories> + <repository> + <id>caucho</id> + <name>Caucho Repository</name> + <url>http://caucho.com/m2</url> + <layout>default</layout> + <snapshots> + <enabled>false</enabled> + </snapshots> + <releases> + <enabled>true</enabled> + </releases> + </repository> + </repositories> </project> @@ -77,16 +77,16 @@ PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> <web-app> - <display-name>Cayenne Tutorial</display-name> - <servlet> - <servlet-name>cayenne-project</servlet-name> - <servlet-class>org.apache.cayenne.configuration.rop.server.ROPHessianServlet</servlet-class> + <display-name>Cayenne Tutorial</display-name> + <servlet> + <servlet-name>cayenne-project</servlet-name> + <servlet-class>org.apache.cayenne.configuration.rop.server.ROPHessianServlet</servlet-class> <load-on-startup>0</load-on-startup> - </servlet> - <servlet-mapping> - <servlet-name>cayenne-project</servlet-name> - <url-pattern>/cayenne-service</url-pattern> - </servlet-mapping> + </servlet> + <servlet-mapping> + <servlet-name>cayenne-project</servlet-name> + <url-pattern>/cayenne-service</url-pattern> + </servlet-mapping> </web-app> @@ -130,9 +130,9 @@ INFO::Started SelectChannelConnector@0.0 INFO: Loading XML configuration resource from file:cayenne-project.xml INFO: loading user name and password. INFO: Created connection pool: jdbc:derby:memory:testdb;create=true - Driver class: org.apache.derby.jdbc.EmbeddedDriver - Min. connections in the pool: 1 - Max. connections in the pool: 1 + Driver class: org.apache.derby.jdbc.EmbeddedDriver + Min. connections in the pool: 1 + Max. connections in the pool: 1 Cayenne ROP service URL is http://localhost:8080/tutorial/cayenne-service. If you click on it, you will see "Hessian Requires POST" message, that means that the service is alive, but you Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/java-classes.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/java-classes.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/java-classes.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/java-classes.xml Wed Dec 26 18:38:17 2012 @@ -38,21 +38,21 @@ This is because our project does not include Cayenne as a Maven dependency yet. Let's fix it now by adding "cayenne-server" artifact in the bottom of the pom.xml file. The resulting POM should look like - this:<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + this:<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>org.example.cayenne</groupId> - <artifactId>tutorial</artifactId> - <version>0.0.1-SNAPSHOT</version> + <modelVersion>4.0.0</modelVersion> + <groupId>org.example.cayenne</groupId> + <artifactId>tutorial</artifactId> + <version>0.0.1-SNAPSHOT</version> - <dependencies> - <dependency> - <groupId>org.apache.cayenne</groupId> - <artifactId>cayenne-server</artifactId> + <dependencies> + <dependency> + <groupId>org.apache.cayenne</groupId> + <artifactId>cayenne-server</artifactId> <!-- Here specify the version of Cayenne you are actually using --> - <version>3.1M3</version> - </dependency> - </dependencies> + <version>3.1M3</version> + </dependency> + </dependencies> </project> Your computer must be connected to the internet. Once you save the pom.xml, Eclipse will download the needed Cayenne jar file and add it to the project build path. As a Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/object-context.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/object-context.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/object-context.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/object-context.xml Wed Dec 26 18:38:17 2012 @@ -66,9 +66,9 @@ public class Main { started:INFO: Loading XML configuration resource from file:cayenne-project.xml INFO: loading user name and password. INFO: Created connection pool: jdbc:derby:memory:testdb;create=true - Driver class: org.apache.derby.jdbc.EmbeddedDriver - Min. connections in the pool: 1 - Max. connections in the pool: 1 Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/persistent-objects.xml URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/persistent-objects.xml?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/persistent-objects.xml (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/getting-started/src/docbkx/persistent-objects.xml Wed Dec 26 18:38:17 2012 @@ -91,8 +91,8 @@ stein.setGallery(metropolitan); @@ -170,7 +170,7 @@ </tr> </table> </form> - </body> + </body> </html> @@ -243,12 +243,12 @@ INFO::Started SelectChannelConnector@0.0 INFO: Loading XML configuration resource from file:/.../tutorial/target/classes/cayenne-project.xml INFO: loading user name and password. INFO: Created connection pool: jdbc:derby:memory:testdb;create=true - Driver class: org.apache.derby.jdbc.EmbeddedDriver - Min. connections in the pool: 1 - Max. connections in the pool: 1 + Driver class: org.apache.derby.jdbc.EmbeddedDriver + Min. connections in the pool: 1 + Max. connections in the pool: 1 INFO: Opening connection: jdbc:derby:memory:testdb;create=true - Login: null - Password: ******* + Login: null + Password: ******* INFO: +++ Connecting: SUCCESS. INFO: Detected and installed adapter: org.apache.cayenne.dba.derby.DerbyAdapter INFO: --- transaction started. Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/common-customizations.xsl URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/common-customizations.xsl?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/common-customizations.xsl (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/common-customizations.xsl Wed Dec 26 18:38:17 2012 @@ -20,15 +20,13 @@ - + - - 1 - + Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/html.xsl URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/html.xsl?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/html.xsl (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/html.xsl Wed Dec 26 18:38:17 2012 @@ -18,10 +18,10 @@ under the License. --> - + + + @@ -38,6 +38,4 @@ 1 - - Modified: cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/pdf.xsl URL: http://svn.apache.org/viewvc/cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/pdf.xsl?rev=1425988&r1=1425987&r2=1425988&view=diff ============================================================================== --- cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/pdf.xsl (original) +++ cayenne/main/branches/STABLE-3.1/docs/docbook/stylesheets/pdf.xsl Wed Dec 26 18:38:17 2012 @@ -1,115 +1,502 @@ + - - - - - A4 - - - 0pt - - - - - - - .png - stylesheets/docbook-xsl-ns/images/ - - - - .png - stylesheets/docbook-xsl-ns/images/callouts/ - - 0 - - - 2em - - - 10em - - - 18 - - - Lucinda Grande,sans-serif - Times,serif - Lucinda Grande,sans-serif - Lucinda Grande,serif - monospace - - - left - - - - 11 - - false - - - 1.5 - - - - 0.8em - 0.6em - 1.0em - - - - - auto - - - - 20mm - - - 20mm - - - 10mm - - - 10mm - - - 25mm - - - 15mm - - - - - - blue - - - - 7pt - - - ../ + + + + + + + + + + + + + + + + + + + + + + + + 0pt + + + + + + + .png + stylesheets/docbook-xsl-ns/images/ + + + + .png + stylesheets/docbook-xsl-ns/images/callouts/ + + 0 + + + 2em + + + 10em + + + 18 + + + Lucinda Grande,sans-serif + Times,serif + Lucinda Grande,sans-serif + Lucinda Grande,serif + monospace + + + justify + + + 11 + + true + + + 1.5 + + + + 0.8em + 0.6em + 1.0em + + + + + auto + + + + 20mm + + + 20mm + + + 10mm + + + 10mm + + + 18mm + + + 18mm + + + + + + blue + + + ../ + + + + + + + + + + + + + + + + + -5em + -5em + + + + + + + + + + + Spring-Integration ( + + ) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + 1 + 1 + + 1 + + + + + + book toc + + + + + + + + + + + + + + + 0 + 0 + + + + 10mm + + + + 10mm + + + + + + + 0pc + + + + + + + + + + 8 + + + + + 17.4cm + + + + 4pt + 4pt + 4pt + 4pt + + + + all + all + + 0.5pt + solid + black + 0.5pt + black + solid + solid + solid + solid + solid + + + + + 1 + + + + + + + + left + bold + + + pt + + + + + + + + + + + + + + + 0.8em + 0.8em + 0.8em + + + pt + + 0.1em + 0.1em + 0.1em + + + 0.6em + 0.6em + 0.6em + + + pt + + 0.1em + 0.1em + 0.1em + + + 0.4em + 0.4em + 0.4em + + + pt + + 0.1em + 0.1em + 0.1em + + + + + bold + + + pt + + false + 0.4em + 0.6em + 0.8em + + + + + + + + + pt + + + + + 0.9em + 0.9em + 0.9em + #444444 + solid + 0.1pt + 0.5em + 0.5em + 0.5em + 0.5em + 0.5em + 0.5em + + + + 1 + + #F0F0F0 + + + + + + + + + + 90 + + + + + + + + + + + + figure after + example before + equation before + table before + procedure before + + + + 1 + + + + 0.8em + 0.8em + 0.8em + 0.1em + 0.1em + 0.1em + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +