Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ear

 
Marko Debac
Ranch Hand
Posts: 121
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

how can we build ear if we have normaly web application created with netbeans?

Thanks.
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Web applications are normally packaged as war files. ear files are used for full-blown JEE applications (e.g. those containing EJBs). Why do you want an ear file for a web app?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65118
89
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please be sure to take the time to compose descriptive subjects for your posts; read this for more information.

You can go back and change your post to add a more meaningful subject by clicking the .
 
Luis Lopez Coronado
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For create the ear in netbeans, you need to create a Enterprise Aplication besides your web aplication, and add your web aplication (check the create web aplication module and put the name of your web aplication), when you build the enterprise aplication your war file packaged in ear file.
But as Ulf said, you dont need de ear file if your aplication is only a web aplication.
 
Marko Debac
Ranch Hand
Posts: 121
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I was having problem with saying web app to use my jdbcRealm for authentication module; not to put jdbcRealm to be default realm puting it manualy at SJSAS, but instead I need specify the realm in sun-application.xml who is part of the ear, as below:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sun-application PUBLIC '-//Sun Microsystems, Inc.//DTD Application Server 9.0 Java EE Application 5.0//EN' 'http://www.sun.com/software/appserver/dtds/sun-application_5_0-0.dtd'>
<sun-application>
<realm>myjdbcrealm</realm>
</sun-application>

Than default realm at SJSAS can be some other realm, but my app will still use myjdbcRealm.

Thanks,
I must try the solution now.

Regardes.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic