The errata list is a list of errors and their corrections that were found after the product was released.
The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.
Version |
Location |
Description |
Submitted by |
Date submitted |
Printed |
Page N/A
|
The code examples are not available on the Sonatype web site. I clicked on the link to zip file and got an error:
-------------------------
Forbidden
You don't have permission to access /books/maven-book/examples-1.0/ on this server.
-------------------------
Please fix the link so I can download the example code.
Tom Marrs
|
Tom Marrs |
Feb 12, 2009 |
Printed |
Page everwhere
Throughout the book |
I have a copy of the first printing. All the figures are missing. Not just in one chapter, but all the figures. The first figure is Figure 3-1. Instead of a figure, I see a square with a staircase looking marking on the lower right. I didn't notice it at first as it looked like it might be intentional, until I realized this is just a pretty version of the broken image. The last missing figure seems to be Figure 16-22 toward the end of the book.
Something else that appears to be broken is that every instance of user input is "%" or a "$" followed by a bunch of boxes. The ":" symbol sometimes get through. It looks like a missing font issue.
I've emailed O'Reilly but no response.
|
Harold Shinsato |
Apr 27, 2009 |
Printed |
Page 30
second paragraph |
the word "archetype" is split on line 4 with no hyphen. It is just
arche/type with no indication that the word is split.
Similar problem on page 31 in the first paragraph after the alert box.
archetype:cre/ate is badly split.
I'm sure there are other examples of this.
On page 31 in the first paragraph after the figure 3-1, there is a line that is correct but somewhat ugly because the two "-D..." parameters are not split.
I understand that formatting problems are a pain to deal with, but since you publish technical (programming) books, I would expect better. I once returned a book from another company because the formatting of code was TERRIBLE. This is not that bad, but it is confusing and inconsistent.
|
Anonymous |
Sep 23, 2011 |
|
43
2nd paragraph |
Links for download and reading online are broken. Previous errata posted indicate the links were fixed, but it is not so.
|
Mark Jaffe |
Jan 31, 2011 |
Printed |
Page 51
Simple Weather Source Code |
The link to the yahoo weather Api is not more in use, I put the following link :https://query.yahooapis.com/v1/public/yql/?q=select%20*%20from%20weather.forecast%20where%20woeid=2400737&format=xml
just to get the same place information( Evanston,Il,Us), exec:java is ok only that the template doesn't show the data.
|
Paolo Lordi |
Aug 26, 2017 |
PDF |
Page 53
Bottom |
The following code . . .
<build>
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
</configuration>
</plugin>
<executions>
<execution>
<id>simple-command</id>
<phase>package</phase>
<goals>
<goal>attached</goal>
</goals>
</execution>
</executions>
</plugins>
</build>
produces the following error when I run mvn package from the simple-weather directory . . .
[ERROR] FATAL ERROR
[INFO] Error building POM (may not be this project's POM).
under <execution> the <id> is listed as 'simple-command' which I assumed was the culprit but when I replaced it with 'simple-weather' that errored the same way.
|
Anonymous |
Jun 29, 2009 |
Printed |
Page 60
Code Example 4-13 |
The groupId (and version) for the apache Commons IO utils has changed from org.apache.commons to commons-io .
Presently, the dependency element should look something like this:
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.4</version>
</dependency>
|
Isaac Kleinman |
Oct 24, 2013 |
Printed |
Page 68-69
Creating the Simple Web Project |
running mvn archetype:create... as shown does not produce the same pom file as illustrated on pages 68-69.
1)The debug output shows that the commmand in the example is deprecated.
2)The pom file generated contains the wrong package type:
<packaging>jar</packaging>
3)The pom file is missing <build>..</build>
INFO] [INFO] Building Maven Default Project
[INFO] task-segment: [archetype:create] (aggregator-style)
[INFO] [INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus
.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on => 'false'.
[INFO] Setting property: resource.loader => 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound => 'false'.
[INFO] [archetype:create]
[WARNING] This goal is deprecated. Please use mvn archetype:generate instead
[INFO] artifact org.apache.maven.archetypes:maven-archetype-quickstart: checking
for updates from central
[INFO] -------------------------------------------------------------
[INFO] Using following parameters for creating OldArchetype: maven-archetype-qui
ckstart:RELEASE
[INFO] -------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.ch05
[INFO] Parameter: packageName, Value: org.sonatype.mavenbook
[INFO] Parameter: package, Value: org.sonatype.mavenbook
[INFO] Parameter: artifactId, Value: simple-webapp
[INFO] Parameter: basedir, Value: C:\
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] ********************* End of debug info from resources from generated POM
<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.sonatype.mavenbook.ch05</groupId>
<artifactId>simple-webapp</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>simple-webapp</name>
<url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
|
Anonymous |
Jan 26, 2009 |
Printed |
Page 69
Example 5-2 |
Instead of
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
</plugin>
It should be
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
</plugin>
|
izy100 |
Dec 30, 2008 |
Printed |
Page 77
Last paragraph |
The sentence says that the POM file in simple-parent/pom.xml (or ch06-multi/simple-parent/pom.xml based on the extraction from the downloaded examples) is the parent, or top-level, POM. If that is the case then what is the POM file in ch06-multi/pom.xml called?
<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.sonatype.mavenbook.ch06</groupId>
<artifactId>parent</artifactId>
<packaging>pom</packaging>
<name>Chapter 6 Parent Project</name>
<url>http://sonatype.com/book</url>
<parent>
<artifactId>examples</artifactId>
<groupId>org.sonatype.mavenbook</groupId>
<version>1-SNAPSHOT</version>
</parent>
<modules>
<module>simple-parent</module>
</modules>
</project>
Logically I would think ch06-multi/pom.xml would be the parent POM. There is no mention of this particular POM. Is this POM needed?
|
mcraghead |
Mar 02, 2009 |
Printed |
Page 78
Example 6-1 |
The simple-parent project POM file: simple-parent/pom.xml from the printed book does not tally with the downloaded pom.xml from the examples.
This portion is missing in the printed book:
<parent>
<artifactId>parent</artifactId>
<groupId>org.sonatype.mavenbook.ch06</groupId>
<version>1-SNAPSHOT</version>
</parent>
This confusion is further exacerbated by the explanation in the printed book in Pg 78, " ... the groupId is com.sonatype.maven, the artifactId id simple-parent and the version is 1.0. The ..." which doesn't tally to pom.xml in both the book and the downloaded examples.
|
izy100 |
Jan 01, 2009 |
Printed |
Page 88
fig 7-1 |
The relationships not properly depicted
1)simple project should inherit from Super POM.
2)simple-webapp, simple-command, simple-persist , simple-weather, simple-model should all inherit from simple-project.
3)simple-webapp, simple-command, simple-persist , simple-weather, simple-model should all be Module of simple-project.
This is important especially if you read thru page 170, 171 when the author tries to differentiate between inheritance and multi module "composition"
|
Vishy |
Oct 17, 2010 |
Printed |
Page 116
Top of the page |
When I try to run
mvn hibernate3:hbm2ddl
I get an error. The 2nd time I tried running I got this error message:
C:\Users\vance\workspace\simple-parent\simple-webapp>mvn hibernate3:hbm2ddl
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Building Chapter 7 Simple Web Application
[INFO] task-segment: [hibernate3:hbm2ddl]
[INFO] ------------------------------------------------------------------------
[INFO] Preparing hibernate3:hbm2ddl
[INFO] [resources:resources {execution: default-resources}]
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources,
i.e. build is platform dependent!
[INFO] Copying 0 resource
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to resolve artifact.
Missing:
----------
1) org.sonatype.mavenbook.ch07:simple-weather:jar:1-SNAPSHOT
Try downloading the file manually from the project website.
Then, install it using the command:
mvn install:install-file -DgroupId=org.sonatype.mavenbook.ch07 -DartifactI
d=simple-weather -Dversion=1-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file
Alternatively, if you host your own repository you can deploy the file there:
mvn deploy:deploy-file -DgroupId=org.sonatype.mavenbook.ch07 -DartifactId=
simple-weather -Dversion=1-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file -Durl=[
url] -DrepositoryId=[id]
Path to dependency:
1) org.sonatype.mavenbook.ch07:simple-webapp:war:1-SNAPSHOT
2) org.sonatype.mavenbook.ch07:simple-weather:jar:1-SNAPSHOT
2) org.sonatype.mavenbook.ch07:simple-persist:jar:1-SNAPSHOT
Try downloading the file manually from the project website.
Then, install it using the command:
mvn install:install-file -DgroupId=org.sonatype.mavenbook.ch07 -DartifactI
d=simple-persist -Dversion=1-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file
Alternatively, if you host your own repository you can deploy the file there:
mvn deploy:deploy-file -DgroupId=org.sonatype.mavenbook.ch07 -DartifactId=
simple-persist -Dversion=1-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file -Durl=[
url] -DrepositoryId=[id]
Path to dependency:
1) org.sonatype.mavenbook.ch07:simple-webapp:war:1-SNAPSHOT
2) org.sonatype.mavenbook.ch07:simple-persist:jar:1-SNAPSHOT
----------
2 required artifacts are missing.
for artifact:
org.sonatype.mavenbook.ch07:simple-webapp:war:1-SNAPSHOT
from the specified remote repositories:
central (http://repo1.maven.org/maven2)
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 second
[INFO] Finished at: Thu Jun 30 23:07:48 EDT 2011
[INFO] Final Memory: 9M/108M
[INFO] ------------------------------------------------------------------------
|
Anonymous |
Jun 30, 2011 |
Printed |
Page 162
2nd pom example (Optional Dependencies section) |
<project>
...
<dependencies>
...
<dependency>
<groupId>net.sf.ehcache</groupId>
<artifactId>swarmcache</artifactId>
<version>1.4.1</version>
</dependency>
</dependencies>
</project>
I think the artifactId should be ehcache (not swarmcache).
|
Pete B |
Jul 03, 2009 |
Printed |
Page 164
section 'Transitive dependencies and scope' |
A provided scoped transitive dependency of a provided scoped direct dependency will be omitted. Hence, the intersection of 'provided' and 'provided' should be changed from 'provided' to '-'. For further information see http://jira.codehaus.org/browse/MNG-4746.
|
Nico Werlein |
Aug 01, 2010 |
Printed |
Page 181
Last paragraph |
The sentence: "Running mvn clean invokes the clean lifecycle that consists of three lifecycle phases: pre-clean, clean, post-clean." is incorrect. "mvn clean" invokes the clean phase of the clean lifecylce. It will include pre-clean, but will not cause post-clean to run, any more than running "mvn test" will cause the package or install phase of the default lifecyle to run.
|
Gordon Shannon |
Mar 06, 2011 |
Other Digital Version |
220-259
Chapter 12 example source (page 220-259) |
The chapter 12 source in the examples: mvn-examples-1.0.zip 31-Oct-2008 15:00 287K
has only a very short pom.xml, it seems like it should have the assembly snippets that are described on pages 220-259 of the printed version.
The complete directory listing is:
$ find .
.
./.classpath
./.project
./.settings
./.settings/org.eclipse.jdt.core.prefs
./.settings/org.maven.ide.eclipse.prefs
./pom.xml
And the pom:
$ cat pom.xml
<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.sonatype.mavenbook.ch12</groupId>
<artifactId>parent</artifactId>
<packaging>pom</packaging>
<name>Chapter 12 Parent Project</name>
<url>http://sonatype.com/book</url>
<parent>
<artifactId>examples</artifactId>
<groupId>org.sonatype.mavenbook</groupId>
<version>1-SNAPSHOT</version>
</parent>
</project>
|
areese78 |
Mar 18, 2009 |
Printed |
Page 270-272,274-279,281-289
Chapter 14 |
All Figures in the chapter are missing.
Please email the missing figures to me or send me a refund check for the
purchase price.
I purchased the book from amazon.com largely on the contents of chapter 14.
|
W J Weder |
Apr 24, 2009 |
Printed |
Page 272
2nd para |
The text seems to suggest that Mylyn is a prerequisite for the Maven Eclipse plug-in. What is your basis for this? It does not match my experience.
|
Anonymous |
Aug 24, 2009 |
Printed |
Page 311
Example 15-1 |
The "Site Descriptor" is presented in Example 15-1 (page 311). For a newcomer it isn't clear which file is to be edited (my first guesses were pom.xml and index.apt). Only the page 314 made it clear that site descriptor is /src/site/site.xml.
Perhaps at least the introduction of /src/site/site.xml should be done before Example 15-1, even if the complete site directory structure comes later in the book.
|
Anonymous |
Oct 03, 2009 |
Printed |
Page 318
4th paragraph |
specify the publickey
publicKey should be privateKey
When connecting to SSH, private key is used on client side.
|
Peter S |
Aug 30, 2012 |
Printed |
Page 397
The last paragraph of Section "Configuring a Plugin Prefix" |
"you should be able to execute the EchoMojo by running mvn echo:blah from any directory."
Where should be
"you should be able to execute the EchoMojo by running mvn blah:echo from any directory."
|
Anonymous |
Aug 29, 2017 |
Printed |
Page 404
2nd |
The sentence "Example 17-8 shows a ZipMojo that depends on a Plexus component using the @parameter annotation." is pointing to the wrong example, 17-8 is using an @component annotation on the zipArchiver member. Example 17-7 us using @parameter on the same member.
|
Anonymous |
Apr 09, 2010 |