When i see some java people and asking about a framework, they say struts, hibernate or spring etc. Noone is keen to create a custom framework of their own.
When i was working in my first project, i underwent a training for ten days to understand the framework they developed. It was such a huge project and they had a solid framework.
Which never failed till the end. It was a portal project but we used the whole project in a single portlet so no much of portlet stuff. But they customized everything that they almost created their own methods and classes to do almost all the things. Since we used JSF, we created a lot of custom components also(Till now i was saying as they, but now its WE. Since i was working in that part and i WAS a specialist in that area)
Enough of the older stories. First lets see what does a framework mean.
Dont need to go for dictionary since the meaning of Framework is evident to all. So for a project, the skeleton is framework. So once the skeleton is framed properly, we can go ahead with filling the skeleton with flesh. Oops, going like a horror movie. So here, if the application has many modules, each module will use almost same(some may need sub framework) the framework. Each module will have its own track in a good framework. So it will make the process of recovery after a damage easy.
For example all projects in java handles with database searching, insertion of new data and updating or deleting data. But they will have different business process or rules.
So here one thing is same, contacting the DB. So the major aim of the framework will be this. Then insertion and updation are same part so they will use a track in the framework(If needed some sub framework may be used for business rules). Searching and deleting(which normally not good to use. Instead we can move to a temp DB and delete contents in intervals) will take their own tracks.
If its a web project then, its good no no must to use a tiered architecture. Majorly 3 tier. Its M..U..S..T.. must to follow this rule. Otherwise its so hard to maintenance and also it will make the whole project rubbish. No intro for 3 tier architecture. Its like teaching a,b,c.. again.
May be these are some of the advatage of using a own framework in JAVA.
The major problems in java are Exception handling and memory management(Though there are strong garbage collection mechanisms, a single coding error will lead to a total mess, which will take days to figure out) and some object pass between classes.
Its good to extend every class from our own custom super class. For example in struts. Instead of extending all action classes from Action. Extend a CustomAction class from Action and the rest can be extended from CustomAction. So it gives a clear control over the Action class. so we can do whatever changes before it finally reaches to the original Action class. For example in the topmost action class, we can have exception catching and handling mechanism so that it will surely make process easy.
Hope i confused u. But i am sure that you should have got an idea about frameworks. Any doubts or scolds, pls do it in comments. lol..
This entry was posted
on Mar 26, 2008
at Wednesday, March 26, 2008
and is filed under
java
. You can follow any responses to this entry through the
comments feed
.
Flickr Photostream
குருதியில் பூக்கள் நனையும் போது உறவுகள் உறங்கலாமோ?
temp
Contributors
- Kishore
- Everybody struggles and overcomes them. Some i come across and the way i did it.