01: /**
02: * JOnAS: Java(TM) Open Application Server
03: * Copyright (C) 2006 Bull S.A.S.
04: * Contact: jonas-team@objectweb.org
05: * Copyright (C) 2006 Distributed Systems Lab.
06: * Universidad Polit??cnica de Madrid (Spain)
07: * Contact: http://lsd.ls.fi.upm.es/lsd
08: *
09: * This library is free software; you can redistribute it and/or
10: * modify it under the terms of the GNU Lesser General Public
11: * License as published by the Free Software Foundation; either
12: * version 2.1 of the License, or any later version.
13: *
14: * This library is distributed in the hope that it will be useful,
15: * but WITHOUT ANY WARRANTY; without even the implied warranty of
16: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17: * Lesser General Public License for more details.
18: *
19: * You should have received a copy of the GNU Lesser General Public
20: * License along with this library; if not, write to the Free Software
21: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
22: * USA
23: *
24: * --------------------------------------------------------------------------
25: *
26: * --------------------------------------------------------------------------
27: */package org.objectweb.jonas_ejb.container;
28:
29: import java.rmi.NoSuchObjectException;
30: import java.rmi.Remote;
31: import java.rmi.RemoteException;
32:
33: import org.objectweb.carol.cmi.ServerConfigException;
34: import org.objectweb.carol.cmi.configuration.TraceCmi;
35: import org.objectweb.jonas_ejb.deployment.api.SessionDesc;
36:
37: /**
38: * This class is the Standard Home for replicated SSB objects It exists only
39: * for beans that have declared a Remote Interface.
40: * @author Francisco Perez-Sorrosal (fpsorrosal@no-spam@fi.upm.es)
41: * @author Alberto Paz-Jimenez (apaz@no-spam@fi.upm.es)
42: * @author Benoit Pelletier
43: */
44: public abstract class JRepStatelessHome extends JSessionHome {
45:
46: /**
47: * Constructor
48: * @param dd
49: * @param bf
50: * @throws RemoteException
51: */
52: public JRepStatelessHome(SessionDesc dd, JSessionFactory bf)
53: throws RemoteException {
54: super (dd, bf);
55: if (TraceCmi.isDebugCmiHA()) {
56: TraceCmi.debugCmiHA("JRepStatelessHome");
57: }
58: }
59:
60: /**
61: * Get the remote object as a stub object for HA remote object LB
62: * @param remote remote object
63: * @return get remote object
64: * @throws RemoteException
65: * @throws ServerConfigException
66: * @throws NoSuchObjectException if the clustered object is not found in the
67: * CMI registry
68: */
69: public Remote getHARemoteStub(Remote remote) throws RemoteException {
70: return JRepUtil.getHARemoteStub(remote, dd);
71: }
72:
73: }
|