Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Plugins vs Applications for Dummies

DirtyDogDirtyDog ✭✭
edited November 2012 in Vanilla 2.0 - 2.8

I'm the dummy. I've read some threads on this but the differences are described in technical terms. Could someone explain the differences in a way even a small child (me) could understand?

Actually I don't need it totally in the form "well if Jack has 3 apples, and Mary has 2 oranges....", some specifics would be cool. I just haven't found an explanation that has worked for me yet.



  • My child's-eye take on the differences.

    my take is an application is used for more complex projects and resides in application folder. e.g. Inbox Conversations are an application, so if the vanilla forum - they do two different things and have a looser tie-in.
    the custom pages is also an example of an application.

    plugin is controlled by plugin controller and is used for less complex projects.
    plugin seems more tightly coupled to the forum discussions and comments, themes and style sheets itself. My take is if a plugin can do the job - use a plugin.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • businessdadbusinessdad Stealth contributor MVP

    From a Developer perspective (me), a component is a (usually small) piece of software which provides one specific feature. An application sits at a higher level. It's made by components which work together to provide a set of functionalities.

    Taking my work as an example: Cron plugin gives the ability of running scheduled jobs. The Logger allows other components to keep track of things. LoginGuard prevents brute force attacks, and so on.

    Together, they form Vanilla Forums, which is an application. Sure, they are optional, but that's the idea. A well designed application is always modular, therefore almost any plugin could be considered optional.

  • x00x00 MVP
    edited November 2012

    From the Model Controller View perspective. Applications are the natural containers of controllers and hence model and views, that define an application.

    So in simple terms if the a section of the site the is primarily to do with one thing then the bulk of that is probably in an application. Such as Conversations, or Addons.

    However as I hinted at before, Garden allows thing to be quite incestuous, and the main way of melding the different functionality is through hooks, and of course many of the resources from different areas are also available to use such as models, and modules.

    Pugins tend to extend functionality in parallel, however that is not to say they can't go beyond that. There is quite a bit of crossover.

    However to start it is useful to think of plugins as adding things to Applications so if you have an application, it might add functionally to a particular controller, model or view method through hooks. it might add new Method to a controller (which is almost like adding a page). it can even directly override controller method (generally discouraged).

    In some case plugins work like mini applications, including mini dispatchers. This is becuase of the balance of the crossover. In an Application like Addon the bulk of it is specific to Addon, but it is also making use of the forum functionality. If you have something like Karma the bulk of it is across all areas, with a small number of pages for summarising, so plugin make sense.

    Now I did something odd with MarketPlace. This is something that could have been an Application but is actually a Plugin. This was a complicated design decision witch may well change, however it is worked out ok, and it felt fairly natural doing it that way. I guess the primary reason is it is relies on plugins that are in some cases are directly controlling access to you other Applications. I also did it becuase I felt people might find it easer to implement it this way. Itself is parallel, and it is extended in a parallel way.

    How is it I was able to make a pluign pose as an Application? Well I used specific routing techniques. This actually enable the end user to choose the location of their store, from behind the dash.

    grep is your friend.

  • Cool thanks guys. I need to digest this for a bit.

Sign In or Register to comment.