DATAJPA-470 - Update Documentation.

Update urls to point to spring.io. Added missing id tag to documentation sections. Fix some typos in reference manual. Update readme.md to use consistent set of database and dialect. Add missing end tag for 'para' in FAQ section. Update authors for proper rendering in PDF. Added productname tag. Added links to Stack Overflow.

Original pull request: #59.
This commit is contained in:
Christoph Strobl
2014-02-20 14:48:43 +01:00
committed by Oliver Gierke
parent 59d4e80010
commit 7e2d7831a4
9 changed files with 198 additions and 143 deletions

View File

@@ -9,7 +9,7 @@
<name>Spring Data JPA</name>
<description>Spring Data module for JPA repositories.</description>
<url>http://www.springframework.org/spring-data/jpa</url>
<url>http://projects.spring.io/spring-data-jpa</url>
<parent>
<groupId>org.springframework.data.build</groupId>

View File

@@ -1,6 +1,6 @@
# Spring Data JPA #
The primary goal of the [Spring Data](http://www.springsource.org/spring-data) project is to make it easier to build Spring-powered applications that use data access technologies. This module deals with enhanced support for JPA based data access layers.
The primary goal of the [Spring Data](http://projects.spring.io/spring-data) project is to make it easier to build Spring-powered applications that use data access technologies. This module deals with enhanced support for JPA based data access layers.
## Features ##
@@ -14,11 +14,11 @@ The primary goal of the [Spring Data](http://www.springsource.org/spring-data) p
## Getting Help ##
This README as well as the [reference documentation](http://static.springsource.org/spring-data/data-jpa/snapshot-site/reference/html) are the best places to start learning about Spring Data JPA. There are also [two sample applications](https://github.com/SpringSource/spring-data-jpa-examples) available to look at.
This README as well as the [reference documentation](http://docs.spring.io/spring-data/data-jpa/docs/current/reference/html) are the best places to start learning about Spring Data JPA. There are also [two sample applications](https://github.com/spring-projects/spring-data-examples) available to look at.
The main project [website](http://www.springsource.org/spring-data) contains links to basic project information such as source code, JavaDocs, Issue tracking, etc.
The main project [website](http://projects.spring.io/spring-data) contains links to basic project information such as source code, JavaDocs, Issue tracking, etc.
For more detailed questions, use the [forum](http://forum.springsource.org/forumdisplay.php?f=27). If you are new to Spring as well as to Spring Data, look for information about [Spring projects](http://www.springsource.org/projects). You should also have a look at our new Spring Guide
For more detailed questions, use [stackoverflow](http://stackoverflow.com/questions/tagged/spring-data-jpa) or the [forum](forum.spring.io/forum/jpa-orm). If you are new to Spring as well as to Spring Data, look for information about [Spring projects](http://projects.spring.io). You should also have a look at our new Spring Guide
[Accessing Data with JPA](https://spring.io/guides/gs/accessing-data-jpa/) that leverages the simplified configuration provided by [Spring Boot](http://projects.spring.io/spring-boot/).
@@ -44,7 +44,7 @@ class AppConfig {
@Bean
public DataSource dataSource() {
return new EmbeddedDatabaseBuilder().setType(EmbeddedDatabaseType.HSQL).build();
return new EmbeddedDatabaseBuilder().setType(EmbeddedDatabaseType.H2).build();
}
@Bean
@@ -125,9 +125,9 @@ public class UserRepositoryIntegrationTest {
Here are some ways for you to get involved in the community:
* Get involved with the Spring community on the Spring Community Forums. Please help out on the [forum](http://forum.springsource.org/forumdisplay.php?f=27) by responding to questions and joining the debate.
* Get involved with the Spring community by helping out on [stackoverflow](http://stackoverflow.com/questions/tagged/spring-data-jpa) and the [forum](forum.spring.io/forum/jpa-orm) by responding to questions and joining the debate.
* Create [JIRA](https://jira.springsource.org/browse/DATAJPA) tickets for bugs and new features and comment and vote on the ones that you are interested in.
* Github is for social coding: if you want to write code, we encourage contributions through pull requests from [forks of this repository](http://help.github.com/forking/). If you want to contribute code this way, please reference a JIRA ticket as well covering the specific issue you are addressing.
* Watch for upcoming articles on Spring by [subscribing](http://www.springsource.org/node/feed) to springframework.org
* Watch for upcoming articles on Spring by [subscribing](http://spring.io/blog) to spring.io.
Before we accept a non-trivial patch or pull request we will need you to sign the [contributor's agreement](https://support.springsource.com/spring_committer_signup). Signing the contributor's agreement does not grant anyone commit rights to the main repository, but it does mean that we can accept your contributions, and you will get an author credit if we do. Active contributors might be asked to join the core team, and given the ability to merge pull requests.

View File

@@ -50,7 +50,8 @@
<answer>
<para>You have to replace
<classname>AnnotationSessionFactoryBean</classname> with the
<classname>HibernateJpaSessionFactoryBean</classname> as follows:
<classname>HibernateJpaSessionFactoryBean</classname> as
follows:</para>
<example>
<title>Looking up a SessionFactory from a

View File

@@ -1,114 +1,114 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
<glossary id="glossary">
<glossdiv>
<title>A</title>
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
<glossary id="glossary">
<glossdiv>
<title>A</title>
<glossentry>
<glossterm>AOP</glossterm>
<glossentry>
<glossterm>AOP</glossterm>
<glossdef>
<para>Aspect oriented programming</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Aspect oriented programming</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>C</title>
<glossdiv>
<title>C</title>
<glossentry>
<glossterm>Commons DBCP</glossterm>
<glossentry>
<glossterm>Commons DBCP</glossterm>
<glossdef>
<para>Commons DataBase Connection Pools - Library of the Apache
foundation offering pooling implementations of the
<interfacename>DataSource</interfacename> interface.</para>
</glossdef>
</glossentry>
<glossdef>
<para>Commons DataBase Connection Pools - Library of the Apache
foundation offering pooling implementations of the
<interfacename>DataSource</interfacename> interface.</para>
</glossdef>
</glossentry>
<glossentry>
<glossterm>CRUD</glossterm>
<glossentry>
<glossterm>CRUD</glossterm>
<glossdef>
<para>Create, Read, Update, Delete - Basic persistence
operations</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Create, Read, Update, Delete - Basic persistence
operations</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>D</title>
<glossdiv>
<title>D</title>
<glossentry>
<glossterm>DAO</glossterm>
<glossentry>
<glossterm>DAO</glossterm>
<glossdef>
<para>Data Access Object - Pattern to separate persisting logic from
the object to be persisted</para>
</glossdef>
</glossentry>
<glossdef>
<para>Data Access Object - Pattern to separate persisting logic from
the object to be persisted</para>
</glossdef>
</glossentry>
<glossentry>
<glossterm>Dependency Injection</glossterm>
<glossentry>
<glossterm>Dependency Injection</glossterm>
<glossdef>
<para>Pattern to hand a component's dependency to the component from
outside, freeing the component to lookup the dependant itself. For
more information see <ulink
url="http://en.wikipedia.org/wiki/Dependency_Injection">http://en.wikipedia.org/wiki/Dependency_Injection</ulink>.</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Pattern to hand a component's dependency to the component from
outside, freeing the component to lookup the dependant itself. For
more information see <ulink
url="http://en.wikipedia.org/wiki/Dependency_Injection">http://en.wikipedia.org/wiki/Dependency_Injection</ulink>.</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>E</title>
<glossdiv>
<title>E</title>
<glossentry>
<glossterm>EclipseLink</glossterm>
<glossentry>
<glossterm>EclipseLink</glossterm>
<glossdef>
<para>Object relational mapper implementing JPA - <ulink
url="http://www.eclipselink.org">http://www.eclipselink.org</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Object relational mapper implementing JPA - <ulink
url="http://www.eclipselink.org">http://www.eclipselink.org</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>H</title>
<glossdiv>
<title>H</title>
<glossentry>
<glossterm>Hibernate</glossterm>
<glossentry>
<glossterm>Hibernate</glossterm>
<glossdef>
<para>Object relational mapper implementing JPA - <ulink
url="http://www.hibernate.org">http://www.hibernate.org</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Object relational mapper implementing JPA - <ulink
url="http://www.hibernate.org">http://www.hibernate.org</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>J</title>
<glossdiv>
<title>J</title>
<glossentry>
<glossterm>JPA</glossterm>
<glossentry>
<glossterm>JPA</glossterm>
<glossdef>
<para>Java Persistence Api</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdef>
<para>Java Persistence Api</para>
</glossdef>
</glossentry>
</glossdiv>
<glossdiv>
<title>S</title>
<glossdiv>
<title>S</title>
<glossentry>
<glossterm>Spring</glossterm>
<glossentry>
<glossterm>Spring</glossterm>
<glossdef>
<para>Java application framework - <ulink
url="http://www.springframework.org">http://www.springframework.org</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
</glossary>
<glossdef>
<para>Java application framework - <ulink
url="http://projects.spring.io/spring-framework">http://projects.spring.io/spring-framework</ulink></para>
</glossdef>
</glossentry>
</glossdiv>
</glossary>

View File

@@ -1,11 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
<book xmlns:xi="http://www.w3.org/2001/XInclude">
<book>
<bookinfo>
<title>Spring Data JPA - Reference Documentation</title>
<releaseinfo>&version;</releaseinfo>
<releaseinfo>version;</releaseinfo>
<authorgroup>
<author>
@@ -16,12 +16,12 @@
<affiliation>
<jobtitle>Software Engineer</jobtitle>
<orgname>GoPivotal Deutschland GmbH</orgname>
<orgname>Pivotal Software, Inc.</orgname>
</affiliation>
<email>ogierke@gopivotal.com</email>
</author>
<author>
<firstname>Thomas</firstname>
@@ -30,11 +30,25 @@
<affiliation>
<jobtitle>Software Engineer</jobtitle>
<orgname>GoPivotal Deutschland GmbH</orgname>
<orgname>Pivotal Software, Inc.</orgname>
</affiliation>
<email>tdarimont@gopivotal.com</email>
</author>
<author>
<firstname>Christoph</firstname>
<surname>Strobl</surname>
<affiliation>
<jobtitle>Software Engineer</jobtitle>
<orgname>Pivotal Software, Inc.</orgname>
</affiliation>
<email>cstrobl@gopivotal.com</email>
</author>
</authorgroup>
<legalnotice>
@@ -44,42 +58,45 @@
Notice, whether distributed in print or electronically.</para>
</legalnotice>
<pubdate />
<copyright>
<year>2008-2013</year>
<year>2008-2014</year>
<holder>The original authors</holder>
<holder>The original authors.</holder>
</copyright>
<productname>Spring Data JPA - Reference Documentation</productname>
</bookinfo>
<toc />
<toc/>
<xi:include href="preface.xml" />
<xi:include href="preface.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<part id="reference">
<title>Reference Documentation</title>
<xi:include href="https://raw.github.com/SpringSource/spring-data-commons/1.7.0.RC1/src/docbkx/repositories.xml">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repositories.xml" />
<xi:include href="https://raw.github.com/spring-projects/spring-data-commons/1.7.0.RC1/src/docbkx/repositories.xml"
xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repositories.xml"/>
</xi:include>
<xi:include href="jpa.xml" />
<xi:include href="jpa.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
</part>
<part id="appendix">
<title>Appendix</title>
<xi:include href="https://raw.github.com/SpringSource/spring-data-commons/1.7.0.RC1/src/docbkx/repository-namespace-reference.xml">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repository-namespace-reference.xml" />
</xi:include>
<xi:include href="https://raw.github.com/SpringSource/spring-data-commons/1.7.0.RC1/src/docbkx/repository-query-keywords-reference.xml">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repository-query-keywords-reference.xml" />
<xi:include href="https://raw.github.com/spring-projects/spring-data-commons/1.7.0.RC1/src/docbkx/repository-namespace-reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repository-namespace-reference.xml"/>
</xi:include>
<xi:include href="faq.xml" />
<xi:include href="https://raw.github.com/spring-projects/spring-data-commons/1.7.0.RC1/src/docbkx/repository-query-keywords-reference.xml"
xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:fallback href="../../../spring-data-commons/src/docbkx/repository-query-keywords-reference.xml"/>
</xi:include>
<xi:include href="glossary.xml" />
<xi:include href="faq.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
<xi:include href="glossary.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
</part>
</book>
</book>

View File

@@ -42,7 +42,7 @@
in <xref linkend="repositories.create-instances"/>. Beyond that it
activates persistence exception translation for all beans annotated with
<interfacename>@Repository</interfacename> to let exceptions being
thrown by the JPA presistence providers be converted into Spring's
thrown by the JPA persistence providers be converted into Spring's
<classname>DataAccessException</classname> hierarchy.</para>
<simplesect id="jpa.namespace-attributes">
@@ -50,7 +50,7 @@
<para>Beyond the default attributes of the <code>repositories</code>
element the JPA namespace offers additional attributes to gain more
detailled control over the setup of the repositories:</para>
detailed control over the setup of the repositories:</para>
<table>
<title>Custom JPA-specific attributes of the repositories
@@ -98,7 +98,7 @@
</simplesect>
</section>
<section>
<section id="jpa.java-config">
<title>Annotation based configuration</title>
<para>The Spring Data JPA repositories support cannot only be activated
@@ -208,7 +208,7 @@ class ApplicationConfig {
Data JPA will delegate the new-detection to the
<methodname>isNew</methodname> - Method of the Entity. See the
<ulink
url="http://static.springsource.org/spring-data/data-commons/docs/current/api/index.html?org/springframework/data/domain/Persistable.html">JavaDoc</ulink>
url="http://docs.spring.io/spring-data/data-commons/docs/current/api/index.html?org/springframework/data/domain/Persistable.html">JavaDoc</ulink>
for details.</entry>
</row>
@@ -226,7 +226,7 @@ class ApplicationConfig {
implementation of <classname>JpaRepositoryFactory</classname>
as a Spring bean. Note that this should be rarely necessary.
See the <ulink
url="http://static.springsource.org/spring-data/data-jpa/docs/current/api/index.html?org/springframework/data/jpa/repository/support/JpaRepositoryFactory.html">JavaDoc</ulink>
url="http://docs.spring.io/spring-data/data-jpa/docs/current/api/index.html?org/springframework/data/jpa/repository/support/JpaRepositoryFactory.html">JavaDoc</ulink>
for details.</entry>
</row>
</tbody>
@@ -321,6 +321,14 @@ class ApplicationConfig {
<entry><code>… where x.lastname = ?1 or x.firstname =
?2</code></entry>
</row>
<row>
<entry><code>Is,Equals</code></entry>
<entry><code>findByFirstname,findByFirstnameIs,findByFirstnameEquals</code></entry>
<entry><code>… where x.firstname = 1?</code></entry>
</row>
<row>
<entry><code>Between</code></entry>
@@ -338,6 +346,14 @@ class ApplicationConfig {
<entry><code>… where x.age &lt; ?1</code></entry>
</row>
<row>
<entry><code>LessThanEqual</code></entry>
<entry><code>findByAgeLessThanEqual</code></entry>
<entry><code>… where x.age &lt;= ?1</code></entry>
</row>
<row>
<entry><code>GreaterThan</code></entry>
@@ -346,6 +362,14 @@ class ApplicationConfig {
<entry><code>… where x.age &gt; ?1</code></entry>
</row>
<row>
<entry><code>GreaterThanEqual</code></entry>
<entry><code>findByAgeGreaterThanEqual</code></entry>
<entry><code>… where x.age &gt;= ?1</code></entry>
</row>
<row>
<entry><code>After</code></entry>
@@ -472,6 +496,15 @@ class ApplicationConfig {
<entry><code>… where x.active = false</code></entry>
</row>
<row>
<entry><code>IgnoreCase</code></entry>
<entry><code>findByFirstnameIgnoreCase</code></entry>
<entry><code>… where UPPER(x.firstame) = UPPER(?1)</code></entry>
</row>
</tbody>
</tgroup>
</table><note>
@@ -645,7 +678,7 @@ public class User {
binding as described in all the samples above. This makes query methods
a little error prone to refactoring regarding the parameter position. To
solve this issue you can use <code>@Param</code> annotation to give a
method parameter a concrete name and bind the name in the query:</para>
method parameter a concrete name and bind the name in the query.</para>
<example>
<title>Using named parameters</title>
@@ -662,7 +695,7 @@ public class User {
</example>
</section>
<section>
<section id="jpa.query.spel-expressions">
<title id="jpa.query.spel">Using SpEL expressions</title>
<para>As of Spring Data JPA Release 1.4 we support the usage of
@@ -722,7 +755,10 @@ public class User {
<programlisting language="java">@Entity
public class User {
@Id @GeneratedValue Long id;
@Id
@GeneratedValue
Long id;
String lastname;
}
@@ -814,7 +850,7 @@ int setFixedFirstnameFor(String firstname, String lastname);</programlisting>
you wish the <interfacename>EntityManager</interfacename> to be cleared
automatically you can set <interfacename>@Modifying</interfacename>
annotation's <code>clearAutomatically</code> attribute to
<literal>true</literal>;</para>
<literal>true</literal>.</para>
</section>
<section id="jpa.query-hints">
@@ -1031,9 +1067,10 @@ class UserManagementImpl implements UserManagement {
none already running). The transaction configuration at the repositories
will be neglected then as the outer transaction configuration determines
the actual one used. Note that you will have to activate
<code>&lt;tx:annotation-driven /&gt;</code> explicitly to get annotation
based configuration at facades working. The example above assumes you
are using component scanning.</para>
<code>&lt;tx:annotation-driven /&gt;</code> or use
<interfacename>@EnableTransactionManagement</interfacename> explicitly
to get annotation based configuration at facades working. The example
above assumes you are using component scanning.</para>
</example>
<section id="transactional-query-methods">
@@ -1122,12 +1159,12 @@ public interface UserRepository extends JpaRepository&lt;User, Long&gt; {
<section id="jpa.auditing">
<title>Auditing</title>
<xi:include href="https://raw.github.com/SpringSource/spring-data-commons/master/src/docbkx/auditing.xml"
<xi:include href="https://raw.github.com/spring-projects/spring-data-commons/master/src/docbkx/auditing.xml"
xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:fallback href="../../../spring-data-commons/src/docbkx/auditing.xml"/>
</xi:include>
<section>
<section id="jpa.auditing.configuration">
<title>General auditing configuration</title>
<para>Spring Data JPA ships with an entity listener that can be used to
@@ -1250,7 +1287,7 @@ class Config {
<para>As of Spring 3.1 a package to scan can be configured on the
<classname>LocalContainerEntityManagerFactoryBean</classname> directly
to enable classpath scanning for entity classes. See the <ulink
url="http://static.springsource.org/spring/docs/3.1.x/javadoc-api/org/springframework/orm/jpa/LocalContainerEntityManagerFactoryBean.html#setPackagesToScan(java.lang.String...)">JavaDoc</ulink>
url="http://docs.spring.io/spring/docs/current/javadoc-api/org/springframework/orm/jpa/LocalContainerEntityManagerFactoryBean.html#setPackagesToScan(java.lang.String...)">JavaDoc</ulink>
for details.</para>
</note>
</section>

View File

@@ -10,7 +10,7 @@
<itemizedlist spacing="compact">
<listitem>
<para>Version control - <ulink
url="git://github.com/SpringSource/spring-data-jpa.git">git://github.com/SpringSource/spring-data-jpa.git</ulink></para>
url="git://github.com/spring-projects/spring-data-jpa.git">git://github.com/spring-projects/spring-data-jpa.git</ulink></para>
</listitem>
<listitem>
@@ -20,18 +20,18 @@
<listitem>
<para>Release repository - <ulink
url="http://repo.springsource.org/libs-release">http://repo.springsource.org/libs-release</ulink></para>
url="http://repo.spring.io/libs-release">http://repo.spring.io/libs-release</ulink></para>
</listitem>
<listitem>
<para>Milestone repository - <ulink
url="http://repo.springsource.org/libs-milestone">http://repo.springsource.org/libs-milestone</ulink></para>
url="http://repo.spring.io/libs-milestone">http://repo.spring.io/libs-milestone</ulink></para>
</listitem>
<listitem>
<para>Snapshot repository - <ulink
url="http://repo.springsource.org/libs-snapshot">http://repo.springsource.org/libs-snapshot</ulink></para>
url="http://repo.spring.io/libs-snapshot">http://repo.spring.io/libs-snapshot</ulink></para>
</listitem>
</itemizedlist>
</section>
</preface>
</preface>

View File

@@ -13,5 +13,5 @@ The reference manual and javadoc are located in the 'docs' directory.
ADDITIONAL RESOURCES:
Spring Data Homepage: http://www.springsource.org/spring-data
Spring Data Forum: http://forum.springsource.org/forumdisplay.php?f=27
Spring Data Homepage: http://projects.spring.io/spring-data
Spring Data Forum: http://forum.spring.io/forum/jpa-orm

View File

@@ -1,7 +1,7 @@
Bundle-ManifestVersion: 2
Bundle-SymbolicName: org.springframework.data.jpa
Bundle-Name: ${project.name}
Bundle-Vendor: SpringSource
Bundle-Vendor: Pivotal Software, Inc
Bundle-Version: ${project.version}
Bundle-RequiredExecutionEnvironment: J2SE-1.5
Export-Template: