Changing the default ports used by JBoss

These two posts describe how to change the default port numbers in JBoss 4.x and 5.x: