title: How to use Maven Release Plugin with Multiple Maven Projects
body: <p>I'm using Maven 3.</p>
  
  <p>I have multiple maven projects, namely: the 'data model', the 'service', and the 'presentation', split into 3 different projects. They are configured separately (ie. not using maven parent pom).</p>
  
  <p><img src="https://i.stack.imgur.com/XCxix.png" alt="project setup"></p>
  
  <p>I have maven release plugin setup on my project correctly, such that when I run <code>mvn release:clean release:prepare release:perform</code> on each individual project, it updates the project version (ie: from 3.4.5-SNAPSHOT to 3.4.5) as well as all the other things.</p>
  
  <p>The problem here is, 'presentation' is dependent on 'service' is dependent on 'data model', and I refer to the projects in the pom files with the version number. </p>
  
  <p>While I develop, say for example I would refer to 'service' in 'presentation' as 3.4.5-SNAPSHOT. But during deploy, I have to release 'service' to change the version to 3.4.5, then I have to update my version reference of 'service' in 'presentation', before I can run a release on 'presentation'. </p>
  
  <p>Is there an automated way of doing this such that I don't need to update the reference of dependent projects during release?</p>
  
  <h2>What I have so from thanks to below comments: Updated: 25/03/2013</h2>
  
  <p>Run maven with:</p>
  
  <pre><code>versions:use-releases -Dmessage="update from snapshot to release" scm:checkin release:clean release:prepare release:perform
  </code></pre>
  
  <p>Outcome: version updated, but release build failed. </p>