Mvnforum设计者概述MvnForum论坛的架构和设计

 mvnforum是一个非常不错的开源论坛,由于工作关系,我研究了这个论坛的构架,虽然不是十分完美,但也异常的强大和易于扩展,在这里转贴一下那位越南开发者对构架的简单描述:

        I will try to describe the framework, the sequence of an app in this framework, the initial design of it and some reasons for these design:
       At the beginning, I decide to learn the j2ee technology because I think it is a promissing technology. What I learned at that time was the Blueprint Java Petstore, and I love its MVC model very much. I also need a forum for my site, but there is not any good opensource forum, so I and my friends at MyVietnam.net decide to build one. Next is the decision to use Jsp/Servlet instead of EJB, and we build a version based on the Petstore ideas, but specially designed for Jsp/Servlet, now it is the core library and is released as the MyVietnam framework, and the forum are open source for everyone (naturally mvnForum are using MyVietnam framework )
        We dont just want mvnForum to only be an independant java webapp, but a plugin that can integrate seamlessly to any existing apps, so you can say that mvnForum is a web plugin (look at the package net.myvietnam.mvnplugin.mvnforum)
       All the plugins will use the same core lib, that is MyVietnam Core Library, or MyVietnam Webapp Framework (note that it is not a full feature framework)
       All plugins will base on the MVC model, and can include as many modules as you want (mvnForum has 2 modules: user and admin). Each module has a Controler servlet (eg: ForumUserServlet), this servlet call a processor (eg: UserModuleProcessor) to handle the control of the module. the actual mapping is in a MapHandler (eg: ForumURLMapHandler).    Next, the processor call the WebHandler (eg: PostWebHandler), and the WebHandler call WebHelper (eg: PostWebHelper) for access database functionalities.
       If there is an error, then the Processor will catch and forward to an error page. Otherwise, the Processor will forward to a correct View based on the info in the MapHandler.
       All the view (*.jsp) should not process any thing, instead it only display the data that the WebHandler has prepared. It means that if there is an error in jsp page, then it can be considered as a serious error (look at the error page in each of the jsp files)
That is a summary, if you need to further explaination, just ask here

 
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值