Win a copy of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques this week in the Server-Side JavaScript and NodeJS forum!

James Liu

Greenhorn
+ Follow
since Aug 02, 2002
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by James Liu

Hello everyone,
I am new in hibernate, when I check the samples or examples, I can only see the simple table relations, I have a simple questions, is it ok to setup the complicate tables relationship using hibernate?
For example, in our DB, we have about 500 tables, some times one select sql involve about 10-20 tables, when I try it using hibernate, I find it is really time comsuming doing the mapping, and it is much difficult to just write a sql, do I miss something or it is not for complicate mapping?

Thanks

James Liu
Yes. I was surprised when I saw that too, nut I do not think I have the chance to use that Logo anyway?
Yes. I was surprised when
Thanks for the post, but the problem is :
in petstore example, when signonEJB sessionbean calls the UserEJB entitybean local interface, it just simply lookup, it did not use erviceLocator.
but when shoppingClientFacadeLocalEJB session lookup the Customer entitybean local interface, it uses serviceLocator. I mean why both cases is sessionbean lookup entityBean local interface, but one it uses servicesLocator, but the other not?
Today when I looked at petstore source code, I found this:
1. When signonEJB sessionbean calls the UserEJB entitybean local interface, it just simply lookup, it did not use serviceLocator.
2 .Then I found when shoppingClientFacadeLocalEJB session lookup the Customer entitybean, it uses serviceLocator.
3. Then I check the CORE PATTERN books, from the UML, it looks like if you try to lookup the sessionfacade from outside EJB container , using serviceLocator, if a sessionbean calls a entitybean, it does not use serviceLocator.
So anybody can explain this, I am really confuse by this. I am so suprised about this, before I thought we should always use serviceLocator whenever you try to lookup a EJB, I have been using this for a while in our project.
Today when I looked at petstore source code, I found this:
1. When signonEJB sessionbean calls the UserEJB entitybean local interface, it just simply lookup, it did not use serviceLocator.
2 .Then I found when shoppingClientFacadeLocalEJB session lookup the Customer entitybean, it uses serviceLocator.
3. Then I check the CORE PATTERN books, from the UML, it looks like if you try to lookup the sessionfacade from outside EJB container , using serviceLocator, if a sessionbean calls a entitybean, it does not use serviceLocator.
So anybody can explain this, I am really confuse by this. I am so suprised about this, before I thought we should always use serviceLocator whenever you try to lookup a EJB, I have been using this for a while in our project.
Hello everyone,
Is there anyone has the experience how to do it, could you please post the example code if you can.
Thanks
James Liu
Hi seid,
I think it is ok use DAO with stateful session bean, actually I use it in our projects for a while, it is working fine.
In my opinion, DAO is just data access object, all the other objects want to access the database, it calls DAO to do it. So no matter it is stateless/stateful/BMP Entity bean, or even servlet, it always call DAO to do it. It makes code very clean ( all the sql in one layer), if in the future I want to switch database, it is much easier to do it. Also it is good for reuse.
Just like chris said, 'DTO' is just a value object, it is good for performance when passing cross network and methods.
Hi Alex,
Will you go to studay MBA? You suprised me again with your new idea. I do not think MBA will help your career as a IT professional, it will be the same as SCEA certificate. After two years MBA study, you still can not say you have two years managerment experience, you still face the same problem you have right now. No certificate can guarantee you in real world.
I hope it helps.
Hi Alex,
You are 23 and you have 7 years experience in IT field, are you kidding me? Based on what you just said, you have a full time job when you went through the whole four years ( or more) in the university, what kind of school is it?
If everything you said it is true, then you are really a genius, off course this certificate is useless for you, and most of us here are just normal guys, this is why we can not understand you, this is why we still think this certificate is useful for our careers.
I think I benefit a lot from preparing this test. Off course the real project experience is not the same as passing the test, but when I was preparing for this test, I did study a lot of new things and got tons of new ideas, I am sure I will use some of them in our real projects.
This certificate is not just a paper for me, it gives me a lot even it costs me a lot, both time and money.