In a previous post I did on "what is Business Logic", I used the analogy of the application's controller making a request for information from the model, and how the process that the model executes in order to produce the requested information IS the business logic itself. Since I had taken the time to expound on the term "Business Logic", a reader asked me if I would expound on what, in contrast, exactly Application Logic is, so what follows is an analogy of the term as I understand it....
Let's start a company, shall we? Sapient Grey will be primarily a think tank, but with an in-house development group with the capabilities to make the visions of the core committee a reality. Our corporate motto, "Sapient Grey is People..." will be burnished in giant brazen letters alongside a customized version of Rodin's famous sculpture "The Thinker", all of which will adorn the east-facing side of our brand new ten story red granite office building.... Oh, wait. We don't have an office building yet. Okay then, so we'll hire an architect to design our office building, being sure to include a private elevator and an elaborate zen-style atrium or courtyard in the center. In the meantime, while the building is being designed and constructed, you and I and our other elite colleagues will fly ourselves to Tahiti to brainstorm Sapient Grey's visions, goals, agenda, and lay out a detailed business plan.
Our architect is creating detailed blueprints for the office building, figuring out how the plumbing will need to be laid out, how the electrical systems will be segregated and tied together, how the interoffice communication system will be organized, and how we will implement security at all levels. The systems and designs that our building architect is handling is a precise analogy to what "Application Logic" is within a web application. How security is implemented, how we will manage and access state and persistence, how we will handle storage and retrieval of data....this is application logic. Like our office building, which when complete could house and accommodate anything from an elite night club to an investment firm, the application logic is independent of the actual business logic that executes within it.
Back in Tahiti, we and our elite colleagues have nailed down our mission, vision, and corporate culture statements, and have managed (despite the infinite flow of top shelf pina coladas) to draft a three hundred page document which architects Sapient Grey's primary divisions, corporate policies, managerial policies, communication policies, and human resources policies. We know, generally at this point, what our company will be doing and all the internal workings that will allow it to function efficiently. In our analogy with a web based application, we have just architected our application's Business Logic.
So, although at first glance the terms Application Logic and Business Logic can seem to be very ambiguous and even overlapping (they were for me, anyway), in reality they are not. Using the analogy of Sapient Grey and its office building, it is a rather simplistic exercise to properly categorize any aspect of a web based application's logic as one or the other. Just ask yourself, "is it part of the building our company resides in, or is it part of our company and would go with us DESPITE the building we happen to office in?"
Just my take on things. Input and/or clarification soliticted from any other enlightened beings.
Doug out.
You are not logged in, so your subscription status for this entry is unknown. You can login or register here.
Thanks again,
Charlotte
