由买买提看人间百态

topics

全部话题 - 话题: hibernate
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)
f*****e
发帖数: 57
1
I am in the transition of c++ to java, and my boss has been encouraging me
to buy books. I have some basic java books like "Thinking in Java", and the
head First series. Now I am ready to look deeper into the java world.
Please recommend some books on the following subjects:
- Ajax
- Web2.0
- Spring
- Hibernate
- Web Services with jee technology
- BPEL
Thanks in advance.
g*****g
发帖数: 34805
2
For spring and hibernate, the "in action" series is pretty good.
Also the "pro" series.
For web service, Axis and XFire are hot, check their websites to
see if you can get any books.
For ajax, there are different approaches, client package (e.g. YUI),
server side framework (DWR), and some full fledged one (GWT). It all
depends on what kind of application you are working on.
Can't comment on BPEL.
JEE is too big a topic, it's probably get dirty first and read what you need,
rather than read a ton
A**o
发帖数: 1550
3
去国内的论坛看看吧。那些人对这种问题更有经验。
我记得有个hibernate中文网什么的。

driver
t*******e
发帖数: 684
4

你说的JSF的问题没有一个在点上.
JSF到现在已经5年了,占了很大的market share. 所有IDE都支持JSF的开发, debugging
根本不是问题.
除了真正POJO的技术, 重大项目是很难作到完全backward compatible的,Hibernate,
Struts,Tapestry,等等没有例外,特别是触及了low level API的code.
有量化的benchmark说明JSF performance有问题吗? 如果application有performance问
题,十之八九是在Data Access Layer上. Web Layer对performance的影响极小.
c*****t
发帖数: 1879
5
来自主题: Java版 - Hibernate question
Does hibernate provide database server solutions that improves
the retrieval of data objects?
For example, instead of making multiple SQL queries to retrieve
the data and its children, do one query and through the use of
server solution to package the result and decript the data on
the client, to improve the performance.
I am trying to do some research to see if there anything interesting
could be done in this area.
t*******e
发帖数: 684
6
来自主题: Java版 - Hibernate question
What OP described is also known as n+1 select problem. The solution is to
run eager fetching. From "extra lazy" to eager, there are 7 levels a
developer can choose from. An appropriate fetching level will lead you to
optimized query performance. Besides, another great feature of Hibernate is
auto dirty checking that prevents unnecessary update operations.
c*****t
发帖数: 1879
7
来自主题: Java版 - Hibernate question
I don't care about the laziness. What I care is when the parent/children
needs to be retrieved, whether or not Hibernate can quickly retrieve all
of them at once.
For example, query Person and past work places (many-many), I'd like to
retrieve all of them at once using a single select query, rather than
using separated SQL statements.
I think that it is possible by adding a simple databaser server extension
(and hence the question in the original post), so it is likely someone
has thought about
s******e
发帖数: 493
8
来自主题: Java版 - Hibernate question
Hibernate does provide 'bulk' retrieval with join. in such case, it will
allow you to retrieve, for example, 10 people and their past work places
with one single db hit. But you should bear in mind, that no ORM is designed
for bulk operation, so you should to try to not use this feature. If it is
absolutely needed, you should always limit the number of records you want to
retrieve for one db visit, for example, you want to return only 9 other
persons if you want to get information about smectite
s*****e
发帖数: 854
9
来自主题: Java版 - Hibernate question
You can define a database view for the outer join and then use Hibernate to
interface with the view.
g*****g
发帖数: 34805
10
来自主题: Java版 - hibernate和ejb3
I think you mean JPA, hibernate is one implementation.
And EJB3 only supports JPA.
A**o
发帖数: 1550
11
来自主题: Java版 - hibernate和ejb3
哦,我是说JPA,就是Entity Bean啦。
从工程的角度讲,用JPA好,还是直接用hibernate好呢?
F****n
发帖数: 3271
12
来自主题: Java版 - hibernate和ejb3
Actually as goodbug pointed out early, Hibernate is not competing with EJB3,
as JPA is only a standard. EJB is basically useless and unnecessary unless
you really want to manage distributed transactions (which is such a big
assumption).
F****n
发帖数: 3271
13
来自主题: Java版 - hibernate和ejb3
You do know what is hibernate, don't you?
z****e
发帖数: 54598
14
来自主题: Java版 - hibernate和ejb3
那你不还是在用别人的类吗?
那不如用hibernate
如果你自己写的话,那就重复造轮子了,没兴趣
z****e
发帖数: 54598
15
来自主题: Java版 - hibernate和ejb3
那这不是hibernate的问题,是你自己的问题
T*********g
发帖数: 496
16
来自主题: Java版 - hibernate和ejb3
Ibaits,
它把jdbc的结果自动给你反射成对象。 如果之前的数据库设计的不好的话,比
hibernate有效。
b******g
发帖数: 3883
17
学好hibernate还是有一定难度的
p****d
发帖数: 2183
18
来自主题: Java版 - hibernate问题。。
最近在用hibernate,不太熟悉整个体系,有个问题:
所有的table都有javabean的持久化对象,在做单表查询的时候,api大概是这样
beanInstance[] getDataByQuery(Query, beanInstance)
这样单表查询的时候,给定SQL和需要做操作的表格的对象,可以返回一个包含查询结
果的bean对象数组。 所有个javabean都继承自一个baseBean
如果以这种方式实现多表查询,每个不同的query可能返回不同的fields,这样可能就
需要重新写一个不同的bean的对象,这样岂不很不爽?
表达好困难呀。。。不知道看不看得懂。。。
感觉这时候直接jdbc操作,resultset处理数据还更直接一点呀?
m******t
发帖数: 2416
19
来自主题: Java版 - hibernate问题。。

