in reply to Allowing Plugins

To chime in on pc88mxer's comments, the point is that there should be a single authority for any given concept. I like to look at the concept of "Who cares?", as in "Which entity is the one that should be the Subject Matter Expert for this concept?". Every other entity should then defer questions to that SME. Sooo, if you have authorization as a concept, have one authz entity that does the right thing. Everyone else talks to this guy.

Also, you've got code (plugins) that are really configuration items (who can login, etc). Don't conflate behaviors (code) with input (data).


My criteria for good software:
  1. Does it work?
  2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?

Replies are listed 'Best First'.
Re^2: Allowing Plugins
by norkakn (Novice) on Feb 25, 2008 at 19:11 UTC
    > Also, you've got code (plugins) that are really configuration items (who can login, etc). Don't conflate behaviors (code) with input (data).

    I guess I was unclear. The reconciliation program figures out that a person should be able to login (because of the import flags). The plugin is given a person and told that this person either gets to login, or doesn't. The plugins are designed not to need any knowledge of which queries guarantee the permission, just that this record needs it.
      The plugin is given a person and told that this person either gets to login, or doesn't. The plugins are designed not to need any knowledge of which queries guarantee the permission, just that this record needs it.

      So, what exactly is the plugin doing again that a class doesn't?


      My criteria for good software:
      1. Does it work?
      2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?
        It is a class. I'm a bit confused (I'm pretty new to perl, hopefully plugin doesn't mean something more specific in perl) The plugins will inherit from a base plugin class and just override the methods. Is there an easier way to go through modules and see what classes have the same superclass? That'd do the trick.