r18623 - gnucash/trunk - Remove the old, obsolete postgres backend and its tools
Geert Janssens
gjanssens at code.gnucash.org
Mon Feb 8 05:14:30 EST 2010
Author: gjanssens
Date: 2010-02-08 05:14:30 -0500 (Mon, 08 Feb 2010)
New Revision: 18623
Trac: http://svn.gnucash.org/trac/changeset/18623
Removed:
gnucash/trunk/contrib/pgsql-1.8-import/
gnucash/trunk/src/backend/postgres/
Modified:
gnucash/trunk/.gitignore
gnucash/trunk/po/POTFILES.skip
gnucash/trunk/src/README.modules
gnucash/trunk/src/doc/backend-api.txt
gnucash/trunk/src/doc/books.txt
gnucash/trunk/src/doc/lots.txt
gnucash/trunk/src/engine/gnc-commodity.c
gnucash/trunk/src/engine/gnc-commodity.h
Log:
Remove the old, obsolete postgres backend and its tools
I also changed some of the documentation that referred to it, but there are still some
references left in the (unmaintained ?) design documents.
Modified: gnucash/trunk/.gitignore
===================================================================
--- gnucash/trunk/.gitignore 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/.gitignore 2010-02-08 10:14:30 UTC (rev 18623)
@@ -59,17 +59,6 @@
po/stamp-it
py-compile
src/app-utils/gnucash
-src/backend/postgres/base-autogen.c
-src/backend/postgres/base-autogen.h
-src/backend/postgres/check-autogen.c
-src/backend/postgres/check-autogen.h
-src/backend/postgres/functions.c
-src/backend/postgres/kvp-autogen.c
-src/backend/postgres/kvp-autogen.h
-src/backend/postgres/table-audit.c
-src/backend/postgres/table-create.c
-src/backend/postgres/table-drop.c
-src/backend/postgres/table-version.c
src/bin/gnucash
src/bin/gnucash-bin
src/bin/gnucash-env
Modified: gnucash/trunk/po/POTFILES.skip
===================================================================
--- gnucash/trunk/po/POTFILES.skip 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/po/POTFILES.skip 2010-02-08 10:14:30 UTC (rev 18623)
@@ -13,21 +13,6 @@
src/import-export/binary-import/binary-import.glade
src/import-export/binary-import/druid-commodity.c
src/import-export/binary-import/gncmod-binary-import.c
-src/backend/postgres/PostgresBackend.c
-src/backend/postgres/account.c
-src/backend/postgres/book.c
-src/backend/postgres/builder.c
-src/backend/postgres/checkpoint.c
-src/backend/postgres/demo.c
-src/backend/postgres/escape.c
-src/backend/postgres/events.c
-src/backend/postgres/gncquery.c
-src/backend/postgres/kvp-sql.c
-src/backend/postgres/price.c
-src/backend/postgres/putil.c
-src/backend/postgres/txn.c
-src/backend/postgres/txnmass.c
-src/backend/postgres/upgrade.c
src/gnome-utils/glade/dialog-database-connection.glade
src/libqof/qof/qofgobj.c
src/libqof/qof/qofquery-deserial.c
Modified: gnucash/trunk/src/README.modules
===================================================================
--- gnucash/trunk/src/README.modules 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/README.modules 2010-02-08 10:14:30 UTC (rev 18623)
@@ -22,9 +22,11 @@
engine The engine module, without any backends
-backend/file Binary and XML (v1 and v2) backends
-backend/postgres Postgres backend
+backend/xml Binary and XML (v1 and v2) backends
+backend/dbi SQL based backends: postgres, mysql, sqlite3 (all
+ via the dbi interface)
+
register/ledger-core The xacc SplitLedger and MultiLedger parts formerly
in src/
register/register-core Toolkit independent register code, formerly in
Modified: gnucash/trunk/src/doc/backend-api.txt
===================================================================
--- gnucash/trunk/src/doc/backend-api.txt 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/doc/backend-api.txt 2010-02-08 10:14:30 UTC (rev 18623)
@@ -57,7 +57,7 @@
search type CANNOT change between a compile and the execute,
but the query infrastructure maintains that invariant.
-In this manner, a Backend (e.g. the Postgres backend) can compile the
+In this manner, a Backend (e.g. the dbi backend) can compile the
Query into its own format (e.g. a SQL expression) and then use the
pre-compiled expression every run instead of rebuilding the
expression.
Modified: gnucash/trunk/src/doc/books.txt
===================================================================
--- gnucash/trunk/src/doc/books.txt 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/doc/books.txt 2010-02-08 10:14:30 UTC (rev 18623)
@@ -304,25 +304,13 @@
Uses FreqSpec.[ch] and the widget in gnc-frequency.[ch] to allow
the user to specify the frequency of book closings.
-- The Postgres backend has been modified to support multiple books.
- All books are stored in the same database; there is no performance
- penalty for storing all books together in the same SQL database,
- because they can be easily picked apart by an appropriate SQL query.
- (Not tested, probably borken).
-
- Period-closing does not delete anything from the SQL database. That's
- the design. The core assumption is that having lots of old data in the
- SQL DB wouldn't slow it down, and thus, nothing needed to be actually
- deleted. So it doesn't delete anything.
-
- However, an SQL admin, if they were desperate to trim the DB size,
- could DELETE FROM * WHERE bookguid='asdfasdfasdf';
-
- The XML-file backend can store multiple books in one file. There
is currently minimal support for writing out multiple books,
one per file (this enables faster load, by not loading old books).
There is currently no support for loading multiple books from multiple
files.
+
+- (Details about the dbi backend are missing.)
\section periodsannounce ANNOUNCE: Book Closing Beta 2
Modified: gnucash/trunk/src/doc/lots.txt
===================================================================
--- gnucash/trunk/src/doc/lots.txt 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/doc/lots.txt 2010-02-08 10:14:30 UTC (rev 18623)
@@ -513,11 +513,6 @@
a 'big picture' view of how its done. (September 2003)
- A basic lot-viewing GUI is in src/gnome/lot-viewer.c
This GUI cannot 'edit' lots. (August 2003)
-- The Postgres backend does not yet support lots.
- XXX In particular, the programming API for Lots is currently
- non-transactional. There's no dirty flag, and the backend is not
- signalled that the lots have changed. This is the case both for
- Scrub2.c and for src/gnome/lot-viewer.c (which changes KVP's).
- Need to write extensive test cases to verify the rather complex
constraints between the gains and lots and splits.
- Need to write a cap-gains report!
Modified: gnucash/trunk/src/engine/gnc-commodity.c
===================================================================
--- gnucash/trunk/src/engine/gnc-commodity.c 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/engine/gnc-commodity.c 2010-02-08 10:14:30 UTC (rev 18623)
@@ -73,7 +73,6 @@
char * cusip; /* CUSIP or other identifying code */
int fraction;
char * unique_name;
- gint16 mark; /* user-defined mark, handy for traversals */
gboolean quote_flag; /* user wants price quotes */
gnc_quote_source * quote_source; /* current/old source of quotes */
@@ -584,7 +583,6 @@
priv->mnemonic = CACHE_INSERT("");
priv->cusip = CACHE_INSERT("");
priv->fraction = 10000;
- priv->mark = 0;
priv->quote_flag = 0;
priv->quote_source = NULL;
priv->quote_tz = CACHE_INSERT("");
@@ -857,8 +855,6 @@
g_free(priv->unique_name);
priv->unique_name = NULL;
- priv->mark = 0;
-
#ifdef ACCOUNTS_CLEANED_UP
/* Account objects are not actually cleaned up when a book is closed (in fact
* a memory leak), but commodities are, so in currently this warning gets hit
@@ -920,7 +916,6 @@
dest_priv->namespace = src_priv->namespace;
- dest_priv->mark = 0;
dest_priv->fraction = src_priv->fraction;
dest_priv->quote_flag = src_priv->quote_flag;
@@ -1038,17 +1033,6 @@
}
/********************************************************************
- * gnc_commodity_get_mark
- ********************************************************************/
-
-gint16
-gnc_commodity_get_mark(const gnc_commodity * cm)
-{
- if(!cm) return 0;
- return GET_PRIVATE(cm)->mark;
-}
-
-/********************************************************************
* gnc_commodity_get_auto_quote_control_flag
********************************************************************/
@@ -1222,17 +1206,6 @@
}
/********************************************************************
- * gnc_commodity_set_mark
- ********************************************************************/
-
-void
-gnc_commodity_set_mark(gnc_commodity * cm, gint16 mark)
-{
- if(!cm) return;
- GET_PRIVATE(cm)->mark = mark;
-}
-
-/********************************************************************
* gnc_commodity_set_auto_quote_control_flag
********************************************************************/
Modified: gnucash/trunk/src/engine/gnc-commodity.h
===================================================================
--- gnucash/trunk/src/engine/gnc-commodity.h 2010-02-07 20:51:44 UTC (rev 18622)
+++ gnucash/trunk/src/engine/gnc-commodity.h 2010-02-08 10:14:30 UTC (rev 18623)
@@ -432,16 +432,6 @@
*/
int gnc_commodity_get_fraction(const gnc_commodity * cm);
-/** Retrieve the 'mark' field for the specified commodity.
- *
- * @note This is a private field used by the Postgres back end.
- *
- * @param cm A pointer to a commodity data structure.
- *
- * @return The value of the mark field.
- */
-gint16 gnc_commodity_get_mark(const gnc_commodity * cm);
-
/** Retrieve the automatic price quote flag for the specified
* commodity. This flag indicates whether stock quotes should be
* retrieved for the specified stock.
@@ -938,16 +928,6 @@
@{
*/
-/** Set the 'mark' field for the specified commodity.
- *
- * @note This is a private field used by the Postgres back end.
- *
- * @param cm A pointer to a commodity data structure.
- *
- * @param mark The new value of the mark field.
- */
-void gnc_commodity_set_mark(gnc_commodity * cm, gint16 mark);
-
/** You proably shouldn't be using gnc_commodity_table_new() directly,
* its for internal use only. You should probably be using
* gnc_commodity_table_get_table()
More information about the gnucash-changes
mailing list