You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-dev@db.apache.org by Thomas Fischer <Fi...@seitenbau.net> on 2005/01/21 18:35:54 UTC

Generator: comparison TORQUE_3_1_BRANCH vs HEAD




Hi,

I have looked into the differences between the CVS branches
TORQUE_3_1_BRANCH and HEAD in the Torque generator. In short, it seems that
the HEAD branch is more advanced than the TORQUE_3_1_BRANCH, except for
Henning's correctGetters.

Improvements in TORQUE_3_1_BRANCH
Henning's correctGetters - improvement

Improvements in HEAD:
Refactoring of the model
replaced db.props files by java classes
removed support for "autoincrement" and "sequence" (is now "native")

In my opinion, we should not loose the improvements made in HEAD. It seems
to be feasible to incorporate the correctGetters in HEAD.

    Thomas


Changes in details:


Different version of StringUtils, version in 3_1 is newer. Main difference
seems to be name of method capitalise/capitalize

src/java:
Package torque.engine
EngineException: no change

Package torque.engine.database.model
AppData.java is removed in HEAD. This means we cannot handle more than one
database at a time. No idea whether that is needed.

Column.java:
size,torqueType,defaultValue was moved to new member Domain
columnType is not needed any more
...


ConstraintNameGenerator: adjusted to other changes
Database.java: Does not contain AppData any more, but additionally contains
a Map of Domains and a filename
getTables() returns List, not array

Domain.java: added in HEAD, holds some of the data of column.java. Holds
all data for a column data type (like, which is its sql name, size,...)
I am not content with the name of the class, is not intuitive. Call it
ColumnType ???
private String name; // unique identifier for the domain, seems to be used
in xml generation
private String description; // not heavily used except in loading from xml
private String size;  // from Column.java
private String scale; // e.g. in Oracle number (10,2);
private SchemaType torqueType; // from Column.java
private String sqlType; // how the type of the column is called in SQL.
Depends from Platform.
private String defaultValue; // from Column.java

IdMethod: Autoincrement and sequence are not supported any more
IdMethodParameter: No changes
Index.java: slight code improvements in HEAD
Inheritance.java: No changes
JavaNameGenerator: Difference in version of StringUtils
NameFactory: No changes
SchemaType: Only Exists in Head. Enumeration for all types in schema.xml,
previously constants in TypeMap.java
Table.java: some methods return list instead of arrays
autoincrement and sequence support is dropped
in 3_1, the correctGetters are added

TypeMap.java: Some constants have been moved to SchemaType
Slight differences in BIT_OBJECT_TYPE
Slight differences in getTorqueType()

Unique.java: no change

package torque.engine.database.transform:
DTDResolver: Name of dtd changed
SQLToAppData changes because of removal of AppData
XmlToAppData changes because of removal of AppData, can handle new Element
"domain"
XmlToData Tabs replaced by spaces in HEAD

package torque.engine.platform
Does not exist in 3_1, replaces db.props files

package torque.engine.sql
ParseException no changes
SqlScanner: no changes
Token: No changes

package torque.task
PackageAsPathTask  No changes

TorqueDataDumpTask:
Improved javadoc
statement is filled in initControlContext()
uses jdbc instead of velocity. The new tableTool.hasNext() needs to be
optimized.

TorqueDataModelTask
improved javadoc
path to db.props is not needed any longer
Database used instead of AppData

TorqueDataSqlTask:
Use Database instead of AppData

TorqueDocumentationTask: No changes
TorqueJdbcTransformTask: adjusted to changes in Column.java
TorqueSQLExec: No changes
TorqueSQLTask: uses Database instead of AppData
TorqueSQLTransformTask: uses Database instead of AppData

src/test:
package torque.engine.database
TestPackageHandling: uses Database instead of AppData
package-schema.xml: dtd location changed
package2-schema.xml: dtd location changed

package torque.engine.database.model
Added lost of test cases in HEAD: ColumnTest, DomainTest, MssqlDomainTest,
OracleDomainTest, PostgresqlDomainTest, TypeMapTest
and additional file domaintest-schema.xml

