• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

EJB's are easy to build....are they?

 
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Kathy,
I just wonder how far the above said statement is true? Dont you think we need to learn and memorize all of the following technologies:
J2SE 1.3
JNDI 1.2
JTA 1.01
JDBC 2.0
JMS 1.02
JAVAMAIL 1.1
And how many people have written Enterprise Beans that scaled to multiple containers??
 
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
EJB are easy to write because you concentrate on writing business logic but assembling, deploying and writing vendor specific DD is a painful process, I feel.
 
Ranch Hand
Posts: 195
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You don't really need to be an expert in all of those. Of course J2SE you need to know, but as far as Java Mail, JTA, and some of the others listed you can learn as you need to. For things like JNDI, just understanding the basic principles of doing is lookup is enough, and there are plenty of code samples in books and on the internet to help with that.
Brian
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
not expert but atleast should be thorough enough about the said technologies. right?
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

not expert but atleast should be thorough enough about the said technologies. right?


You cannot except someone who does not java to write EJBs.
 
author
Posts: 9050
21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Viswanadh,
Well I guess it's all relative EJB is a REALLY HARD way to write hello world. On the other hand, if I was going to create the website for Victoria's Secret (if Kathy would let me ), I think EJB would make it MUCH easier than most other technologies. Depending on your application I would guess that most of the APIs you mentioned would be used to some degree.
 
Cowgirl and Author
Posts: 1589
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by viswanadh kasinadhuni:
Kathy,
I just wonder how far the above said statement is true? Dont you think we need to learn and memorize all of the following technologies:
J2SE 1.3
JNDI 1.2
JTA 1.01
JDBC 2.0
JMS 1.02
JAVAMAIL 1.1
And how many people have written Enterprise Beans that scaled to multiple containers??


OK, this is another really good question.
The only thing you MUST know, in order to do EJB, is a solid knowledge of the Java language. If you have passed SCJP, you have enough Java knowledge. Actually, *more* than enough, because you do not do threading in EJB, for example. You do not need to know many/most of the APIs in J2SE, other than those you'll be using. You'll do know file IO or AWT/Swing for example. No custom classloading.
As for the others, you do not need to know them unless you are going to be using them. You do not need to know JTA, but you DO need to know the javax.transaction,UserTransaction, which you'll learn as part of learning bean-managed transactions. (But even that, you will most likely NOT use BMT, in which case you wouldn't even use THAT).
You do NOT need to know most of JNDI, other than getting an initial context and navigating / doing lookups. Again, very simple, and only a very small part of JNDI. Your container is required to do the JNDI registration on your behalf, so the only JNDI you really need is what is in the spec, UNLESS you are also doing additional work with your company's naming & directory services. But just because you're doing EJB, does not mean you're responsible for managing/administering a company's naming services.
You do NOT need to know JDBC unless you're doing BMT, which very few people are with EJB 2.0 (if you are working with legacy EJB systems, then yes, you probably WILL need JDBC.) A large part of the POINT of EJB 2.0 was to prevent developers from having to be DBA's or know JDBC, since CMT will nearly always be faster and more efficient than using BMT.
JavaMail you would need only if you happen to be writing an application that uses it. Most won't. I would put that in the category of "just in time learning" -- wait until you need it, which you may never need.
JMS, I agree that you should have *some* familiarity, but other than understanding the purpose and how message-driven beans work, you can probably hold off learning much about JMS until you know for certain that you will need to use it, either because it's already a part of the enterprise system, or because you've identified it as a part of your design (so, if you're a designer or architect, you WILL need to know enough about JMS to know whether you should use it... but you certainly don't need to know much about the APIs.)
So, writing EJB's really *is* pretty easy. BUT... that doesn't mean assembling and deploying an application is easy. Not to mention administering it! In other words, if your job is simply to write business components, then, as others here mentioned, it is fairly straightforward and MUCH easier than if you had to write code for transactions and security and concurrency, etc.
But if your job is to build a complete application, whether from existing components or those you create (or more likely, a combination), you have a lot of choices to make. Still, the best way to make reusable applications in EJB is to use declarative transactions and security, and allow as much customization as possible to happen during DEPLOYMENT rather than during code development.
If you are writing for a clustered environment, the difficulty is *not* in how you write your components. If you have written components to the specification, they should be usable regardless of whether the server is clustered or not. In reality, of course, there are issues... but they are much more vendor-specific / Container-specific issues rather than strictly EJB issues. So I would say...
"Building EJB components is easy"
"Assembling and deploying an application can be a little harder" (sometimes a LOT harder, depending on the complexity of the app)
"Administering a large-scale clustered J2EE server is hard."
and finally...
"Architecting and designing a large-scale J2EE application can be challenging!"
If I were looking for a job, I'd be hoping for business component developer and I would run SCREAMING away from a job that required me to manage the server environment. But often, you don't get a choice. Especially these days.
So, the business component development (in other words, creating the EJB) is by far the easiest part, and requires only a basic level of Java knowledge. Crafting an application requires more sophisticated knowledge, since the application level can affect performance in profound ways... (like, choosing to make separate transactional calls to an entity bean rather than scoping three calls to the same bean in the same transaction, for example) or, using a multi-row finder when a home business method would be far more efficient... and of course transaction scope and security is in the application level as well.
And architecting and/or designing both the application and its deployment can be a Big Decision, not left to junior programmers, even though a fairly inexperienced programmer can write good beans, if they understand how EJB works, so that they know WHAT to put, for example, in each of the lifecycle methods.
cheers,
Kathy
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for an excellent reply kathy. Now the question is "Sun certified Business Componenet Developer"
means nothing but a person who possess the knowledge of just "writing EJB Components"...?
But as you said the reply "Business Component Development is by far the easiest part, and requires
only a basic level of java knowledge", means any SCJP (is by default) a SCBCD, then why take the
SCBCD? just to add a certification?
I am thinking that being an SCBCD you should do all the tasks you mentioned in the reply. Like
(a) Build EJB Components
(b) Assemble and Deploy it
(c) Administer it on a large-scale clustered J2EE Server
and you should be competent enough to
"Architect and design a large-scale J2EE application"
any takes??
 
