DaliCore OSGi

This is a modularized implementation of DaliCore that is ready to be used on the OSGi framework.

Building the project can be done with maven: mvn clean package

The project uses a MySQL database by default, which you can configure in the following way:

  • make sure you have a copy of the MySQL JDBC driver installed in the modules directory of glassfish
  • create the database on your local MySQL server. you can use the script in src/main/setup/ for this
  • add the JDBC resources to glassfish with the following command:
    asadmin add-resources src/main/setup/sun-resources.xml

Afterwards, you can deploy the following five bundles:

  1. asadmin deploy --type osgi --name dalicore-osgi-entity dalicore-osgi-entity/target/dalicore-osgi-entity-1.1.0-SNAPSHOT.jar
  2. asadmin deploy --type osgi --name dalicore-osgi-search dalicore-osgi-search/target/dalicore-osgi-search-1.1.0-SNAPSHOT.jar
  3. asadmin deploy --type osgi --name dalicore-osgi-service dalicore-osgi-service/target/dalicore-osgi-service-1.1.0-SNAPSHOT.jar
  4. asadmin deploy --type osgi --name dalicore-osgi-jpa dalicore-osgi-jpa/target/dalicore-osgi-jpa-1.1.0-SNAPSHOT.jar
  5. asadmin deploy --type osgi --name dalicore-osgi-console dalicore-osgi-console/target/dalicore-osgi-console-1.1.0-SNAPSHOT.jar

Then connect to the felix gogo shell (eg: telnet localhost 6666) and run the following commands:

  • create "Title for Content 1" 1
  • create "Title for Content 2" 2
  • create "Title for Contnet 3" 2
  • listbytype 2