blob: 98266ed2ee446b1a7fbf18d7ee8ae7b4897bea14 [file] [log] [blame]
Vinay Vishal7c4c4fc2019-01-28 12:01:04 +05301type=page
2status=published
3title=delete-application-ref
4next=delete-audit-module.html
5prev=delete-admin-object.html
6~~~~~~
7delete-application-ref
8======================
9
10[[delete-application-ref-1]][[GSRFM00064]][[delete-application-ref]]
11
12delete-application-ref
13----------------------
14
15removes a reference to an application
16
17[[sthref585]]
18
19Synopsis
20
21[source,oac_no_warn]
22----
23asadmin [asadmin-options] delete-application-ref [--help]
24[--target target]
25[--cascade=false] reference_name
26----
27
28[[sthref586]]
29
30Description
31
32The `delete-application-ref` subcommand removes a reference from a
33cluster or an unclustered server instance to an application. This
34effectively results in the application element being undeployed and no
35longer available on the targeted instance or cluster.
36
37The target instance or instances making up the cluster need not be
38running or available for this subcommand to succeed. If one or more
39instances are not available, they will no longer load the application
40the next time they start.
41
42Removal of the reference does not result in removal of the application
43from the domain. The bits are removed only by the `undeploy` subcommand.
44
45This subcommand is supported in remote mode only.
46
47[[sthref587]]
48
49Options
50
51asadmin-options::
52 Options for the `asadmin` utility. For information about these
53 options, see the link:asadmin.html#asadmin-1m[`asadmin`(1M)] help page.
54`--help`::
55`-?`::
56 Displays the help text for the subcommand.
57`--target`::
58 Specifies the target from which you are removing the application
59 reference. Valid values are +
60 * `server`- Specifies the default server instance as the target.
61 `server` is the name of the default server instance and is the default
62 value.
63 * cluster_name- Specifies a certain cluster as the target.
64 * instance_name- Specifies a certain stand-alone server instance as
65 the target.
66`--cascade`::
67 For a connector module, indicates whether the resources dependent on
68 the module should also be recursively deleted. The default is `false`.
69 The connector module can be either a stand-alone RAR file or a module
70 within an EAR file.
71
72[[sthref588]]
73
74Operands
75
76reference_name::
77 The name of the application or module, which can be a Java EE
78 application module, Web module, EJB module, connector module,
79 application client module, or lifecycle module. +
80 The name can include an optional version identifier, which follows the
81 name and is separated from the name by a colon (`:`). The version
82 identifier must begin with a letter or number. It can contain
83 alphanumeric characters plus underscore (`_`), dash (`-`), and period
84 (`.`) characters. To delete references to multiple versions, you can
85 use an asterisk (`*`) as a wildcard character. For more information
86 about module and application versions, see "link:../application-deployment-guide/overview.html#GSDPG00324[Module
87 and Application Versions]" in GlassFish Server Open Source Edition
88 Application Deployment Guide.
89
90[[sthref589]]
91
92Examples
93
94[[GSRFM531]][[sthref590]]
95
96Example 1   Deleting an Application Reference
97
98The following example removes a reference to the Web module `MyWebApp`
99from the unclustered server instance `NewServer`.
100
101[source,oac_no_warn]
102----
103asadmin> delete-application-ref --target NewServer MyWebApp
104Command delete-application-ref executed successfully.
105----
106
107[[sthref591]]
108
109Exit Status
110
1110::
112 command executed successfully
1131::
114 error in executing the command
115
116[[sthref592]]
117
118See Also
119
120link:asadmin.html#asadmin-1m[`asadmin`(1M)]
121
122link:create-application-ref.html#create-application-ref-1[`create-application-ref`(1)],
123link:list-application-refs.html#list-application-refs-1[`list-application-refs`(1)],
124link:undeploy.html#undeploy-1[`undeploy`(1)]
125
126link:../application-deployment-guide/toc.html#GSDPG[GlassFish Server Open Source Edition Application Deployment
127Guide]
128
129