Kathy Sierra
Cowgirl and Author
Posts: 1589
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy --
Even though the exam *is* named "Business Component Developer", it does cover these EJB roles:
* Bean Provider (the one who really does create the components... the programmer)
* Application Assembler (the one who assembles various components into an application (possibly creating new components and clients as well) and sets up transactions and security roles for the application
* Deployer (the one who takes the application and deploys it into some actual server in a real company, and does the final security mapping between the security roles defined in the application and *real* people (users and groups) in the company who will map to those roles defined by the assembler.
In reality, most of us will do all three of these things.
But server administration and architecture are not part of this -- that is going too far beyond the scope, and in most large enterprises, the bean provider is *not* the one responsible for server administration.
However, design *is* important, and even though it is not specifically covered in the exam, the assumption is that if you DO understand OO design, AND you have a very strong foundation of how EJB works, you have a better chance of making good design decisions, and often the EJB developer will also be responsible for design. Certainly, and application assembler is often the designer of the application, even if some of the beans were written by others.
Sun considers the role of architect to exist at a very different level, and that in fact architects may not always be Java coders. (Although in some parts of Sun, the architect is the person who is the BEST at creating the components and applications, and can build the most representative prototypes...)
People traditionally complain that there has been too much *code-level* knowledge in the SCEA, the only certification that does NOT require SCJP.
cheers,
Kathy
 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Kathy,
Excellent point. Add my 2 cents: In real world, the most problems are not the technology itself, rather how we are going to implement the business logic into something like EJB. So I definitely agree that you DON'T have to be an expert on every field to write ejb.
Back to your book, there is a chapter about pattern and performance in EJB. Is this something like "best practice" or "design pattern" of ejb, and how much it is weighed in the exam?
Thanks,
Kevin Cao
 
Kathy Sierra
Cowgirl and Author
Posts: 1589
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy Kevin,
Actually, the patterns and performance chapter did *not* make it into the book because the book got too large (it is already 100 pages longer than expected), and because it is the ONLY part of the book that was not part of the exam. So, I was sad to see it go, but we are putting that info on the website instead as kind of a (free, of course) supplement. Mainly just tips, tricks, some best practices, and a summary of how to apply some of the most-common and helpful design patterns.
But NONE of the patterns and performance stuff is on the exam. The *real* final table of contents is the one on our ftp site. The patterns/performance stuff is more like, "OK, given that you now know THIS about how the Container works, doesn't it makes sense that you would choose XYZ when you need to do ABC?" Showing you how the way it works can be applied when you make design and implementation choices. Still, I'm sorry it didn't make it into the book. But they book is already heavy enough to be used as a dangerous weapon
An added bonus! It doubles as a self-defense tool!
cheers,
Kathy
 
Ranch Hand
Posts: 321
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,
I think if one has passed SCJP with a thorough know how and not just cramming can very well write and understand EJB's and offcourse a little knowlwdge of patterns would certainly help in getting things easier.
Rishi
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
kathy,
is there any chance that you give sample chapters of your "Head First Java" for download?
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Kathy,
why there is still "preorder this item" on the amazon?
 
Ranch Hand
Posts: 3178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by viswanadh kasinadhuni:
kathy,
is there any chance that you give sample chapters of your "Head First Java" for download?


Here is the link to O'Reilly site, from which you can download the sample chapters...
http://www.oreilly.com/catalog/hfjava/chapter/index.html
 
Ranch Hand
Posts: 883
3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by viswanadh kasinadhuni:
kathy,
is there any chance that you give sample chapters of your "Head First Java" for download?


Did you mean "Head First EJB"? If so, then the O'Reilly won't be any help for sample chapters, though I do like the "How to Talk About Jini, J2EE, and Web Services at a Cocktail Party" piece, also by Kathy and Bert.
I believe there's a link to the FTP section of wickedlysmart.com floating around here - and you can download a couple of sample chapters there.
 
Ko Ko Naing
Ranch Hand
Posts: 3178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Burk Hufnagel:

Did you mean "Head First EJB"? If so, then the O'Reilly won't be any help for sample chapters, though I do like the "How to Talk About Jini, J2EE, and Web Services at a Cocktail Party" piece, also by Kathy and Bert.
I believe there's a link to the FTP section of wickedlysmart.com floating around here - and you can download a couple of sample chapters there.


I think viswanadh has missed the following thread
https://coderanch.com/t/158071/java-EJB-SCBCD/certification/First-Chapter-Sample-Head-First
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
no,
I am asking for another book by kathy...."Head First Java"
 
Ko Ko Naing
Ranch Hand
Posts: 3178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by viswanadh kasinadhuni:
no,
I am asking for another book by kathy...."Head First Java"


So u got the link I have mentioned about, didn't you? There are two chapters available to download...
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
you link has been removed by angelfire naing?
 
Ko Ko Naing
Ranch Hand
Posts: 3178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by viswanadh kasinadhuni:
you link has been removed by angelfire naing?


Yeah, they didn't allow me to let others download just the files... It looks like I use their site for the storage, not for site promotion...
But I have put my files into my Yahoo Account... Have you tried it?
 
viswanadh kasinadhuni
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks naing
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic