I have written a custom implementation for Primary Key Generation using entity command. This implementation works fine for entity beans having Integer as Primary Key Class. The Class Cast Exception is being thrown for the beans having java.lang.Long as primary key Class.
I have the following ejb doclet code in my bean
The exception is thrown when i call local.getEventId() method .
Where should i specify the primary class as java.lang.Long to avoid this exception.