How do I map support classes to EJB jars
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Clifton_Craig
Posted On:   Monday, August 18, 2003 06:30 AM

Hello all, I'm trying to build/update a bunch of EJB jar files in a directory using the ejbjar task with the jonas sub-element. The problem is that I'm using the deployment descriptor naming to create/name the jar files appropriately. I keep all of my deploy descriptors in a META-INF directory in the root of my project prefixing them with the Bean name they correspond to. So for example I'd have Address-ejb-jar.xml for the Address bean, Customer-ejb-jar.xml for the Customer bean and so forth. For my entity beans I have a supporting DXO bean that needs to be included in the jar. My question is how do I include only the AddressDXO.class in the Address jar and only the CustomerDXO.class in the Customr jar and so forth? My instincts tell me that I need a m   More>>

Hello all,

I'm trying to build/update a bunch of EJB jar files in a directory using the ejbjar task with the jonas sub-element. The problem is that I'm using the deployment descriptor naming to create/name the jar files appropriately. I keep all of my deploy descriptors in a META-INF directory in the root of my project prefixing them with the Bean name they correspond to. So for example I'd have Address-ejb-jar.xml for the Address bean, Customer-ejb-jar.xml for the Customer bean and so forth. For my entity beans I have a supporting DXO bean that needs to be included in the jar. My question is how do I include only the AddressDXO.class in the Address jar and only the CustomerDXO.class in the Customr jar and so forth? My instincts tell me that I need a mapper but I'm not exactly sure how I would code it in the buil or how exactly it would work. This is what I have so far:

			

dependency="none"
naming="descriptor"
descriptordir="${project.base}/../META-INF">

jonasroot="${appserver.root}"
orb="${objectweb.orb}"/>







${project.base actually points to the classes folder in the project's root directory. All of the other properties are picked up from an external properties file. The rel.dir property was being set from a custom task I built which resolves the relative directory from the bases directory and another directory passed in from a calling task. You see I was previously iterating over each bean directory in the foreach task and calling the ejbjar task which individually grabbed the deploy descriptor from a sub-folder in each bean's directory. I'm changing this because it was running too in-efficiently. I want to run ejbjar over the entire project. Can someone help me?

Thanks in advance,
-Cliff    <<Less

Re: How do I map support classes to EJB jars

Posted By:   Anonymous  
Posted On:   Friday, August 22, 2003 09:21 AM

1)With pathconvert, you can get the name of your xml files from the fileset "*ejb-jar.xml"

2)With basename task with which you can find the Address part in Address-ejb-jar.xml.

3) then you can do includes="${rel.dir}/${basename}DXO.class" assuming you called basename the property which you set with the basename task.
About | Sitemap | Contact