001: /*
002: * BEGIN_HEADER - DO NOT EDIT
003: *
004: * The contents of this file are subject to the terms
005: * of the Common Development and Distribution License
006: * (the "License"). You may not use this file except
007: * in compliance with the License.
008: *
009: * You can obtain a copy of the license at
010: * https://open-esb.dev.java.net/public/CDDLv1.0.html.
011: * See the License for the specific language governing
012: * permissions and limitations under the License.
013: *
014: * When distributing Covered Code, include this CDDL
015: * HEADER in each file and include the License file at
016: * https://open-esb.dev.java.net/public/CDDLv1.0.html.
017: * If applicable add the following below this CDDL HEADER,
018: * with the fields enclosed by brackets "[]" replaced with
019: * your own identifying information: Portions Copyright
020: * [year] [name of copyright owner]
021: */
022:
023: /*
024: * @(#)InstallationService.java
025: * Copyright 2004-2007 Sun Microsystems, Inc. All Rights Reserved.
026: *
027: * END_HEADER - DO NOT EDIT
028: */
029:
030: package com.sun.esb.management.api.installation;
031:
032: import java.util.Map;
033: import java.util.Properties;
034:
035: import com.sun.esb.management.common.ManagementRemoteException;
036:
037: /**
038: * Defines operations for common installation services.
039: *
040: * @author graj
041: */
042: public interface InstallationService {
043: /**
044: * installs component (service engine, binding component)
045: *
046: * @param paramProps
047: * Properties object contains name/value pair.
048: * @param zipFilePath
049: * archive file in a zip format
050: * @param targetName
051: * name of the target for this operation
052: * @return The name of the component if successful
053: * @throws ManagementRemoteException
054: * on error
055: */
056: public String installComponent(String zipFilePath,
057: Properties paramProps, String targetName)
058: throws ManagementRemoteException;
059:
060: /**
061: * installs component (service engine, binding component)
062: *
063: * @param zipFilePath
064: * archive file in a zip format
065: * @param targetName
066: * name of the target for this operation
067: * @return The name of the component if successful
068: * @throws ManagementRemoteException
069: * on error
070: */
071: public String installComponent(String zipFilePath, String targetName)
072: throws ManagementRemoteException;
073:
074: /**
075: * installs component (service engine, binding component) from the domain
076: * target
077: *
078: * @param componentName
079: * name of the component.
080: * @param component
081: * configuration properties
082: * @param targetName
083: * name of the target for this operation
084: * @return The name of the component if successful
085: * @throws ManagementRemoteException
086: * on error
087: */
088: public String installComponentFromDomain(String componentName,
089: Properties properties, String targetName)
090: throws ManagementRemoteException;
091:
092: /**
093: * installs component (service engine, binding component) from the domain
094: * target
095: *
096: * @param componentName
097: * name of the component.
098: * @param targetName
099: * name of the target for this operation
100: * @return The name of the component if successful
101: * @throws ManagementRemoteException
102: * on error
103: */
104: public String installComponentFromDomain(String componentName,
105: String targetName) throws ManagementRemoteException;
106:
107: /**
108: * installs shared library
109: *
110: * @param zipFilePath
111: * archive file in a zip format
112: * @param targetName
113: * name of the target for this operation
114: * @return shared library name string.
115: * @throws ManagementRemoteException
116: * on error
117: */
118: public String installSharedLibrary(String zipFilePath,
119: String targetName) throws ManagementRemoteException;
120:
121: /**
122: * installs shared library from domain target
123: *
124: * @param libraryName
125: * Shared Library Name
126: * @param targetName
127: * name of the target for this operation
128: * @return shared library name string.
129: * @throws ManagementRemoteException
130: * on error
131: */
132: public String installSharedLibraryFromDomain(String libraryName,
133: String targetName) throws ManagementRemoteException;
134:
135: /**
136: * uninstalls component (service engine, binding component) with option to
137: * retain in domain target and option to forcibly remove from specified
138: * target
139: *
140: * @param componentName
141: * name of the component
142: * @param forceDelete
143: * true to delete, false to not
144: * @param retainInDomain
145: * true to not delete it from the domain target, false to also
146: * delete it from the domain target.
147: * @param targetName
148: * name of the target for this operation
149: * @return The name of the component if successful
150: * @throws ManagementRemoteException
151: * on error
152: */
153: public String uninstallComponent(String componentName,
154: boolean forceDelete, boolean retainInDomain,
155: String targetName) throws ManagementRemoteException;
156:
157: /**
158: * uninstalls component (service engine, binding component) with forcibly
159: * remove option
160: *
161: * @param componentName
162: * name of the component
163: * @param forceDelete
164: * true to delete, false to not
165: * @param targetName
166: * name of the target for this operation
167: * @return The name of the component if successful
168: * @throws ManagementRemoteException
169: * on error
170: */
171:
172: public String uninstallComponent(String componentName,
173: boolean forceDelete, String targetName)
174: throws ManagementRemoteException;
175:
176: /**
177: * uninstalls component (service engine, binding component)
178: *
179: * @param componentName
180: * name of the component
181: * @param targetName
182: * name of the target for this operation
183: * @return The name of the component if successful
184: * @throws ManagementRemoteException
185: * on error
186: */
187: public String uninstallComponent(String componentName,
188: String targetName) throws ManagementRemoteException;
189:
190: /**
191: * uninstalls shared library with option to retain in domain target and
192: * option to forcibly remove from specified target
193: *
194: * @param sharedLibraryName
195: * name of the shared library
196: * @param forceDelete
197: * true to delete, false to not
198: * @param retainInDomain
199: * true to not delete it from the domain target, false to also
200: * delete it from the domain target.
201: * @param targetName
202: * name of the target for this operation
203: * @return shared library name string.
204: * @throws ManagementRemoteException
205: * on error
206: */
207: public String uninstallSharedLibrary(String sharedLibraryName,
208: boolean forceDelete, boolean retainInDomain,
209: String targetName) throws ManagementRemoteException;
210:
211: /**
212: * uninstalls shared library with option to forcibly remove
213: *
214: * @param sharedLibraryName
215: * name of the shared library
216: * @param forceDelete
217: * true to delete, false to not
218: * @param targetName
219: * name of the target for this operation
220: * @return shared library name string.
221: * @throws ManagementRemoteException
222: * on error
223: */
224: public String uninstallSharedLibrary(String sharedLibraryName,
225: boolean forceDelete, String targetName)
226: throws ManagementRemoteException;
227:
228: /**
229: * uninstalls shared library
230: *
231: * @param sharedLibraryName
232: * name of the shared library
233: * @param targetName
234: * name of the target for this operation
235: * @return shared library name string.
236: * @throws ManagementRemoteException
237: * on error
238: */
239: public String uninstallSharedLibrary(String sharedLibraryName,
240: String targetName) throws ManagementRemoteException;
241:
242: /**
243: * upgrades component (service engine, binding component) Upgrades a
244: * component in a way that actually involves the component. During the
245: * upgrade processing, the component's implementation of the new upgrade SPI
246: * will be invoked to give the component the opportunity to perform any
247: * special processing necessary to complete the upgrade. Components which do
248: * not provide an implementation of the upgrade SPI can still be updated
249: * using the updateComponent API.
250: *
251: * Also, in the upgrade implementation, changes in the component's
252: * installation descriptor will be allowed, with the exception of the
253: * component name (for obvious reasons). This allows new shared library
254: * dependencies, changes to the class names of the component's SPI
255: * implementations, and changes to the component's class loading preferences
256: * (class path and class loading order). These changes are allowed
257: * regardless of whether or not the component provides an implementation of
258: * the new upgrade SPI.
259: *
260: * @param componentName
261: * Name of the component to update.
262: * @param zipFilePath
263: * archive file in a zip format
264: * @return The name of the component if successful
265: * @throws ManagementRemoteException
266: * on error
267: */
268: public String upgradeComponent(String componentName,
269: String zipFilePath) throws ManagementRemoteException;
270:
271: // ///////////////////////////////////////////
272: // Start of Cumulative Operation Definitions
273: // ///////////////////////////////////////////
274:
275: /**
276: * installs component ( service engine, binding component)
277: *
278: * @param paramProps
279: * Properties object contains name/value pair.
280: * @param zipFilePath
281: * archive file in a zip format
282: * @param targetNames
283: * @return name of the component as map of [targetName,string].
284: * @throws ManagementRemoteException
285: * on error
286: *
287: */
288: public Map<String, String> installComponent(String zipFilePath,
289: Properties paramProps, String[] targetNames)
290: throws ManagementRemoteException;
291:
292: /**
293: * installs component ( service engine, binding component)
294: *
295: * @param paramProps
296: * Properties object contains name/value pair.
297: * @param zipFilePath
298: * archive file in a zip format
299: * @param targetNames
300: * @return name of the component as map of [targetName,string].
301: * @throws ManagementRemoteException
302: * on error
303: *
304: */
305: public Map<String, String> installComponent(String zipFilePath,
306: String[] targetNames) throws ManagementRemoteException;
307:
308: /**
309: * installs shared library
310: *
311: * @param zipFilePath
312: * archive file in a zip format
313: * @param targetNames
314: * @return shared library name as map of [targetName,string].
315: * @throws ManagementRemoteException
316: * on error
317: *
318: */
319: public Map<String, String> installSharedLibrary(String zipFilePath,
320: String[] targetNames) throws ManagementRemoteException;
321:
322: /**
323: * uninstalls component ( service engine, binding component)
324: *
325: * @param componentName
326: * name of the component
327: * @param targetNames
328: * @return name of the component as [targetName, String] map.
329: * @throws ManagementRemoteException
330: * on error
331: *
332: */
333: public Map<String, String> uninstallComponent(String componentName,
334: String[] targetNames) throws ManagementRemoteException;
335:
336: /**
337: * uninstalls shared library
338: *
339: * @param sharedLibraryName
340: * name of the shared library
341: * @param targetNames
342: * @return shared library name as [targetName, string] map.
343: * @throws ManagementRemoteException
344: * on error
345: *
346: */
347: public Map<String, String> uninstallSharedLibrary(
348: String sharedLibraryName, String[] targetNames)
349: throws ManagementRemoteException;
350:
351: /**
352: * installs component from Domain( service engine, binding component)
353: *
354: * @param componentName
355: * name of the component
356: * @param targetNames
357: * array of targets for this operation
358: * @return Map of targetName and component name strings.
359: * @throws ManagementRemoteException
360: * on error
361: */
362: public Map<String /* targetName */, String /* targetResult */> installComponentFromDomain(
363: String componentName, String[] targetNames)
364: throws ManagementRemoteException;
365:
366: /**
367: * installs component from Domain( service engine, binding component)
368: *
369: * @param componentName
370: * name of the component
371: * @param properties
372: * configuration properties
373: * @param targetNames
374: * array of targets for this operation
375: * @return Map of targetName and component name strings.
376: * @throws ManagementRemoteException
377: * on error
378: */
379: public Map<String /* targetName */, String /* targetResult */> installComponentFromDomain(
380: String componentName, Properties properties,
381: String[] targetNames) throws ManagementRemoteException;
382:
383: /**
384: * uninstalls component ( service engine, binding component)
385: *
386: * @param componentName
387: * name of the component
388: * @param forceDelete
389: * true to delete, false to not
390: * @param targetName
391: * name of the target for this operation
392: * @return Map of targetName and component name strings.
393: * @throws ManagementRemoteException
394: * on error
395: */
396: public Map<String /* targetName */, String /* targetResult */> uninstallComponent(
397: String componentName, boolean forceDelete,
398: String[] targetNames) throws ManagementRemoteException;
399:
400: /**
401: * installs shared library
402: *
403: * @param libraryName
404: * name of the library
405: * @param targetName
406: * name of the target for this operation
407: * @return Map of targetName and shared library name strings.
408: * @throws ManagementRemoteException
409: * on error
410: */
411: public Map<String /* targetName */, String /* targetResult */> installSharedLibraryFromDomain(
412: String libraryName, String[] targetNames)
413: throws ManagementRemoteException;
414:
415: /**
416: * uninstalls shared library
417: *
418: * @param sharedLibraryName
419: * name of the shared library
420: * @param forceDelete
421: * true to delete, false to not
422: * @param targetName
423: * name of the target for this operation
424: * @return Map of targetName and shared library name strings.
425: * @throws ManagementRemoteException
426: * on error
427: */
428: public Map<String /* targetName */, String /* targetResult */> uninstallSharedLibrary(
429: String sharedLibraryName, boolean forceDelete,
430: String[] targetNames) throws ManagementRemoteException;
431:
432: /**
433: * uninstalls component ( service engine, binding component)
434: *
435: * @param componentName
436: * name of the component
437: * @param forceDelete
438: * true to delete, false to not
439: * @param retainInDomain
440: * true to not delete it from the domain target, false to also
441: * delete it from the domain target.
442: * @param targetNames
443: * array of targets for this operation
444: * @return Map of targetName and component name strings.
445: * @throws ManagementRemoteException
446: * on error
447: */
448:
449: public Map<String /* targetName */, String /* targetResult */> uninstallComponent(
450: String componentName, boolean forceDelete,
451: boolean retainInDomain, String[] targetNames)
452: throws ManagementRemoteException;
453:
454: /**
455: * uninstalls shared library
456: *
457: * @param sharedLibraryName
458: * name of the shared library
459: * @param forceDelete
460: * true to delete, false to not
461: * @param retainInDomain
462: * true to not delete it from the domain target, false to also
463: * delete it from the domain target.
464: * @param targetNames
465: * array of targets for this operation
466: * @return Map of targetName and shared library name strings.
467: * @throws ManagementRemoteException
468: * on error
469: */
470: public Map<String /* targetName */, String /* targetResult */> uninstallSharedLibrary(
471: String sharedLibraryName, boolean forceDelete,
472: boolean retainInDomain, String[] targetNames)
473: throws ManagementRemoteException;
474:
475: // ///////////////////////////////////////////
476: // End of Cumulative Operation Definitions
477: /////////////////////////////////////////////
478: }
|