> -----Original Message----- > From: Kyle Adams [mailto:[EMAIL PROTECTED] > Sent: Monday, October 27, 2003 3:30 PM > To: [EMAIL PROTECTED] > Subject: RE: JAR Repository and File Names > > > > 1) Not using the 'applications' directory for deployment. > > Even though we still put stuff in an applications directory, > that's merely a naming convention--it's not under the > $WL_HOME, so nothing gets auto-deployed (I believe we have > auto deploy turned off in all environments). I think we're > all set on this point.
>From our experience, if you treat the applications directory as a bootstrap for startup of a domain/server then it works, but then you lose the ability to specify the context-root or name in some cirumstances. > > 2) Using the weblogic ant <wldeploy> taskdef > > http://edocs.bea.com/wls/docs81/deployment/tools.html#1000477 > > I took a brief look at this tool, and I'm pretty familiar > with the corresponding WL 7 tool, since that's what we're > using to automate our hot deploys. Now then, bear with me > here, because I really am trying to understand :-) > > If I understand correctly, in your process you do something like: > > <wldeploy action="deploy" source="myEJB-1.0.1.jar" > name="myEJB" user="a" password="a" adminurl="t3://localhost:7001"> > > Even though the EJB previously deployed as "myEJB" was > myEJB-1.0.0.jar, the deploy action above successfully > redeploys myEJB-1.0.1.jar in place of the older jar, correct? Correct, this causes WebLogic (8.1 at least, don't have much experience with the 7.x series) to replace the older jar, but ONLY if we maintain a consistent (non-versioned) context-root or name. > > Using the proprietary <context-root> element in the > > appropriate weblogic.xml deployment descriptor. > > To begin with, most all of our applications are deployed in > EARs - we have very few WARs or EJBs deployed outside an EAR > (meaning that we'd need to dynamically generate the > application.xml from the POM - not impossible, just something > else to script out). > > My understanding of <context-root> within an EAR is that BEA > suggests setting that in the application.xml, where it is > relative to the root of the EAR. I don't think it would do > anything to help or hinder getting around the problem of > ever-changing JAR names. > > Am I missing something there about how you're using <context-root>? Not missing anything, we enforce the context-root or name (depending on if we want an EAR or WAR) and that eliminates the symptom of weblogic deploying multiple versions on the same domain/server combo. Course, there ARE times that you would want to have multiple versions running in a single domain/server, but not during a development cycle. That's more likely to occur in a production capacity. More Info: I've found a few ways to deploy in 8.1 1) From the web console. Pros: Pretty GUI. ;-) Cons: Can't seem to find trick to force a name on deploy tho. 2) From an ant-task (or maven/ant combo) Pros: Developer Friendly. Provides ability to control context-root or name. Cons: Production / Operations Unfriendly. 3) Using deploy via command line utiliy. http://edocs.bea.com/wls/docs81/deployment/tools.html#999152 Pros: Production / Operations friendly. Provides ability to control context-root or name. Very Flexible. Cons: Too Flexible. Used in an inconsistent manner by Production / Operations. ;-) /* joakim */
