Package for marshalling/unmarshaling wisebed resource files in XML, RDBMS and RDF format. Uses JiBX bindings, JPA/Hibernate and Jena.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src
var
.gitignore
README.md
new-file
pom.xml
sun_checks.xml
suppressions.xml

README.md

WiseML

The repository contains the following packages:

  • WiseML parser based on JibX bindings.
  • WiseConfig parser based on JibX bindings.
  • WiseDB relational persistence based on Hibernate bindings.
  • WiseRDF mappings based on Jena framework.

Related links

What do I need?

  • JibX is one of the fastest XML object mapping frameworks out there (check out this performance test). Furthermore, it is very flexible in binding XML structures to objects.
  • Hibernate is probably the most well establish relational persistence framework for Java. Hibernate facilitates the storage and retrieval of Java domain objects via Object/Relational Mapping (ORM).

Latest stable version

The latest stable version is available from Hudson, the continuous integration tool.

(testing the SCM polling mechanism of Hudson)

Hibernate Configuration

You can configure Hibernate by providing the appropriate configuration in your local Maven settings file ~/.m2/settings.xml:

<settings>
	...
	<profiles>
    	<profile>
			<id>wisedb-on-remote-host</id>
        	<properties>
            	<wisedb.hibernate.dialect>org.hibernate.dialect.MySQLDialect</wisedb.hibernate.dialect>
            	<wisedb.jdbc.connection.driver_class>com.mysql.jdbc.Driver</wisedb.jdbc.connection.driver_class>
            	<wisedb.jdbc.connection.url>jdbc:mysql://ip-on-remote-wisedb/wisdeb</wisedb.jdbc.connection.url>
            	<wisedb.jdbc.connection.username>wisedb</wisedb.jdbc.connection.username>
            	<wisedb.jdbc.connection.password>wisedbpassword</wisedb.jdbc.connection.password>
            	<wisedb.jdbc.connection.pool_size>10</wisedb.jdbc.connection.pool_size>
        	</properties>
    	</profile>
		<profile>
			<id>wisedb-on-local-host/id>
			<properties>
				<local.wisedb.hibernate.dialect>org.hibernate.dialect.MySQLDialect</<local.wisedb.hibernate.dialect>
				<local.wisedb.jdbc.connection.driver_class>com.mysql.jdbc.Driver</<local.wisedb.jdbc.connection.driver_class>
				<local.wisedb.jdbc.connection.url>jdbc:mysql://localhost/wisedb</<local.wisedb.jdbc.connection.url>
				<local.wisedb.jdbc.connection.username>wisedb</<local.wisedb.jdbc.connection.username>
				<local.wisedb.jdbc.connection.password>wisedbpassword</<local.wisedb.jdbc.connection.password>
				<local.wisedb.jdbc.connection.pool_size>10</<local.wisedb.jdbc.connection.pool_size>
			</properties>
		</profile>
	</profiles>
	<activeProfiles>
		<activeProfile>wisedb-on-local-host</activeProfile>
		<activeProfile>wisedb-on-remote-host</activeProfile>
	</activeProfiles>
	...
</settings>   

Note that you should provide two profiles one for the main sources and one for the test resources. Configuration is now stored in jar using mvn package.

Simple execution

mvn clean

mvn package

java -cp target/wiseml-1.0-SNAPSHOT-jar-with-dependencies.jar:target/test-classes eu.wisebed.wiseml.test.SetupNewNode marshal

and then check out file "output.xml"

Use in your Maven project

Add the following dependency to your pom.xml:

	<dependency>
		<groupId>ichatz</groupId>
		<artifactId>wiseml</artifactId>
		<version>1.1-SNAPSHOT</version>
	</dependency>

Add the following repositories to your pom.xml

<repositories>
	<repository>
		<id>itm-maven-repository-releases</id>
		<url>http://www.itm.uni-luebeck.de/projects/maven/releases/</url>
		<releases>
			<enabled>true</enabled>
		</releases>
		<snapshots>
			<enabled>false</enabled>
		</snapshots>
	</repository>

	<repository>
		<id>itm-maven-repository-snapshots</id>
		<url>http://www.itm.uni-luebeck.de/projects/maven/snapshots/</url>
		<releases>
			<enabled>false</enabled>
		</releases>
		<snapshots>
			<enabled>true</enabled>
		</snapshots>
	</repository>
</repositories>

Contact

Any feedback will be greatly appreciated, at the GitHub project page (https://github.com/ichatz/wiseml) or by contacting ichatz