Forum OpenACS Development: Re: Joining to acs_objects and package-aware packages

Collapse
Posted by Peter Marklund on
Joel,

"Try not to write queries in your application that join against acs_objects."

Remove this sentence as it is misleading. I think the key sentences in the document that conveys what they are getting at is:

"Second, in order for this to work, the various parts of the OpenACS Objects data model must be interpreted in the same way by all applications that use the data model. Therefore, assigning any application-specific semantics to any part of the core data model is a bad thing to do, because then the semantics of the data model are no longer independent of the application."

I think what spurred this warning was that applications were using context_id to indicate object context (or navigation) hierarchy rather than merely permission inheritance.

My vote is to take out the last bullet point altogether. The issue with the context_id is not important enough to warrant being in the summary. Or, if it is to be in the summary, make the bullet say something like:

"Don't rely on the context_id column in the acs_objects table to signify the hierarchy of objects. The column is merely intended for inheritance of permissions"

I happen to be one of those people who think that the context_id column should in fact indicate *both* the permission inheritance *and* the object hierarchy. Sometimes when package developers misuse the core it's an indication that the core should change. I'm not sure exactly what needs to change though to enforce such new semantics of the column. Anyhow, until we have made that change, the documentation should reflect the old state of affairs.

Regarding this forum my understanding is that it is for the development *of* OpenACS. I think that includes package development and not only core development.