Boranbayev A.S.
Eurasian National
University named after L.N. Gumilyov, Astana, Kazakhstan
ESSENTIAL
PRINCIPLES FOR DEVELOPING INFORMATION SYSTEMS USING FRAMEWORKS
Today,
programmers are using many different open source frameworks which help them
with development of Information Systems using J2EE programming [1]. Some examples of these frameworks include
Spring, Hibernate, Struts, and many other [2].
Many of these open source frameworks do not make programmer's life any
better, because it is not always easy to change and improve these frameworks. For these reasons sometimes programmers might
need to build their own framework.
Developing a framework that leverages Struts could be a very difficult
task, but programmers still do it and many of them succeed [3]. In this article, I will discuss some
questions to ask yourself before writing your own framework.
There are a
many reasons not to use a community framework in development of Information
Systems. A general framework simply
cannot be the optimal solution for every use case. However, we need to think carefully before
writing our own framework for a production application. Did you ever think if you should build rather
than buy your next house? It isn't a
trivial choice.
It is tempting
to set large goals and develop a cutting edge framework that helps us to solve
all problems. If we have sufficient resources, that could be done. Starting smaller lowers the unforeseen risks,
takes up less development time, and lowers the learning curve.
Here are the questions we
should answer before writing our own custom framework:
1. Can I write a better specific solution than
the community solution? The majority of developers don't have the skills
required to do this, even though they are focusing on a specific problem set.
2. Am I sure that I fully understand the problem
domain? It is possible that the
community framework has flexibility we don't require for our use case. It is more likely that it simply has
flexibility that we don't realize we will require, because we have less
experience in designing applications than the sum of all of the community
developers, who have helped to create the community framework.
3. Do we understand exactly how the current
community frameworks work, why they work like that way, which design patterns
we can safely remove, or which patterns we can add? To create our own framework without playing
with current community frameworks is hard.
We may not need everything the community frameworks offer and some of
their generalized patterns may not be optimal for our problem task, but we
cannot even start to write a better framework for our use case unless you have
ripped apart the code base for the community frameworks, and really understand
exactly how they work and why we would want to do things differently.
4. Is it worth the time to develop our own
framework? It takes a lot of time to
write a solid framework. And then we
need to create documentation that is as good as that for the community
projects. Did you ever think if it would
be better using that development time to help community frameworks to become
better? Maybe we could extend the
community frameworks for our own use, or even submit code for possible
inclusion into the frameworks.
5. If we develop our own framework, is it worth
the learning curve for others to learn it?
Not only we, but everyone else who has to work with our new framework is
going to have to learn it whereas many of these people may already be familiar
with community frameworks. Every time we
hire a new contractor or developer we are going to have to teach them our new
framework. Is it worth the time?
Every web
application uses a framework for developing Information Systems [4]. The questions are whether developers wrote it
themselves or leveraged an existing framework, and whether it is a good one or
a poor one. There are a lot of reasons
to use a good community framework, but there is nothing wrong with writing our
own. Custom written frameworks get a lot
of grief because a lot of custom frameworks are not good. This does not mean there is no reason to
write your own framework. There are many
examples of successfully written custom frameworks. But developers must remember, writing your
own custom framework is way harder than they would expect.
I would like
to mention that it is also a good idea to write our own framework as a learning
exercise. In fact, for anyone who has
the time, I do not think anything could make you a better programmer than
creating a custom framework. As a
learning exercise it is a great way to gain experience and to understand what
you are doing while building Information Systems.
References:
1. Boranbayev
A.S. Development of E-business websites
using a multi-tiered architecture and J2EE.
Materials of 6-th Kazakh-Russian international scientific-practical
conference called “Mathematical modeling of scientific-technological and
ecological problems in oil/gas mining industries”. – Astana, 2007, p. 87 – 91.
2. Software
framework. From Wikipedia, the free
encyclopedia:
http://en.wikipedia.org/wiki/Software_framework
3. Struts, an
open-source MVC implementation. Manage
complexity in large Web sites with this servlets and JSP framework:
http://www.ibm.com/developerworks/library/j-struts/
4. Boranbayev
A.S. Principles for Developing
Architecture and Design of Web Applications and Interface in Information
System. //Vestnik of National Academy of Science of the Republic of Kazakhstan,
2007, ¹ 6, p.130 – 134.