Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 57340 - jboss 3.2.3 does not read jboss-web.xml in .war or .ear
Summary: jboss 3.2.3 does not read jboss-web.xml in .war or .ear
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Java team
URL:
Whiteboard:
Keywords: PMASKED
Depends on: 64795
Blocks:
  Show dependency tree
 
Reported: 2004-07-16 17:02 UTC by eric.williams
Modified: 2008-01-26 19:07 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
This is a compressed tarball containing source for a prototype .ear and a log snippet. (AUTO_JMS.tbz,648.85 KB, application/octet-stream)
2004-07-21 06:34 UTC, eric.williams
Details

Note You need to log in before you can comment on or make changes to this bug.
Description eric.williams 2004-07-16 17:02:45 UTC
This was driving me nuts until I (think I) found it.  Or is it a feature?  Color me slightly confused here.

The documentation is clear enough: put jboss-web.xml under WEB-INF in a .war file within a .ear file, and things should work regarding servlets and MDBs (or, as it turns out, arbitrary EJBs).  However, my beans aren't working -- and the log file indicates that the XML files being read during the war deployment do not include jboss-web.xml (although they do include jboss.xml, for some strange reason).

I'll have to see about cobbling up a test case but after looking at the code (at jboss-3.2.3-src/management/src/main/org/jboss/management/j2ee/WebModule.java, around line 329) this appears to be some sort of typo, although I can't say since I don't have the 3.2.1 code handy; nor do I have a .war handy that shows the problem although I can try to upload a small test one if anyone needs it.

(For what it's worth, the code referenced above is still in 3.2.5.)

There is also the faint possibility that jboss-web.xml is no longer required but if so I need to know what in jboss.xml replaces it.

Reproducible: Always
Steps to Reproduce:
1. Create an .ear file containing a .war file with a servlet that uses EJBs.
2. Deploy (by placing in /var/lib/jboss/<server-name>/deploy) the .ear file.
3. Look at the log file, or try to use a capability in the web service that requires access to either an EJB or a MDB Queue or Topic.

Actual Results:  
The log file is not reading jboss-web.xml.

Expected Results:  
The log file should indicate jboss-web.xml is being read, and the hookups
(<resource-ref>, <resource-env-ref>) should be done properly.  (Either that, or
I need to know where to put these hookups.)

# emerge info
Portage 2.0.50-r9 (default-x86-2004.0, gcc-3.3.3, glibc-2.3.3.20040420-r0,
2.4.25-gentoo-r4)
=================================================================
System uname: 2.4.25-gentoo-r4 i686 Intel(R) Xeon(TM) CPU 1.70GHz
Gentoo Base System version 1.4.16
distcc 2.13 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632)
[disabled]Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -mcpu=i686 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3/share/config /usr/lib/mozilla/defaults/pref
/usr/share/config /var/lib/jboss /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -mcpu=i686 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X Xaw3d alsa apache2 apm arts avi berkdb bonobo cdr crypt cups dvd encode
esd flash foomaticdb gdbm gif gnome gpm gtk gtk2 gtkhtml imap imlib java jpeg
kde kerberos ldap libg++ libwww mad mikmod motif mozilla mpeg ncurses nls oci8
oggvorbis opengl oss pam pdflib perl png python qt quicktime readline samba sdl
slang snmp spell ssl svg svga tcltk tcpd tiff truetype unicode x86 xml2 xmms xv
zlib"
Comment 1 Matthew Kennedy (RETIRED) gentoo-dev 2004-07-19 20:43:58 UTC
Hi.  I too, have been struggling to get my servlet and beans deployed successfully this week so perhaps we are having the same problem.  I think this is the 1st time I've tried to deploy on 3.2.3 but can't remember if it worked on 3.2.1.

Could you share a backtrace when you try to run your servlet?  I get a javax.ejb.NamingException: "ejb not bound" exception IIRC.  I'll try to reproduce it here and attach the exact output.  If possible could you share your web.xml and jboss-web.xml?

net-www/jboss-3.2.5 will be committed tonight (~arch keywords), but it will not address this problem.
Comment 2 eric.williams 2004-07-21 06:34:53 UTC
Created attachment 35875 [details]
This is a compressed tarball containing source for a prototype .ear and a log snippet.

[1] Edit /etc/conf.d/jboss so that JBOSS_CONF="all", or copy /var/lib/jboss/all
to /var/lib/jboss/[somewhere] and set JBOSS_CONF="[somewhere]".  Adjust the
pathname in step [4] as needed.
[2] Untar the attachment using the command 'tar xjf AUTO_JMS.tbz'.  You should
see AUTO_JMS and server.log.snippet.
[3] AUTO_JMS contains a build.xml which can be used by ant (if I've done this
properly).  The resulting .ear file is in AUTO_JMS/build/AUTO_JMS.ear .  If you
prefer you can use the existing one, also supplied in the tarball.
[4] Copy the .ear /var/lib/jboss/all/deploy/AUTO_JMS.ear , or create a symbolic
link, and watch it deploy in /var/log/jboss/server.log .
[5] If it deploys successfully (I've tried various deployment descriptors),
access http://localhost:8080/AUTO_JMS_WEB/ and click on the
conveniently-provided link. :-)
Comment 3 Dan A. Dickey 2004-07-21 09:16:56 UTC
I'm not sure what your problem is, but I'll add that
my ear files deploy on 3.2.3 just fine.
I took a quick look at the AUTO_JMS.ear attachment, and did not
see anything amiss or vastly different from my ear files.
When I get a chance, I'll try out your AUTO_JMS.ear file.
Looks like I need to downgrade from 3.2.5 though... :(
Comment 4 Jakub Moc (RETIRED) gentoo-dev 2007-02-04 14:11:22 UTC
mkennedy retired, reassigning to herd.
Comment 5 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2008-01-09 06:46:03 UTC
Last rited: http://archives.gentoo.org/gentoo-dev-announce/msg_00069.xml
Comment 6 William L. Thomson Jr. (RETIRED) gentoo-dev 2008-01-26 19:07:32 UTC
Closing bug. Removed from tree, till we get a maintainer and current version
from source.