NameFactoryTest:
Added new Testcase TestException
Changed from AppData to Database

TableTest:
changed from AppData to db
Coder cleanup in HEAD
lots of new test cases in HEAD

tabletest-schema.xml: extended because of changes in TableTest

package torque.engine.database.transform : Does not exist in 3_1
package torque.engine.platform: Does not exist in 3_1

src/conf:
build-torque.xml:
newer libraries are used in 3_1
path to db.props is removed

build.properties: No change
commons-logging.properties: No change
default.properties: lots of old properties have been removed in HEAD, but
no relevant changes
log4j.properties: no changes
simplelog.properties: no changes

src/dtd:
database.dtd:
Added support of domain/scale elements
Column attribute type is #IMPLIED instead od default type varchar
support for autoincrement/sequence removed

src/schema
id-table-schema: no changes

src/templates:
data/dump:
Control.vm: only one database allowed
bottom.vm, row.vm, top.vm: no changes

data:
Control.vm: only one database allowed
dataset.vm, table.vm: no changes

doc/anakia:
datamodel.vm: only one database is supplied
table.vm: no change

doc/html:
datamodel.vm: only one database is supplied
table.vm: no change

doc:
Control.vm: use property FileNamed instead of name for generating output
filenames

ojb/model:
New files Manager, BaseManager and BaseObject

Object: Most functionality has moved from Object to BaseObject. Why ???

Control.vm:
Only one databse allowed
parses the additional files

ojb/model_broken:
No changes.

ojb/repository:
Control.vm: Datamodel replaced by database
MainRepository.vm: Use DataModel.Name instead of DataModel.shortName in
some places
Repository.vm: database is not taken from dataModel any more

om:
BaseManager: no changes

Control.vm:
db.props is not loaded any more
only one dataModel is supplied
correctGetters added to 3_1

ExtensionManager: No changes
ExtensionObjects: No changes
ExtensionPeer: No changes
Interface.vm: No changes
MapBuilder.vm:
removed generation of deprecated methods
removed support for id-generation types "autoincrement" and "sequence"

MultiExtendObject: no difference

Object.vm:
correctGetters added to 3_1
difference in tabbing
removal of unused variables in 3_1
slight differences in javadocs
different code adjustments in HEAD and 3_1

ObjectWithManager.vm:
correctGetters added to 3_1 (though not everywhere ???, search for
get${column.JavaName}(), set${pk.JavaName} )
different improvements in tabbing done in HEAD and in 3_1
removal of unused variables in 3_1
different code adjustments in HEAD and 3_1

Peer.vm
Difference in method names: buildCriteria() vs buildSelectCriteria(). 3_1
seems to be newer (check !!!)
Additional methods are added in 3_1 (getByPk(), doSelectJoinXXX(),
doSelectJoinAllExceptXXX() each with connection)
correctGetters added to 3_1

sql/base/axion,cloudscape,db2, db2400, ypsersonic, interbase, msaccess,
mssql, oracle, sapdb, sybase
columns newer in HEAD (probably autoincrement changes and removal of
db.props)
db.props removed from HEAD
other files: no change

sql/base/myaql: additionally to the above, table.vm is newer in head

sql/base/derby only exists in 3_1

sql/base/postgresql: To be checked in Detail !
columns, table : check in repository
db.props removed
drop, foreignkey, index, primarykey, tablefk, unique : no difference
sequence: removed in head

/sql/base:
Control.vm: adjusted to AppData->Database change

sql/db-init: no change

sql/id-table:
Control.vm: adjusted to AppData->Database change
idtable.derby added in 3_1
other files: no changes

sql/load: no changes

xdocs:
index.xml, navigation.xml: no change
properties-reference: differences
schema-reference:
removed autoincrement and sequence attributes

root dir:
LICENSE.txt : no change
build-gump.xml: no change
build.xml: removed in HEAD
maven.xml:: differences
project.properties: no change
project.xml: differences

added docs for external-schema element
schanged subsections into sections


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org