• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

use net.sf.ehcache instead of org.ehcache

 
Ranch Hand
Posts: 1738
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, in chapter 16 of Getting Started with Spring Framework 5, ch16-bankapp-db-security, the pom.xml needs to be updated. I think org.ehcache is not updated.
This  is the pom file I updated into:


<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>chapter16</groupId>
<artifactId>ch16-bankapp-db-security</artifactId>
<packaging>war</packaging>
<version>0.1.0.BUILD-SNAPSHOT</version>
<name>ch16-bankapp-db-security</name>
<properties>
<aspectj.version>1.8.9</aspectj.version>
<spring.version>5.0.7.RELEASE</spring.version>
<spring.security.version>5.0.7.RELEASE</spring.security.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

....
<dependencies>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-ehcache</artifactId>
<version>5.2.12.Final</version>
</dependency>

<dependency>
                   <groupId>net.sf.ehcache</groupId>
                  <artifactId>ehcache</artifactId>
                  <version>2.10.0</version>
             </dependency>
....



The original pom file provided by the book is:


<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<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>chapter16</groupId>
<artifactId>ch16-bankapp-db-security</artifactId>
<packaging>war</packaging>
<version>0.1.0.BUILD-SNAPSHOT</version>
<name>ch16-bankapp-db-security</name>
<properties>
<aspectj.version>1.8.9</aspectj.version>
<spring.version>5.0.1.RELEASE</spring.version>
<spring.security.version>5.0.0.RC1</spring.security.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

....
<dependencies>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-ehcache</artifactId>
<version>5.2.12.Final</version>
</dependency>
<dependency>
<groupId>org.ehcache</groupId>
<artifactId>ehcache</artifactId>
<version>3.4.0</version>
</dependency>

   ....

 
Sheriff
Posts: 21758
102
Eclipse IDE Spring VI Editor Chrome Java Ubuntu Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, net.sf.ehcache:ehcache is the older one: http://mvnrepository.com/artifact/net.sf.ehcache/ehcache links to http://mvnrepository.com/artifact/org.ehcache/ehcache. It is true that the older version has a more recent update (April this year), but I wouldn't say that org.ehcache:ehcache is not updated; it's got an update as recent as March this year. That's only a month before the old version, and that was probably a bugfix for people still using the old version. If anything, I'd say that org.ehcache:ehcache is updated more often - the last updates were March, March and February (all this year), whereas net.sf.ehcache:ehcache's latest updates were April this year and April last year.

You should of course use version 3.5.2 instead of 3.4.0, that's true.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!