需要帮助决定Java框架,库 [英] Need help in deciding java framework, libraries

查看:111
本文介绍了需要帮助决定Java框架,库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我打算开发开源的java应用程序,以在谷歌应用程序引擎以及正常的rdbms系统上工作,所以请帮助我选择

MVC框架 -
Struts / Spring MVC?



ORM -
JDO / JPA?



我正在考虑将性能作为一个关键因素。

解决方案

将需要一个轻量级的框架,无论是持久性还是应用程序。谷歌正在改变他们的定价模式,所以你可能想考虑这将如何影响你的计划。关于此应用引擎组有一个有趣的讨论: https://groups.google.com/forum/#!topic/google-appengine/ob-kMuDAAqc/discussion



除此之外,我只能在应用引擎上选择坚持框架

JDO 是一种痛苦。他们(Google)在应用引擎中支持的版本是1.x,我相信这是古老的。我在工作中遇到了很多麻烦,比我还记得。 如果您之前有过使用JDO的经验,这仍然是一个不错的选择。如果我要重新开始,我会选择专门为应用引擎编写的持久性框架,如 objectify strong>或树枝。他们需要更少的开销,并且更易于使用(从我的角度来看)。一个巨大加上objectify:为您提供支持memcache的支持,无需额外工作。有多棒?

但是,您也想支持RDBMS。如果你有时间的话,你可以在你的选择对象化和RDBMS持久层之上推出你自己的抽象层。这会给你在性能上的优势,你正在寻找。 ;)



如果这不是一个选项,我会建议JPA(不是因为我自己使用过它,而是因为我在JDO中遇到了很多麻烦)。 >

希望这有助于!


I am planning to develop open source java application to work on google app engine as well as normal rdbms system, so please help me in choosing

MVC Framework - Struts / Spring MVC ?

ORM - JDO / JPA ?

I am considering performance as a key factor.

解决方案

For app engine you will want a lightweight framework, both for persistance and application stuff. Google is changing their pricing model so you might want to consider how this will impact your plans as well. There is an interesting discussion on the app engine group about this: https://groups.google.com/forum/#!topic/google-appengine/ob-kMuDAAqc/discussion

Aside from that I can only comment on the choice of persistance framework:

JDO on app engine is a pain. The version they (Google) support in app engine is 1.x, which is ancient, I believe. I have had more trouble with getting things to work than I care to remember. If you have previous experience with JDO this still might be a good choice. If I were to start over again I would choose a persistence framework that was specifically written for app engine, like objectify or twig. They require less overhead and are easier to use (from my point of view). One giant plus of objectify: gives you memcache support out of the box with no extra work. How great is that?

However, you also want to support an RDBMS. If you have the time, you could roll your own abstraction layer on top of objectify and the RDBMS persistance layer of your choice. That would give you the edge in performance that you are looking for. ;)

If that is not an option I would suggest JPA (not because I have used it myself, but because I had so much trouble with JDO).

Hope this helps!

这篇关于需要帮助决定Java框架,库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