[kforge-dev] kforge schema diff 0.12 to 0.13

John Bywater john.bywater at appropriatesoftware.net
Thu Jul 19 20:45:30 UTC 2007


So, to continue this schema change consideration, the code will add the 
Image table automatically, so there's no need to write SQL for that. 
However, I don't think KForge needs an Image class, so this bequest 
could be refused by adding "def loadImage(self): pass" to the 
kforge.dom.builder.ModelBuilder class.

As refused bequests are a bad smell, it is clear that the builder 
probably needs separating so that domainmodel applications can start 
with a very minimal model builder, just like they can start with a very 
minimal dm.command.InitialiseDomainModel.

Certainly, the current kforge.dom.builder.ModelBuilder loads far to many 
domain classes for things to be stable.

Anyway, those lastModified attributes arise from the introduction of 
this attribute to the SimpleDatedObject domain model class. It broadens 
the meaning of a dated object, to enable indication of how old the 
information is.

The KForge classes listed are all derived from the StandardDomainObject, 
which inherits from SimpleDatedObject. But most KForge classes are 
SimpleDomainObjects, and don't have this aspect. It's just the major 
domain objects, and it's so that we can present how recent stuff is.

Also, it doesn't really affect performance, as it is only done just 
before an updated domain object is saved, with the new value carried 
along with the changed attributes into the same SQL statement.

So, I'd say we just need to add those attributes to those classes. The 
new code won't do that automatically at the moment, but it might be just 
as easy to change the code as to write the database update script, 
instructions (and have everybody run it).

Bye for now,

John.



John Bywater wrote:

> Below is the report on changes to database schema introduced by 
> kforge-0.13 in respect of kforge-0.12.
>
> Best, John.
>
>
> -------------------------------------------------------
>
> Classes changed:
>   added 'Image' class
>   added 'Plugin lastModified' attr
>   added 'System lastModified' attr
>   added 'System mode' attr
>   added 'Project lastModified' attr
>   added 'Person lastModified' attr
>   added 'Session lastModified' attr
>
>------------------------------------------------------------------------
>
>_______________________________________________
>kforge-dev mailing list
>kforge-dev at lists.okfn.org
>http://lists.okfn.org/mailman/listinfo/kforge-dev
>  
>


-- 
Appropriate Software Foundation
Registered in England and Wales
17 Chapel Street, Hyde Cheshire
Company number: 04977110
W: appropriatesoftware.net
T: 0870 720 2944
M: 0781 139 2292






More information about the kforge-dev mailing list