What's that beanInstance parameter for?
A multi-table query would return a list of object arrays,
where each array corresponds to one row in the result set.
You can execute native sql in hibernate if you want to
deal with the result set directly.
a****n
发帖数: 1528
20
现在由于项目关系,必须要用struts 1做,想知道应不应该好好学,还是凑合凑合就行。
如果学struts对学spring, hibernate有意义的话,我就打算好好学了。
t*******e
发帖数: 684
21
风马牛
struts I - MVC model 2
spring - AOP, DI
Hibernate - ORM
学学也好,不难学。
g***l
发帖数: 352
22
来自主题: Java版 - Hibernate question
Can hibernate be used with all the databases, such as Oracle, MySQL, DB2,
SQL server, PostgreSQL?
g***l
发帖数: 352
23
来自主题: Java版 - Hibernate question
What is the advantage and disadvantage of the following two choices on
database programming?
1. JDBC + SQL
2. Hibernate/spring
t*******e
发帖数: 684
24
来自主题: Java版 - Hibernate question
There is an unarguably steep learning curve on Hibernate. It took me almost
3-4 years to be really proficient in it. However, every minute you spend on
will be paid back.
l********0
发帖数: 283
25
Hibernate主键生成方式 Key Generator
我想满足这样的要求:
如果我自己指定key的话,那么会被数据库接受我自己指定的key;
如果我不指定key的话,那么数据库自动指定key(数据库已经设置了auto_increment)
但是如果我设置assigned方式,那么必须由程序指定;
如果设置identity方式,那么指定的话会出错。
我的意思就是:它可以自动适应我是否指定key,如果我指定,它就不用指定;如果我
不指定,它就自动指定。
请问Key Generator的选项里面有没有满足我的要求的?或者有没有其它方法可是实现
我的要求?
谢谢。
g*****g
发帖数: 34805
26
when you config "increment" in xml, the hibernate code must
be reading it and use it to config certain class.
Check that piece of code to see what class it calls.
q*********u
发帖数: 280
27
公司的数据库里面有一堆表格是没有primary key, 反正那些东西也没有到处foreign
key,都是独立的,对于这些表格,应该不能用hibernate去映射吧?连个@Id都没地方写,
最坏的方案就是用spring的jdbctemplate了,请各位提提意见,先谢过了。
F****n
发帖数: 3271
28
瞎说, 没有PK大多数RDB功能就不work, 会有"希望一个都没有"的DBA?
这个跟hibernate 基本无关
x*****p
发帖数: 1707
29
Even tables do not have pk and fk, you can specify pk and fk in hibernate
mappings.
a*****p
发帖数: 1285
30
最近开始看java ee的东西,知道大多数公司希望招有spring, hibernate或者struts
经验的人。
请问有什么教材复习这些么??我下载了java ee的tutorial,里面没有讲这3个
framework的。有没有什么比较好得电子书来学习这些framework。此外,实际中哪个用
的更多呢??从哪个开始学比较容易呢?
S****h
发帖数: 558
31
Second that. For Spring in Action, make sure you get the latest version
with Spring 3.0. Spring's web tier makes a big turn from XML config to
annotation config in 3.0, which is quite significant.
One thing about Spring's own online manual/document. It is good for
reference, not good for reading from scratch. So make sure start from a
book. Spring is huge. For your purpose, just make sure you understand the
core such as IoC. You can skip on Aspect part. Then go directly to
SpringMVC.
O... 阅读全帖
s****e
发帖数: 282
32
It seems to me that most of the Internet forums recommend using Hibernate
other than Spring. Why learn J2EE from Spring?
S****h
发帖数: 558
33
Hibernate is for ORM, basically, how to deal with persistence/database.
Anything (web or not) can use it.
Spring in general is a framework about IoC and AOP. It can also be used for
any general project. It grew a lot and applied their basic framework to
lots of fields. For example SpringMVC is the one for Web application, (
compared to JavaEE). Spring also has other packages cover lots of other
fields, such as security, message, database, ...
m*****u
发帖数: 1342
34
I was referring to the First application at Hibernate (Jboss) offical
documentation. I found some problems when doing the exercise: just want to
share some of my findings so others may benefit.
http://www.stlplace.com/2010/03/28/some-corrections-to-hibernat
b******e
发帖数: 1861
35
来自主题: Java版 - hibernate高手求助
现在碰到一个问题,
我有两个entity classes通过many to many association联系在一起。在schema上是三
个表,两个主table,一个association table。
It looks like this.
Student table
student id, other columns
student_class table
student id, class id, class name
class table
class id, other columns
class Student
{
long studentId;
other fields.
Map classMap;
}
class Class
{
long classId;
other fields.
}


