OpenAM: Setup in Eclipse

OpenAM Community Logo When I found earlier this year that Eclipse does a pretty good job for XML editing, Eclipse became my IDE of choice. Download support for Subversion and Maven, and most of my tasks seem straightforward.

Except setting up OpenAM as a new project in Eclipse. Which I seem to do too often.

My first mistake is trying to set up from existing code checked out from https://svn.forgerock.org/openam/trunk/opensso. Next mistake is trying to check out the code from Subversion with New > Project… > SVN, and then getting confused, trying to use the existing Ant file under opensso/projects/build.xml.

In fact, what seemed to work for me is this (Eclipse 3.7.0). YMMV…

  1. In Eclipse, New > Project… > SVN, etc.
    When Eclipse starts the wizard inside the wizard, New > Java Project in the directory where the sources will check out, and then Project name opensso (same as the file system directory).
  2. Download the .zip of extlib dependencies from this Wiki page that will be used to replace opensso/products/extlib (but don’t do it yet).
  3. Replace opensso/products/extlib with the content of the .zip.
  4. Build the software first from the command line (cd opensso/products ; ant server-war).
  5. In Eclipse, open opensso/products/build.xml, right-click the server-war target and Run As > Ant Build.
This leaves me with a project having too many folders, many errors, and warnings, but it works to build the server-war target from inside Eclipse… and work on docs under openam-site.

2 thoughts on “OpenAM: Setup in Eclipse

  1. Noamn

    Hi,
    Can you please tell me how much modules required for openAM local testing. when i try to build openAM after checkout code from svn it takes lot of time due because of list of the modules which available in the trunk. I want to test the openAm just for testing purpose so need to know exact number of modules to compile and make a final jar. list of modules which i talking about are like:

    Build Order:

    OpenAM Project
    OpenAM Shared
    OpenAM LDAP Utilities
    OpenAM Tools
    OpenAM Build Tools
    OpenAM Common Locale Bundles
    OpenAM Entitlements
    OpenAM Core Token
    OpenAM Rest
    OpenAM Schemata
    OpenAM Identity Services Schema
    OpenAM MIB Schema
    …. etc

    1. Hi,

      The build does take quite a while and uses a fair amount of RAM.

      I would encourage you to look at the (long) list of modules for a successful build on the Jenkins server. For example, see the list on http://builds.forgerock.org/view/OpenAM/job/OpenAM-Trunk-Nightly/modules.

      That build is created with mvn clean install at the base directory of the project.

      If what you want is just the OpenAM server .war, then you’ll find it at the end of the install in openam-server/target/openam-server-version.war.

      Hope it helps,
      Mark

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.