• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Problem testing my session Bean.

 
Ranch Hand
Posts: 681
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using WebSphere 5.
I have created my first Session Bean using the create EJB Project and Create EJB Bean wizards.
When I attempted to test my Bean, The server started ok, and then I got the following message :
Directory "C:\IBM\WebSpere studio\runtimes\base_v5/temp" does not exist. The EJB Container will use the current directory for passivating beans.
Module, FirstEJBProject.jar, of application, FirstEJBEAR, failed to initialize
An error occurred initializing, FirstEJBEAR.
I followed all the steps so I am not sure why the FirstEJBProject.jar did not initialize.
Has anyone else had this problem.
Thanks for any help.
Tony
 
Tony Evans
Ranch Hand
Posts: 681
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The problem is within my Home Interface.
I have the following code :
ackage FirstEJB;
import java.rmi.*;
/**
* Home interface for Enterprise Bean: FirstSessionEJB
*/
public interface FirstSessionEJBHome extends javax.ejb.EJBHome,Remote
{
/**
* Creates a default instance of Session Bean: FirstSessionEJB
*/
public FirstEJB.FirstSessionEJB create()
throws javax.ejb.CreateException,
java.rmi.RemoteException;
}
But when I compile it with the websphere development studio I get the folloiwng error :
KindStatusPriorityDescriptionResourceIn FolderLocation
Error
CHKJ2402E: This method must return <remote> (EJB 2.0: 6.3.1, 7.8, 7.10.6).FirstSessionEJBHome.javaFirstEJBProject/ejbModule/FirstEJB
Thanks for any help.
Tony
 
author
Posts: 3902
10
Redhat Quarkus Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It looks like your package structure isn't right. Or at least the error indicates that the Session EJB class isn't in the package it expects it to be (e.g. notice that the FirstEJB folder is missing...)
Kyle
 
Tony Evans
Ranch Hand
Posts: 681
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thankyou Kyle Brown, I restarted from scratch and now have a working bean.
Thanks again Tony
 
reply
    Bookmark Topic Watch Topic
  • New Topic