阅读全帖
r*****s
发帖数: 985
36
tho I don't like the idea to replicate db in this way,
this is how you can achieve what you want:
Write an interceptor that extends EmptyInterceptor,
overrides all the cases
onLoad/onSave/onDelete/...
and save the table/class names.
Register it as hibernate.ejb.interceptor.
r*****s
发帖数: 985
37
我也看不懂您要做什么
您是要自己manually instrument lazy init code?
hibernate本来不就是runtime instrumentation
thru CGLIB/Dynamic proxies吗?
c******n
发帖数: 4965
38
certain cases need build time instrumentation, please check out this one
http://docs.jboss.org/hibernate/core/3.5/reference/en/html/perf
I kind of "fixed" it, since I found that the issues are only around
anonymous inner classes (stupid javassist and cglib have problems with these
), so I disabled instrumentation on these
r*****s
发帖数: 985
39
您说的是lazy loading properties
不是我们一般意义上的lazy loading好吧?
正如hibernate manual说的,
only applicable in “extreme cases”,
基本上我觉得需要这样做的应该考虑分出去一个table.

these
P*****f
发帖数: 2272
40
来自主题: Java版 - 现在hibernate这种流行框架
【 以下文字转载自 Programming 讨论区 】
发信人: Pontiff (树), 信区: Programming
标 题: 现在hibernate这种流行框架
发信站: BBS 未名空间站 (Fri Dec 16 01:15:56 2011, 美东)
是不是都用 annotaion, schemaless的POJO了,
总觉得在表达enity之间关系的时候比schema来得复杂,有没有好的review 文章?
P*****f
发帖数: 2272
41
any good resource?
just basica configuration to demo the architecture -- Spring MVC + Hibernate
Persistent + some JSP/Servlet within a Eclipse project.
Thanks
g*****g
发帖数: 34805
42
There should be some HelloWorld maven project that has this already,
google it.

Hibernate
S****h
发帖数: 558
43
Hibernate does not need to be with Spring MVC. You can read the relevant
section in a book like this http://www.apress.com/9781590599792.
r*****s
发帖数: 985
44
是不是互不兼容的啊?
好像以前的@Cache by hibernate不支持method level caching
@Cachable by ehcache-spring-annotations supports it,
so i have to re-annotate every cached entities with @Cachable?
configuration is different too.
very confusing ya
r*****s
发帖数: 985
45
高了半天,
这个method level的@Cachable不是JPA的,
是com.googlecode.ehcache.annotations.Cacheable,
JPA的Cachable基本上跟Hibernate的Cache是差不多的。
s*******n
发帖数: 24
46
来自主题: Java版 - 如何学spring和hibernate
学生,学java两年,还是菜鸟
想请教怎么学spring和hibernate
有什么书推荐
谢谢
t*******e
发帖数: 684
47
来自主题: Java版 - 如何学spring和hibernate
Spring in Action都出了第三版了. 不过第三版把前两版的很多内容都忽略了,不看前两版就上
第三版会漏掉很多东西.
Hibernate in Action至少出了两版了,不过第二版也落后了,有很多新的东西没有.
p*********t
发帖数: 2690
48
来自主题: Java版 - 如何学spring和hibernate
貌似老印里面,有什么spring,hibernate都不懂的,就嘴会吹的,编个烂程序只要编译
就能成功的,也能是个混得很好的jave developer,有时能当上manager.
g*****g
发帖数: 34805
49
来自主题: Java版 - hibernate 的两个问题
Hibernate is an ORM. So the biggest benefit is the ORM, which
makes a clear layered structure, some level of DB independency.
e.g. If your project needs to support MySQL and Oracle at the
same time, it's much tougher to use plain SQL. Also, secondary
caching can be had with zero coding.
B*****g
发帖数: 34098
50
来自主题: Java版 - hibernate 的两个问题
简单sql支持不同数据库根本不是问题,复杂的要不同,不过hibernate也不支持
现在只发现caching确实是个好东西
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)