You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Getting Started with Grouper Provisioning Tests in Eclipse

To test provisioning from Grouper to LDAP or from LDAP to Grouper, you will need a working Grouper API installation and an LDAP DSA.

These instructions assume that you have the Grouper and provisioning projects in your Eclipse workspace, and that you are using Maven to build Grouper. See Grouper Development Environment Using Maven.

Configure Grouper API

Start HSQL or configure a database for Grouper via conf/grouper.hibernate.properties. The following example is for PostgreSQL.

conf/grouper.hibernate.properties
hibernate.dialect = org.hibernate.dialect.PostgreSQLDialect
hibernate.connection.driver_class = org.postgresql.Driver
hibernate.connection.url = jdbc:postgresql://127.0.0.1:5432/grouperTRUNK
hibernate.connection.username = postgres

If you configure a database, whitelist the db connection via db.change.allow.user and db.change.allow.url in conf/grouper.properties.

conf/grouper.properties :

db.change.allow.user.0 = postgres
db.change.allow.url.0 = jdbc:postgresql://127.0.0.1:5432/grouperTEST

PostgreSQL requires a modification to conf/sources.xml, scroll down until you see the following and cut & paste the correct SQL.

conf/sources.xml :

<\!-\-  for postgres, use this query since no concat() exists:

Grouper will warn regarding jarfile mismatches since we are using maven instead of ant. You can turn off the jarfile mismatch warnings in conf/grouper.properties by setting configuration.detect.errors to false.

conf/grouper.properties :

configuration.detect.errors = false

Logging to stdout may be helpful, add grouper_stdout to the log4j.rootLogger in conf/log4j.properties.

conf/log4j.properties :

log4j.rootLogger  = ERROR, grouper_error, grouper_stdout

The Grouper database will need to be initialized. I usually run edu.internet2.middleware.grouper.app.gsh.GrouperShell via a right-click to select Run As -> Java Application. This will fail since the Grouper database has not been initialized. I usually copy the GrouperShell run configuration via the menu Run -> Run Configurations... and add the -registry -runscript argument and run this new run configuration.

Type help() for instructions
gsh 0%
 
  • No labels