sascha@26: 2009-09-10 Sascha L. Teichmann sascha@26: sascha@26: * artifact-database/src/main/java/de/intevation/artifactdatabase/XMLUtils.java: sascha@26: Added method to get strings from XML documents via XPath. sascha@26: sascha@26: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java: sascha@26: Used XMLUtils to create new XML documents. sascha@26: sascha@26: * artifact-database/src/main/java/de/intevation/artifactdatabase/ArtifactDatabaseImpl.java: sascha@26: Forgot to store backend in instance variable. sascha@26: sascha@26: * artifacts/src/main/java/de/intevation/artifacts/ArtifactNamespaceContext.java: sascha@26: Added static instance of this class. sascha@26: sascha@26: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/CreateResource.java: sascha@26: Forward call to ArtifactDatabase, do some error handling. sascha@26: sascha@26: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java: sascha@26: Treat problems with database errors more gracefully. sascha@26: sascha@26: * contrib/run.sh: Added dependencies to common-pool and common-dbcp. sascha@26: sascha@26: * artifact-database/doc/data/create-artifact.xml: New. example data set to sascha@26: create an artifact. Usage sascha@26: sascha@26: $ curl --data-binary @doc/data/create-artifact.xml -D - http://localhost:8181/create sascha@26: sascha@26: 2009-09-10 Sascha L. Teichmann sascha@25: sascha@25: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/FactoriesResource.java: sascha@25: Removed needless import. sascha@25: sascha@25: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java, sascha@25: artifact-database/src/main/java/de/intevation/artifactdatabase/XMLUtils.java: sascha@25: Moved some XPath stuff from Config into XMLUtils. sascha@25: sascha@26: 2009-09-10 Sascha L. Teichmann sascha@24: sascha@24: * artifacts/src/main/java/de/intevation/artifacts/Artifact.java(setup): Added sascha@24: callback parameter in form of the creating factory. sascha@24: sascha@24: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java, sascha@24: artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java: sascha@24: Adjusted to match new Artifact interface. sascha@24: sascha@24: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactFactory.java: sascha@24: Call artifact.setup() with this. sascha@24: sascha@24: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java: sascha@24: Removed namespace stuff. sascha@24: sascha@24: * artifacts/src/main/java/de/intevation/artifacts/ArtifactNamespaceContext.java: sascha@24: Created namespace stuff, need for XPath for e.g. sascha@24: sascha@24: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/FactoriesResource.java: sascha@24: Use new namespace stuff. sascha@24: sascha@24: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/Standalone.java: sascha@24: Added author. sascha@24: sascha@23: 2009-09-09 Sascha L. Teichmann sascha@23: sascha@23: * artifact-database/src/main/java/de/intevation/artifactdatabase/XMLUtils.java: sascha@23: Added method newXPath() to create XPaths with namespace binding. sascha@23: sascha@23: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java: sascha@23: Uses new method from XMLUtils. sascha@23: sascha@22: 2009-09-09 Sascha L. Teichmann sascha@22: sascha@22: * trunk/artifact-database/src/main/java/de/intevation/artifactdatabase/rest/FactoriesResource.java, sascha@22: trunk/artifact-database/src/main/java/de/intevation/artifactdatabase/rest/CreateResource.java: sascha@22: Removed meta data from resources. They prevented serving the right results. sascha@22: sascha@22: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java: sascha@22: Removed needless import. sascha@22: sascha@21: 2009-09-09 Sascha L. Teichmann sascha@21: sascha@21: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/CreateResource.java: sascha@21: New. Resource to create an artifact. Not working on artifact database yet. sascha@21: sascha@21: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/RestApp.java: sascha@21: Attached create to web server. sascha@21: sascha@21: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/FactoriesResource.java: sascha@21: Added meta data to Get annotation. sascha@21: sascha@20: 2009-09-09 Sascha L. Teichmann sascha@20: sascha@20: * artifact-database/pom.xml: Added dependency to restlet.ext.xml sascha@20: for XML handling in representations. sascha@20: sascha@20: * contrib/run.sh: Adjusted to fit new dependency. sascha@20: sascha@20: * artifact-database/src/main/java/de/intevation/artifactdatabase/XMLUtils.java: sascha@20: New. Handle some boiler plate XML stuff. Move more stuff of this kind sascha@20: into this file. sascha@20: sascha@20: * TODO: Added remark to move more XML stuff into XMLUtils. sascha@20: sascha@20: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/Standalone.java: sascha@20: Tell at startup on which port we are listing. sascha@20: sascha@20: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/FactoriesResource.java: sascha@20: Representation to list the available factories. sascha@20: sascha@20: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/RestApp.java: sascha@20: Attach new factory listing to web app. sascha@20: sascha@19: 2009-09-09 Sascha L. Teichmann tim@18: sascha@19: * artifact-database/doc/artifactdb-example-conf.xml: removed sascha@19: * artifact-database/doc/example-conf/conf.xml: Re-added here. sascha@19: sascha@19: The configuration is now found in a subdirectory set by the sascha@19: system property 'artifact.database.dir'. If this property is sascha@19: not set '~/.artitactdb' is used. This directory should contain sascha@19: a file 'conf.xml' with the configuration details. sascha@19: If the artifact database is started as a standalone the config sascha@19: directory is searched for 'log4j.properties' to configure the sascha@19: logging. sascha@19: The H2 database is also search in this directory with the sascha@19: name 'artifacts.db' if the connection url in config.xml is sascha@19: not overwritten. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java: sascha@19: Refactored a bit to follow the new configuration policy. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/DBConnection.java: sascha@19: Build default connection url as described. sascha@19: sascha@19: * artifact-database/doc/example-conf/log4j.properties: New. sascha@19: example logging config sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java: sascha@19: Added some more logging infos. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/App.java: sascha@19: Load the log4j configuration at startup and starts a REST standalone web server. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest: New. sascha@19: Package for REST binding. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/Standalone.java: sascha@19: Convenience wrapper to start a standalone REST web server. sascha@19: sascha@19: * artifact-database/src/main/java/de/intevation/artifactdatabase/rest/RestApp.java: sascha@19: Concrete REST application. TODO: attach restlets to interact with artifact database. sascha@19: sascha@19: * contrib/run.sh: Little start script to launch artifact database for test sascha@19: purpose from classes without the need to build packages. sascha@19: Background: The maven exec:exec goal does not work consistently for me (slt). sascha@19: At home it does, at work it doe not. Anyway. Usage: sascha@19: sascha@19: $ ./contrib/run.sh \ sascha@19: -Dartifact.database.dir=artifact-database/doc/example-conf/ \ sascha@19: de.intevation.artifactdatabase.App sascha@19: sascha@19: 2009-09-08 Tim Englich sascha@19: sascha@19: * src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java : Edited sascha@19: Constants for Namespace-URL and Namespace-Prefix added tim@18: sascha@17: 2009-09-08 Sascha L. Teichmann sascha@17: sascha@17: * artifact-database/src/main/java/de/intevation/artifactdatabase/SQL.java, sascha@17: artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java, sascha@17: artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java, sascha@17: artifact-database/src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java, sascha@17: artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java, sascha@17: artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactFactory.java: sascha@17: Integrated log4j sascha@17: sascha@17: * artifact-database/pom.xml: Added dependency to log4j sascha@17: sascha@17: * TODO: Removed remark to integrate logging. sascha@17: tim@16: 2009-09-07 Tim Englich tim@16: sascha@17: * src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java: edited sascha@17: Bug fixed in XPath Expression. Now the Nodes and not the Text of the Nodes will sascha@17: be used instantiating the ArtifactFactory. sascha@17: sascha@15: 2009-09-07 Sascha L. Teichmann sascha@15: sascha@15: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java: sascha@15: Implemented loading of artifacts from database. If the last access of an sascha@15: artifact is too long ago for its time to life, null is returned. sascha@15: sascha@15: * TODO: Added remark to implement a "killer" thread which periodically cleans the sascha@15: database from outdated artifacts and calls the endOfLife() method on those. sascha@15: sascha@14: 2009-09-07 Sascha L. Teichmann sascha@14: sascha@14: * artifact-database/src/main/java/de/intevation/artifactdatabase/SQL.java: sascha@14: Properties wrapper for SQL statements. The properties are looked up sascha@14: in resorces /sql/DRIVER.properties (DRIVER is the name of the db driver class, sascha@14: lowercased and '.' replaced by '-'. 'org.h2.Driver' turns to sascha@14: 'org-h2-driver.properties', e.g. sascha@14: sascha@14: * artifact-database/src/main/resources/sql/org-h2-driver.properties: sascha@14: SQL statements for H2 database. sascha@14: sascha@14: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java: sascha@14: Artifacts are proxies/wrapped by an special Artifact implementation sascha@14: to bound db activities transparentely to the Artifact. XXX: It has sascha@14: to be evaluated if a more direct concept like extending the Artifact API sascha@14: to store itself would be more robust for future implementations. sascha@14: TODO: Loading Artifact from db is not implemented yet. sascha@14: sascha@13: 2009-09-06 Sascha L. Teichmann sascha@13: sascha@13: * artifact-database/src/main/java/de/intevation/artifactdatabase/Backend.java: sascha@13: New. Used to wrap database presentations of artifacts into artifacts. sascha@13: sascha@13: * artifact-database/src/main/java/de/intevation/artifactdatabase/ArtifactDatabaseImpl.java: sascha@13: New. Implements a ArtifactDatabase backed by Backend. sascha@13: sascha@13: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java: sascha@13: Removed empty last line. sascha@13: sascha@13: * artifact-database/src/main/java/de/intevation/artifactdatabase/App.java: sascha@13: Wired together Backend, ArtifactDatabaseImpl and FactoryBootstrap. sascha@13: sascha@11: 2009-09-06 Sascha L. Teichmann sascha@11: sascha@11: * artifact-database/src/main/java/de/intevation/artifactdatabase/DBConnection.java: sascha@11: Typo in XPath expression. sascha@11: sascha@10: 2009-09-06 Sascha L. Teichmann sascha@10: sascha@10: * artifacts/src/main/java/de/intevation/artifacts/Artifact.java(setup): sascha@10: Added the setup() method to have symmetric counter part to endOfLife(). sascha@10: sascha@10: * artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java(timeToLiveUntouched): sascha@10: Added this method to let the factory decide how long an artifact should live in ms. sascha@10: This is not a part of the Artifact itself because this is only evaluated once when sascha@10: the artifact is created. sascha@10: sascha@10: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifact.java: sascha@10: New. Simple base class implementation of the Artifact interface. sascha@10: sascha@10: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactFactory.java: sascha@10: New. Simple base class implementation of the ArtifactFactory interface. When setup() sascha@10: on instances of this class is called, it pull ttl, name, description and sascha@10: the artifact class name from the node given. See artifactdb-example-conf.xml sascha@10: for examples. sascha@10: sascha@10: * artifact-database/pom.xml: Cleaned up XML. sascha@10: Introduced dependency to apache commons dbcp, used for pooling of the sascha@10: database connections to artifact db. sascha@10: Added parameters for the exec:exec goal to make the project sascha@10: startable without building packages. sascha@10: sascha@10: * artifact-database/doc/schema.sql: Removed AUTO_INCREMENT from primary key sascha@10: to avoid compatibility issues with other non-H2 databases (PostgreSQL, Oracle, ...) sascha@10: which have no or limited support for generated keys in the JDBC driver. Now sascha@10: using an explicit sequence. TTL ist now big int to bring the resolution to ms. sascha@10: sascha@10: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java: sascha@10: Refactored a bit to make the XPath access function usable on arbitrary XML sascha@10: documents and parts of. sascha@10: sascha@10: * artifact-database/src/main/java/de/intevation/artifactdatabase/DBConnection.java: sascha@10: New. Exposes DataSource from a apache dbcp connection pool configured by the sascha@10: global configuration file. See artifactdb-example-conf.xml for examples. sascha@10: TODO: Write some documentation about this. sascha@10: sascha@10: * artifact-database/doc/artifactdb-example-conf.xml: Adjusted to be a more realistic sascha@10: example config file. Added references to DefaultArtifact/DefaultArtifactFactory and sascha@10: demonstrate how to configure the connection pool. sascha@10: sascha@10: * TODO: Add remark to document the connection file. sascha@10: sascha@10: * artifact-database/src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java: sascha@10: Do not crash when config does not contain any factories. sascha@10: sascha@9: 2009-09-04 Sascha L. Teichmann tim@7: sascha@9: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java (getNodeXPath): sascha@9: New method to get a single node from configuration. tim@7: sascha@9: * artifacts/src/main/java/de/intevation/artifacts/Artifact.java (endOfLife): sascha@9: New method called when artifact is going to be removed from artifact data base. tim@6: sascha@9: 2009-09-04 Tim Englich sascha@9: sascha@9: * src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java (loa, sascha@9: * src/main/java/de/intevation/artifacts/ArtifactFactory.java (setup): sascha@9: New Parameter for Setop to put the ArtifactFactoryNode into the setup routine. sascha@9: sascha@9: 2009-09-04 Tim Englich sascha@9: sascha@9: * pom.xml: Edited sascha@9: Buildplugins for Maven-Compiler and Maven-Eclipse Plugin integrated. tim@6: sascha@5: 2009-09-04 Sascha L. Teichmann sascha@5: sascha@5: * artifact-database/doc/artifactdb-example-conf.xml: Example for artifact db sascha@5: configuration. sascha@5: sascha@5: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactContextFactory.java: sascha@5: New. Default implementation of ArtifactContextFactory. Creates a DefaultArtifactContext. sascha@5: sascha@5: * artifact-database/src/main/java/de/intevation/artifactdatabase/DefaultArtifactContext.java: sascha@5: New. Default implementation of ArtifactContext. sascha@5: sascha@5: * artifact-database/src/main/java/de/intevation/artifactdatabase/FactoryBootstrap.java: sascha@5: New. Class to bootstrap the context and the artifact factories. sascha@5: sascha@5: * artifact-database/src/main/java/de/intevation/artifactdatabase/App.java: Bootstrap sascha@5: factories. sascha@5: sascha@5: * artifact-database/src/main/java/de/intevation/artifactdatabase/Config.java: New. sascha@5: Loads configuration as XML from a file. The file is specified by the system sascha@5: property "artifact.database.config" and defaults to "artifactdb-conf.xml". sascha@5: The configuration can be searched via XPath. sascha@5: sascha@5: * artifact-database/pom.xml: Made de.intevation.artifactdatabase.App the main sascha@5: class for start up. sascha@5: sascha@5: * TODO: Added remark to add logging to artifact database. sascha@5: sascha@4: 2009-09-04 Sascha L. Teichmann sascha@4: sascha@4: * artifacts/src/main/java/de/intevation/artifacts/ArtifactContextFactory.java: sascha@4: New. Factory for a global context in the artifact data base. Useful to sascha@4: create shared ressources for artifacts like caches et al. sascha@4: sascha@4: * artifacts/src/main/java/de/intevation/artifacts/ArtifactDatabase.java, sascha@4: artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java, sascha@4: artifacts/src/main/java/de/intevation/artifacts/ArtifactContextFactory.java, sascha@4: artifacts/src/main/java/de/intevation/artifacts/Artifact.java: Uses the sascha@4: global context more consistent. sascha@4: sascha@4: * artifact-database/doc/schema.sql: Using BINARY instead of BLOB to sascha@4: avoid external files for each artifact blob. See H2 documentation sascha@4: for details. sascha@4: sascha@3: 2009-09-03 Sascha L. Teichmann sascha@3: sascha@3: * artifact-database/doc/schema.sql: Schema to store artifacts sascha@3: in H2 databases. sascha@3: sascha@3: * artifact-database/pom.xml: Added dependencies to H2 and sascha@3: restlet. sascha@3: sascha@3: * pom.xml: Added repository to fetch restlet. sascha@3: sascha@3: * README: Describe how to create a H2 database to store artifacts. sascha@3: TODO: Make it more general because description assumes usage of sascha@3: a unixoid system. sascha@3: sascha@2: 2009-09-03 Sascha L. Teichmann sascha@2: sascha@2: * artifact-database/**: created new sub project for the artefact sascha@2: database server. sascha@2: sascha@2: * pom.xml: Registered new sub project and made artifacts a sascha@2: sub project, too. sascha@2: sascha@2: * artifacts/pom.xml: Adjusted to make a artifacts a sub project. sascha@2: sascha@1: 2009-09-02 Sascha L. Teichmann sascha@1: sascha@1: * artifacts/src/main/java/de/intevation/artifacts/Artifact.java: sascha@1: Interface of the central component of the system. sascha@1: sascha@1: * artifacts/src/main/java/de/intevation/artifacts/ArtifactDatabase.java: sascha@1: Central place to store artifacts in. sascha@1: sascha@1: * artifacts/src/main/java/de/intevation/artifacts/ArtifactFactory.java: sascha@1: Factory to build artifacts. Works together with ArtifactDatabase. sascha@1: sascha@1: * artifacts/pom.xml: Simple maven file to compile the project. sascha@1: sascha@0: 2009-09-01 Sascha L. Teichmann sascha@0: sascha@0: * README, Changelog, Changes, NEWS, TODO: New. Initial setup