sascha@4108: 2012-01-11 Sascha L. Teichmann sascha@4108: sascha@4108: * src/main/resources/sql/flys-oracle-jdbc-oracledriver.properties: sascha@4108: Added 'FROM DUAL' clause when selecting new ids from sequences. sascha@4108: Sync process between AFT(Oracle) and FLYS(Oracle) is working now! sascha@4108: sascha@4107: 2012-01-10 Sascha L. Teichmann sascha@4107: sascha@4107: * src/main/resources/sql/flys-oracle-jdbc-oracledriver.properties: New. sascha@4107: Statements to make the FLYS database connection Oracle compatible. sascha@4107: Untested! sascha@4107: sascha@4106: 2012-01-10 Sascha L. Teichmann sascha@4106: sascha@4106: * src/main/resources/sql/aft-oracle-jdbc-oracledriver.properties: New. sascha@4106: Statements to make the AFT database connection Oracle compatible. sascha@4106: sascha@4105: 2012-01-09 Sascha L. Teichmann sascha@4105: sascha@4105: * src/main/java/de/intevation/aft/DischargeTable.java: Write sascha@4105: warning if there are discharge tables with same descriptions sascha@4105: in FLYS or AFT and ignore the redundant ones. This led sascha@4105: to an ever growing FLYS database. sascha@4105: sascha@4104: 2012-01-09 Sascha L. Teichmann sascha@4104: sascha@4104: * src/main/java/de/intevation/aft/Sync.java: Log if modifications sascha@4104: are found or not. sascha@4104: sascha@4104: * src/main/java/de/intevation/aft/River.java: Commit/rollback sascha@4104: changes on gauge if a gauge is updated. sascha@4104: sascha@4103: 2012-01-09 Sascha L. Teichmann sascha@4103: sascha@4103: * src/main/java/de/intevation/aft/DischargeTable.java: Store sascha@4103: the W/Q values in sets to prevent value duplications leading sascha@4103: to unique constraint violations in FLYS. Log a warning sascha@4103: when loading a W/Q value duplication. sascha@4103: sascha@4103: This have the nice side effect that the W/Q values are sascha@4103: written sorted by Q/W which is of benefit for FLYS. sascha@4103: sascha@4102: 2012-01-09 Sascha L. Teichmann sascha@4102: sascha@4102: * src/main/java/de/intevation/aft/River.java: Fixed logic bug sascha@4102: when writing discharge tables of an gauge existing in both dbs. sascha@4102: sascha@4102: * src/main/java/de/intevation/aft/DischargeTable.java: Moved sascha@4102: some SQL code from River here to simplify the persistence. sascha@4102: sascha@4101: 2012-01-09 Sascha L. Teichmann sascha@4101: sascha@4101: * src/main/java/de/intevation/aft/TimeInterval.java(toString): Added sascha@4101: toString() method. sascha@4101: sascha@4101: * src/main/java/de/intevation/aft/SyncContext.java: Added debug sascha@4101: logging when creating a new time inteval. sascha@4101: sascha@4101: * src/main/java/de/intevation/aft/DischargeTable.java: Added sascha@4101: warning when start and end of a time interval from AFT sascha@4101: are ordered start > end. sascha@4101: sascha@4100: 2012-01-07 Sascha L. Teichmann sascha@4100: sascha@4100: * src/main/java/de/intevation/db/SymbolicStatement.java: sascha@4100: Added setLong() method. Used when setting the official number sascha@4100: of a gauge. sascha@4100: sascha@4100: * src/main/java/de/intevation/aft/River.java: Store the new sascha@4100: discharge tables in FLYS when gauges exist in both sascha@4100: FLYS and AFT and there are discharge tables that are only in AFT. sascha@4100: Store official number as long. sascha@4100: sascha@4099: 2012-01-07 Sascha L. Teichmann sascha@4099: sascha@4099: * src/main/java/de/intevation/aft/River.java: Store sascha@4099: the W/Q differences of existing discharge tables sascha@4099: to the FLYS database. sascha@4099: sascha@4099: * src/main/java/de/intevation/aft/DischargeTable.java: Added sascha@4099: getter/setter for W/Q values. sascha@4099: sascha@4098: 2012-01-06 Sascha L. Teichmann sascha@4098: sascha@4098: * src/main/java/de/intevation/aft/River.java: Do the pairing sascha@4098: of discharge table of a gauge that needs updates. TODO: sascha@4098: Build the W/Q difference of found FLYS/AFT matches and sascha@4098: create the discharge tables in FLYS that are found in AFT. sascha@4098: sascha@4097: 2012-01-06 Sascha L. Teichmann sascha@4097: sascha@4097: * src/main/resources/sql/flys-common.properties: Added statement sascha@4097: to load all discharge tables of a given gauge. sascha@4097: sascha@4097: * src/main/java/de/intevation/aft/DischargeTable.java: sascha@4097: sascha@4097: * src/main/java/de/intevation/aft/DIPSGauge.java: Store sascha@4097: the official number, too. sascha@4097: sascha@4097: * src/main/java/de/intevation/aft/River.java: In case of sascha@4097: updating a gauge load all discharge tables of that gauge sascha@4097: from FLYS and AFT. TODO: Do pairing based on the descriptions. sascha@4097: sascha@4097: * src/main/java/de/intevation/aft/DischargeTable.java: Code sascha@4097: to load the discharge table from FLYS and AFT. sascha@4097: sascha@4096: 2012-01-06 Sascha L. Teichmann sascha@4096: sascha@4096: * src/main/java/de/intevation/aft/WQDiff.java: New. sascha@4096: Calculates the difference of two W/Q value table of a sascha@4096: discharge table. This can be used to write an optimized sascha@4096: change set in terms of executed SQL to the FLYS database. sascha@4096: sascha@4096: * src/main/java/de/intevation/aft/WQ.java: Changed the EPS_CMP sascha@4096: comparator to first sort by Q and then by W because the Qs sascha@4096: are more distinct and the dominant component. sascha@4096: sascha@4096: * src/main/resources/sql/flys-common.properties: Added statement sascha@4096: to delete W/Q values. sascha@4096: sascha@4095: 2012-01-06 Sascha L. Teichmann sascha@4095: sascha@4095: * src/main/java/de/intevation/utils/XML.java: Added code sascha@4095: to send/receive documents from streams. sascha@4095: sascha@4095: * src/main/java/de/intevation/aft/Notification.java: New. sascha@4095: Sends XML documents via HTTP POST to given URLs. sascha@4095: sascha@4095: * src/main/java/de/intevation/aft/Sync.java: Send notifications sascha@4095: if the FLYS database was modified. Useful to invalidate caches sascha@4095: in the artifact server. sascha@4095: sascha@4094: 2012-01-05 Sascha L. Teichmann sascha@4094: sascha@4094: * doc/conf.xml: Added demo notification url. sascha@4094: sascha@4094: * src/main/java/de/intevation/aft/River.java, sascha@4094: src/main/java/de/intevation/aft/Rivers.java, sascha@4094: src/main/java/de/intevation/aft/Sync.java: Modifications sascha@4094: are bubbled up to main() to send notifactions. sascha@4094: sascha@4093: 2012-01-05 Sascha L. Teichmann sascha@4092: sascha@4092: * src/main/java/de/intevation/aft/DischargeTable.java: Store sascha@4092: W/Q values to FLYS. sascha@4092: sascha@4092: * src/main/resources/sql/flys-common.properties: Added statements sascha@4092: to store W/Q values into FLYS database. sascha@4092: sascha@4093: 2012-01-05 Sascha L. Teichmann sascha@4091: sascha@4091: * src/main/java/de/intevation/aft/WQ.java: New. W/Q model used sascha@4091: for AFT and FLYS. sascha@4091: sascha@4091: * src/main/java/de/intevation/aft/DischargeTable.java: Holds sascha@4091: a list of its W/Q values now. Values are loadable from AFT sascha@4091: and FLYS. sascha@4091: sascha@4091: * src/main/resources/sql/aft-common.properties, sascha@4091: src/main/resources/sql/flys-common.properties: Added statements sascha@4091: to load W/Q values for a given discharge table. sascha@4091: sascha@4090: 2012-01-04 Sascha L. Teichmann sascha@4090: sascha@4090: * src/main/java/de/intevation/aft/SyncContext.java(fetchOrCreateFLYSTimeInterval): sascha@4090: Create FLYS time intervals if they are not in the database. sascha@4090: sascha@4090: * src/main/java/de/intevation/aft/DischargeTable.java: New. Model sascha@4090: for discharge tables. sascha@4090: sascha@4090: * src/main/java/de/intevation/aft/TimeInterval.java: Added sascha@4090: convinience constructors. sascha@4090: sascha@4090: * src/main/java/de/intevation/aft/River.java: Store discharge tables. sascha@4090: sascha@4090: * src/main/java/de/intevation/aft/Sync.java: Exit with errorcode sascha@4090: if syncing fails. sascha@4090: sascha@4090: * src/main/resources/sql/aft-common.properties: Fetch the sascha@4090: description of a discharge table, too. sascha@4090: sascha@4090: * src/main/resources/sql/flys-common.properties: Added statements sascha@4090: to create time intevals and discharge tables. sascha@4090: sascha@4089: 2012-01-03 Sascha L. Teichmann sascha@4089: sascha@4089: * src/main/java/de/intevation/aft/TimeInterval.java: New. sascha@4090: Model for FLYS time intervals. sascha@4089: sascha@4089: * src/main/java/de/intevation/aft/SyncContext.java: Preload sascha@4089: existing time intervals from FLYS. sascha@4089: sascha@4089: * src/main/java/de/intevation/aft/Sync.java: Call init() sascha@4089: after construction to ensure that the db connections are sascha@4089: closed properly. sascha@4089: sascha@4089: * src/main/resources/sql/flys-common.properties: Added statement sascha@4089: to fetch the time intervals from FLYS. sascha@4089: sascha@4088: 2012-01-03 Sascha L. Teichmann sascha@4088: sascha@4088: * src/main/java/de/intevation/aft/River.java: Fetch discharge table sascha@4088: infos from AFT. sascha@4088: sascha@4088: * src/main/resources/sql/aft-common.properties: Added statement to fetch sascha@4088: infos from ABFLUSSTAFEL. sascha@4088: sascha@4087: 2012-01-02 Sascha L. Teichmann sascha@4087: sascha@4087: * src/main/resources/sql/flys-common.properties: Added statements sascha@4087: to create gauges in FLYS. sascha@4087: sascha@4087: * src/main/java/de/intevation/aft/DIPSGauge.java: Make more fields sascha@4087: accessible for gauge creation in FLYS. sascha@4087: sascha@4087: * src/main/java/de/intevation/aft/River.java: Store new gauges sascha@4087: in FLYS. sascha@4087: sascha@4087: * src/main/java/de/intevation/db/ConnectedStatements.java: sascha@4087: Added logging, make methods of transaction handling public. sascha@4087: sascha@4087: * src/main/java/de/intevation/db/SymbolicStatement.java(setDouble): sascha@4087: Fixed argument type problem. sascha@4087: sascha@4086: 2012-01-02 Sascha L. Teichmann sascha@4086: sascha@4086: * src/main/java/de/intevation/db/ConnectionBuilder.java: sascha@4086: Set auto commit of new connection to false to enable transaction. sascha@4086: sascha@4086: * src/main/java/de/intevation/db/ConnectedStatements.java: sascha@4086: Added methods to begin, commit and rollback transactions. sascha@4086: Relies on savepoint support which is check by database metadata. sascha@4086: sascha@4085: 2011-12-22 Sascha L. Teichmann sascha@4085: sascha@4085: * src/main/java/de/intevation/aft/River.java: Figure out sascha@4085: which gauges must be updated, which must be created. sascha@4085: sascha@4085: * src/main/java/de/intevation/aft/DIPSGauge.java: Store sascha@4085: info from AFT and FLYS, too. sascha@4085: sascha@4085: * src/main/resources/sql/flys-common.properties: Fetch the sascha@4085: official number, too. sascha@4084: 2011-12-20 Sascha L. Teichmann sascha@4084: sascha@4084: * src/main/java/de/intevation/aft/River.java: Removed sascha@4084: index DIPS gauge number -> DIPS gauge. sascha@4084: sascha@4084: * src/main/java/de/intevation/aft/SyncContext.java: Readded sascha@4084: here, because the index can be shared by all rivers. sascha@4084: sascha@4083: 2011-12-20 Sascha L. Teichmann sascha@4083: sascha@4083: * doc/repair.xsl: Repair XSL transform which brings the sascha@4083: DIPS gauge numbers of the 15 FLYS gauges to the same sascha@4083: numbers as they are used in "Pegel Online". sascha@4083: sascha@4083: !!! The purpose of this script is to do more repairing !!! sascha@4083: sascha@4083: * doc/pegelstationen.xml: Sub document of repair. Used sascha@4083: for lookup the correct pegel numbers. sascha@4083: sascha@4083: * doc/conf.xml: Changed to optionally load the repair XSLT. sascha@4083: sascha@4083: * src/main/java/de/intevation/aft/Sync.java: Load the sascha@4083: repair XSL transformation if configured. sascha@4083: sascha@4083: * src/main/java/de/intevation/utils/XML.java: Added code sascha@4083: to make XSL transforms possible. sascha@4083: sascha@4083: * src/main/java/de/intevation/aft/River.java, sascha@4083: src/main/java/de/intevation/aft/Rivers.java: Fixed logging. sascha@4083: sascha@4082: 2011-12-20 Sascha L. Teichmann sascha@4082: sascha@4082: * src/main/java/de/intevation/aft/River.java, sascha@4082: src/main/java/de/intevation/aft/DIPSGauge.java: Make DIPS check sascha@4082: more verbose. sascha@4082: sascha@4076: 2011-12-16 Sascha L. Teichmann sascha@4076: sascha@4076: * src/main/java/de/intevation/db/SymbolicStatement.java: sascha@4076: Made the setX() methods cascadable. sascha@4076: sascha@4076: * src/main/java/de/intevation/aft/River.java: Fetches sascha@4076: the gauges from the database. sascha@4076: sascha@4076: * src/main/resources/sql/aft-common.properties, sascha@4076: src/main/resources/sql/flys-common.properties: Added gauges sascha@4076: statements. sascha@4076: sascha@4075: 2011-12-14 Sascha L. Teichmann sascha@4075: sascha@4075: * src/main/java/de/intevation/db/SymbolicStatement.java: sascha@4075: Added execute(), executeQuery() & Co. sascha@4075: sascha@4075: * src/main/java/de/intevation/aft/IdPair.java: New. Base class sascha@4075: for id pairs to identify same object in both databases. sascha@4075: sascha@4075: * src/main/java/de/intevation/aft/River.java: New. To sync sascha@4075: the objects of one river. sascha@4075: sascha@4075: * src/main/java/de/intevation/aft/Rivers.java: Figure out sascha@4075: only the rivers which are in both databases and sync them. sascha@4075: sascha@4075: * src/main/java/de/intevation/aft/Sync.java: Only pass the sascha@4075: connected statements to the sync. sascha@4075: sascha@4075: * src/main/resources/sql/flys-common.properties: Fixed SQL for sascha@4075: fetching the rivers. sascha@4075: sascha@4075: * pom.xml: Added dependency to PostgreSQL. sascha@4075: sascha@4075: * doc/conf.xml: SQLite needs a driver class. sascha@4075: sascha@4074: 2011-12-13 Sascha L. Teichmann sascha@4074: sascha@4074: * src/main/java/de/intevation/db/ConnectionBuilder.java: Removed sascha@4074: statements here. sascha@4074: sascha@4074: * src/main/java/de/intevation/db/Statements.java: Added method sascha@4074: to access the hole map of statements. sascha@4074: sascha@4074: * src/main/java/de/intevation/db/ConnectedStatements.java: New. sascha@4074: A cache that binds prepared statements to a connection. sascha@4074: sascha@4073: 2011-12-13 Sascha L. Teichmann sascha@4073: sascha@4073: * src/main/java/de/intevation/db/ConnectionBuilder.java: Added sascha@4073: access to Statements. sascha@4073: sascha@4073: * src/main/java/de/intevation/db/SymbolicStatement.java: New. sascha@4073: Made top level from inner class of Statements. sascha@4073: sascha@4073: * src/main/java/de/intevation/db/Statements.java: Moved SymbolicStatement sascha@4073: out to top level class. sascha@4073: sascha@4073: * src/main/java/de/intevation/aft/Rivers.java: Syncing beginns at sascha@4073: river level. sascha@4073: sascha@4073: * src/main/java/de/intevation/aft/Sync.java: Start the syncing with sascha@4073: the rivers of both dbs. sascha@4073: sascha@4072: 2011-12-13 Sascha L. Teichmann sascha@4072: sascha@4072: * doc/conf.xml: Adjusted structure to be more generic. sascha@4072: sascha@4072: * src/main/java/de/intevation/utils/XML.java: Allow namespace aware sascha@4072: file parsing. sascha@4072: sascha@4072: * src/main/java/de/intevation/db/ConnectionBuilder.java: New. Evaluate sascha@4072: config and builds a new db connection. sascha@4072: sascha@4072: * src/main/java/de/intevation/aft/Sync.java: Load config file. sascha@4072: sascha@4072: * pom.xml: Added dependency to SQLite JDBC driver. sascha@4072: sascha@4071: 2011-12-13 Sascha L. Teichmann sascha@4071: sascha@4071: * doc/conf.xml: New. Configuration file. sascha@4071: sascha@4070: 2011-12-13 Sascha L. Teichmann sascha@4070: sascha@4070: * ChangeLog: New. Argh! Forgot to check it in before. sascha@4070: sascha@4070: * src/main/java/de/intevation/utils/XML.java: New. XML/XPath support. sascha@4070: Mainly a stripped down version of sascha@4070: de.intevation.artifacts.common.utils.XMLUtils sascha@4070: sascha@4070: 2011-12-12 Sascha L. Teichmann sascha@4070: sascha@4070: * src/main/java/de/intevation/db/Statements.java: Added support sascha@4070: for symbolic prepared statements. sascha@4070: sascha@4070: 2011-12-12 Sascha L. Teichmann sascha@4070: sascha@4070: * src/main/java/de/intevation/db/Statements.java: New. Load statements sascha@4070: from ressources. sascha@4070: sascha@4070: * src/main/resources/sql/aft-common.properties: New. Common statements sascha@4070: for the AFT side of the sync. sascha@4070: sascha@4070: * src/main/resources/sql/flys-common.properties: New. Common statements sascha@4070: for the FLYS side of the sync. sascha@4070: sascha@4070: * pom.xml: Added dependency to log4j