Spring 3.1 and CloudFoundry with MongoDB
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.gitignore
README
pom.xml

README

## How to run ##

To run this application, you must have Maven 3 and JDK 1.6+ installed and working AND MongoDB 1.8+ running locally for the tests to run

To run, type:
mvn clean package cargo:run

There are enhancements you can add to this configuration, like using JRebel and adding remote debugging. To enable both JRebel and remote debugging, simply add a profile in your settings.xml file:

...
...
<profile>
    <id>tomcat</id>
    <properties>
        <cargo.tomcat.installdir>${project.basedir}</cargo.tomcat.installdir>
        <cargo.args>-noverify -javaagent:${env.REBEL_HOME}/jrebel.jar -Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n</cargo.args>
    </properties>
</profile>
...
...
<activeProfiles>
    <activeProfile>tomcat</activeProfile>
    ...
    ...
</activeProfiles>
...
...


Reasoning behind using Cargo + Tomcat 7
The reason for tomcat 7 is to better replicate the production environment of many companies.  Typically the artifact of a build is a WAR, which is then deployed to Tomcat. One good way of doing this is to publish your WAR file to a repository like Artifactory, Nexus or Apache Artifact Repository.  During your deployment phase the artifact can be pulled from the repository.  This configuration is set up to replicate most of that configuration.