• 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

Deploy an app-client?

 
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to get my head around using Netbeans with Glassfish and building EJB applications.

One of the oddest things in Glassfish here is an example they have : Cart. It is an application client and an EJB project bundled up in Cart.ear and deployed on Glassfish.

But this is strange. When you build an Enterprise App with Netbeans they offer you the chance to have a myproj-ejb automatically setup and a myproj-web-app automatically setup.

No myproj-app-client.

1. How did they do it with this Cart example that comes with glassfish??

2. And why do you bundle up an EJB project, a component resident in the server together with an app-client, something exceedingly distant from the server?

Seems strange to me. How can you deploy an app-client? The app-client is supposed to be outside of the server. That's why they call it a client.

Or am I completely off base??
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I’m a newbie. I haven't written any JEE project code of my own yet. I'm still playing with examples written by others. So my reply may not help you. If that’s the case I’m sorry.

Question 1

JEE 6 + GlassFish 3.1.2 (+ Netbeans 7.2)




When Netbeans 7.2 created the Enterprise Application -> SessionBeanIntro it didn’t create the SessionBeanIntro-app-client and SessionBeanIntroClientLib (Java Class Library). I’ve created those manually. Here are the steps to create app-client,


a. Click New Project

b. Select Java EE

c. From the Projects box select Enterprise Application Client and press Next.





d. Write your Project name and press Next.





e. Now here at Server and Settings at the very top Add to Enterprise Application is located. Select your Enterprise Application. In my case it was SessionBeanIntro. Then press Finish.





Question 2

In my example SessionBeanIntroClientLib is a Java Class Library. For remote clients, the client project
needs to use the Java Class Library project containing the remote interface.





Why is the SessionBeanIntro-ejb is there? I have no clue. It was in the example so add it to app-client Library. If I remove it, it works fine!


 
I don't even know how to spell CIA. But this tiny ad does:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic