dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #01658
Re: Should we remove the Source object?
Lars I think you are right. I think the household/person was the closest I
think we got to considering deriving something else from source other than
organisation unit.
I'd put it on notice - if you don't get any suggested use cases before the
weekend (or some other arbitrary point in time) then chop it. I don't
imagine it will have an enormous performance impact, but getting leaner is
good.
Regards
Bob
2009/8/26 Lars Helge Øverland <larshelge@xxxxxxxxx>
> Hi,
>
> I have been thinking about removing the Source object from the API.
> The abstract Source class was introduced in the model in order to
> allow for multiple implementations of Sources in the system. Currently
> we only have the OrganisationUnit object extending Source. We now see
> eg. with Abyot's CHIS module that even if we need a new kind of
> Source; the Patient, we still need the OrganisationUnit reference in
> DataValue.
>
> The downsides of keeping Source are that it
>
> - Increases complexity.
> - Makes JDBC/Hibernate operations slower, since the Source table must
> be updated first, then the orgunit table.
> - Entails problems when people manually modifies the database (which
> they really should not) as they always forget to update the source
> table when adding/removing from the organisationunit table.
>
> The only database update this would require is to set the
> "organisationunitid" field in the "organisationunit" table to
> auto-increment. I believe Hibernate will take care of this.
>
> Based on this I opt for removing the Source object and moving the
> OrganisationUnit object into the core.
>
> Are there other aspects regarding this that should be mentioned? Any
> objections?
>
>
> regards
>
>
> Lars
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
> Post to : dhis2-devs@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
> More help : https://help.launchpad.net/ListHelp
>
Follow ups
References