Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Deploy an app-client?  RSS feed

Dave Elwood
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • 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??
Eva Thant
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

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!

  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!