Configure isolated loader repositories for each deployment unit. Read the wiki for this:
Don't forget to configure different URLs for your web application and perhaps different security settings???
The problem I have is that the application needs an exact name (xyz.war). Parts of the application need this name so it is impossible to rename the second one.
the url you posted doesn´t help me out :-(
You can deploy exactly the same application twice (and even more often). The units (e.g. xyz.war) can hold the same resources and have the same name at all.
But you have to configure the loader repositories as described above. And you have to use different URLs for your web app (configured in the deplyoment descriptor of the war) and different JNDI names for your EJBs (configured in the deployment descriptor of the EJB jars).
One thing I don't understand is, why parts of your application need the name of the WAR file...