• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Modifying a WebObjects application to run under JBoss
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Modifying a WebObjects application to run under JBoss


  • Subject: Re: Modifying a WebObjects application to run under JBoss
  • From: "Colin O'Brien" <email@hidden>
  • Date: Thu, 12 Feb 2004 21:53:28 -0500

Hi, I never did get any responses on the attached, but I thought I would share some notes on our experiences, and new questions...

On Feb 6, 2004, at 1:47 PM, Colin O'Brien wrote:

Hi,

we have started looking at JBoss and have some very basic questions...

* if you go the whole way and set SERVLET_TRUE_WAR = YES and deploy on JBoss, what does the URL look like?
It seems unlikely it's going to include cgi-bin/WebObjects, but then it has to have the application/component somewhere ?!?

One of the cool things is that the war on a development system is automatically created AND moved to the JBoss deploy directory.
So all you need to do is go to the browser and type the URL (as aopropriate, for example)
http://servename:8080/appname/WebObjects/appname.woa/wa/default
and up comes your application.


You can actually reduce it down to /appname/WebObjects but not /appname
You can actually rename your war file from appname.war to yourname.war and then your url becomes
http://servename:8080/yourname/WebObjects/appname.woa/wa/default
(JBoss automatically undeploys the "old" app and deploys the "new" one when you rename!)
and I think you can achieve the same effect by specifying yourname in one of the xml files, though I don't know if that would achieve the more useful effect of having a collective "branding" for a set of applications.
Anyway, still doesn't seem to be a way to do without the word WebObjects in your URL - maybe there's a way to get Apache/JBoss to trigger off the woa extension?


The automatic deploy is very cool - the first time.
I'm having trouble with subsequent builds.
If it's a regular incremental build, the new version doesn't appear (the old one continues to appear).
If you look at the JBoss console, you see an error during the deploy
15:07:46,361 INFO [appname] javax.naming.NamingException: Could not dereference object. Root exception is javax.naming.NameNotFoundException: YOU MUST CONFIGURE THIS PROPERTY TO DEPLOY not bound
Obviously related to this line
<jndi-name>java:/YOU MUST CONFIGURE THIS PROPERTY TO DEPLOY</jndi-name>
in Resources/Servlet Resources/WEB-INF/jboss-web.xml
but if there's anything that tells you what to put here, then I've missed it.


Curiously, if you do a Build>Clean All Targets, and then Build and Run again, this time the new version does deploy and replace the running version successfully.
Not terribly practical on a large project, but presumably once we know the jndi-name requirement we won't have to worry about this.


* are you (still) using your Apache when connecting with/to JBoss?
I believe JBOss subsumes Tomcat, but typing port numbers can be very confusing for web site visitors and so you want something answering on port 80.
That seems to imply JBoss is listening on 80, or Apache is listening on port 80 and can can pass the request to JBoss.
JBoss to WO seems easy enough - that's what the .war does.

As illustrated above, in a default OS X development environment, JBoss is listening on the Tomcat port 8080.
We tried adding the mod-jk lines to httpd.conf and restarting Apache and deleting the 8080 from the URL
- Apache didn't seem to see anything in the URL to associate it with JBoss/Tomcat and returned a Not Found.
Not that my mod-jk is working - if I try a URL with a regular .jsp I get Internal Server Error and the mod-jk.log says it doesn't see Tomcat and I might want to check which port it is listening on - but there is definitely a specific problem with WO under JBoss and Apache.


Which is unfortunate - we are retrieving some image and style sheet files directly from the webserver.
Running under JBoss they are coming up as Not Found.


* I installed JBoss on to a development system from the XCode developer CD.
Even with SERVLET_TRUE_WAR = YES, if I build and run, the project comes up as a regular cgi-bin/WebObjects
Is there a way (from XCode) to get it running under JBoss on the development system?

See above.

Is there any relevance to running it under JBoss on the development system?

I think we've demonstrated that if you intend to deploy underJBoss, then you had better test that way as well (not every build perhaps, but certainly before your deploy).


* in traditional WO development, you have a development build target, and then a deployment target.
Is this still necessary when deploying with JBoss?

Obviously, we haven't gotten that far yet, but still interested in hearing of others' experiences.


Finally, this document
http://docs.info.apple.com/article.html?artnum=107649
lists the settings to add to an existing application to convert it to a war.
However, I noticed one setting
SERVLET_STUB_WAR = NO
which does not get created when you start a new WO servlet project.
Don't suppose it matters if NO, presumably, is the default, but when there are only nine lines of documentation in the entire world on WO/JBoss, why should one of the lines be irrelevant?!?


Thanks
Colin
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Modifying a WebObjects application to run under JBoss (From: sean roehnelt <email@hidden>)
 >Re: Modifying a WebObjects application to run under JBoss (From: "Colin O'Brien" <email@hidden>)

  • Prev by Date: Re: Java 1.4.2 Update ..... safe for WO
  • Next by Date: Re: Downloading attachments to clients from an OB database from WO
  • Previous by thread: Re: Modifying a WebObjects application to run under JBoss
  • Next by thread: how to fetch header info of NSData
  • Index(es):
    • Date
    • Thread