Hi there! The ejb-name is a name that does not *need* to match the bean name or interface. You could (although it would be bad idea) give each of your beans names like: Foo, Bar, etc. even though your actual component interfaces are Customer, Advice, etc.
It is generally good practice, though, to give your bean an ejb-name that represents the bean, not one of its interfaces, although many use this practice:
Remote:
Remote Component interface: Customer
Remote Home interface: CustomerHome
Local Component interface: CustomerLocal
Local Home interface: CustomerHomeLocal or CustomerLocalHome
Bean class name: CustomerBean
ejb-name in DD: CustomerBean (or Customer)
(So the ejb-name often matches the bean class name or remote component interface name, which is generally the bean class name *minus* the
word "bean".)
Remember that the ejb-name is never used in code, or in JNDI lookups, etc. The ejb-name is used ONLY as a kind of "label" in the DD. It is a name that you can use in *other* parts of the DD to tell the DD which actual bean you are referring to, without having to redefine all the core info about the bean everywhere you need to refer to one. For example, an ejb-ref can use the ejb-link to specify WHICH bean you're *really* talking about, and value of the ejb-link tag must match the value of an ejb-name tag somewhere else in the DD.
cheers,
Kathy