This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 63607 - EJB session bean create method must return void
Summary: EJB session bean create method must return void
Status: RESOLVED DUPLICATE of bug 61518
Alias: None
Product: javaee
Classification: Unclassified
Component: EJB (show other bugs)
Version: 5.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Martin Adamek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-03 21:01 UTC by psecheresse
Modified: 2006-06-03 17:53 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description psecheresse 2005-09-03 21:01:08 UTC
The generated code in a BEAN (javax.ejb.SessionBean) isn't correct, see result
below when I use the contextual menu to add a create method:
    public CartRemote ejbCreate(String person, String id) throws
javax.ejb.CreateException {
        //TODO implement 
    }

No error message windows and nothing in the log.

In EJB Specif 2.1 --> 7.11.3 ejbCreate<METHOD> Methods 
The session bean class must define one or more ejbCreate<METHOD> methods whose
signatures must follow these rules:
- The return type must be void.

I think there is a confusion with HOME interface wich conversely need a return
type :
In EJB Specif 2.1 --> 7.11.6 Session Bean’s Remote Home Interface : 
- The return type for a create<METHOD> method must be the session bean’s remote
interface type.

I was working with NetBeans 4.2 200508311800, I did a session bean as described
in the J2EE 1.4 Tutorial with NB 4.1, The CartBean Example Application (Page
file:<INSTALL>/j2eetutorial14%20NB4.1/docs/Session2.html ).
I was at the chapter : The ejbCreate Methods, step 5
Comment 1 Martin Adamek 2005-09-05 12:22:36 UTC

*** This issue has been marked as a duplicate of 61518 ***