KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jonas > resource > ResourceServiceImplMBean


1 /*
2  * JOnAS: Java(TM) Open Application Server
3  * Copyright (C) 1999 Bull S.A.
4  * Contact: jonas-team@objectweb.org
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19  * USA
20  *
21  * Initial developer(s): ____________________________________.
22  * Contributor(s): Michel Bruno and Guillaume Riviere
23  *
24  * --------------------------------------------------------------------------
25  * $Id: ResourceServiceImplMBean.java,v 1.6 2004/10/29 23:33:37 ehardesty Exp $
26  * --------------------------------------------------------------------------
27  */

28
29 package org.objectweb.jonas.resource;
30
31 import java.rmi.RemoteException JavaDoc;
32
33 import java.util.List JavaDoc;
34 import java.util.Set JavaDoc;
35
36 /**
37  * MBean Interface for Resource Service Management
38  * MBean type: Standard
39  * MBean model: Inheritance (ResourceServiceImpl)
40  */

41 public interface ResourceServiceImplMBean {
42
43     /**
44      * Deploy an RAR, used by the JMX Management.
45      * @param fileName the fileName of the rar which must be be deployed.
46      * @return The ObjectName of the MBean associated to the deployed J2EE Application
47      * @throws RemoteException if rmi call failed.
48      * @throws ResourceServiceException if the deployment of the RAR failed.
49      */

50     String JavaDoc deployRarMBean(String JavaDoc fileName) throws RemoteException JavaDoc, ResourceServiceException;
51
52
53     /**
54      * Undeploy an RAR, used by the JMX Management.
55      * @param fileName the fileName of the rar which must be be undeployed.
56      * @throws RemoteException if rmi call failed.
57      * @throws ResourceServiceException if the undeployment of the RAR failed.
58      */

59     void unDeployRarMBean(String JavaDoc fileName) throws RemoteException JavaDoc, ResourceServiceException;
60
61     /**
62      * @return current number of rars deployed in the JOnAS server
63      */

64     Integer JavaDoc getCurrentNumberOfResource();
65
66     /**
67      * @return current number of rars deployed in the JOnAS server
68      */

69     Integer JavaDoc getCurrentNumberOfRars();
70
71     /**
72      * @return the list of RAR files deployed
73      * @throws Exception if error retrieving the list
74      */

75     List JavaDoc getDeployedRars() throws Exception JavaDoc;
76
77     /**
78      * @return the list of RAR files found in JONAS_BASE/rars and in JONAS_BASE/rars/autoload
79      * @throws Exception if error retrieving the list
80      */

81     List JavaDoc getInstalledRars() throws Exception JavaDoc;
82
83     /**
84      * This method is added temporarily. It will disapear when Rars will have their associated MBeans
85      * (when Rars will become manageable)
86      * @return the names of the rars currently deployed in the JOnAS server
87      */

88     Set JavaDoc getRarNames();
89
90     /**
91      * Test if the specified filename is already deployed or not
92      * @param fileName the name of the rar file.
93      * @return true if the rar is deployed, else false.
94      */

95     boolean isRarLoaded(String JavaDoc fileName);
96
97     /**
98      * Return the list of installed RAR container ready to deploy.
99      *
100      * @return The list of deployable RAR container
101      * @throws Exception if error retrieving the list
102      */

103     List JavaDoc getDeployableRars() throws Exception JavaDoc;
104
105     /**
106      * Return the list of "autoload" directories for RAR containers.
107      * @return The list of all "autoload" directories
108      */

109     List JavaDoc getAutoloadDirectories();
110
111     /**
112      * Return the Rars directory.
113      * @return The Rars directory
114      */

115     String JavaDoc getRarsDirectory();
116
117 }
118
Popular Tags