You can use the editCompUnit command to modify the configuration information for a composition unit that contains an enterprise bundle archive (EBA) asset. If the EBA asset includes composite bundles, the command syntax is slightly different.
For a full description of how you modify this configuration information, see Modifying the configuration of an OSGi composition unit by using wsadmin commands. When you work through that task, each step where the syntax is different for composite bundles is linked to an equivalent step in this task.
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-ContextRootStep [
[bundle_symbolic_name_1 bundle_version_1 context_root_1]
[bundle_symbolic_name_2 bundle_version_2 context_root_2]]
]')
CBA.symbolic.Name_CBA.bundle.version/WAB.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=helloWorldService
-cuID WebSphere:cuname=com.ibm.ws.eba.helloWorldService_0001.eba
-ContextRootStep [
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web 1.0.0
"/hello/web"]
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.withContextRoot 0.9.0
"/hello/service"]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-MDBBindingsStep [
[bundle_symbolic_name_1 bundle_version_1 uri_1
activation_spec_1 destination_jndi_name_1 authentication_alias_1]
[bundle_symbolic_name_2 bundle_version_2 uri_2
activation_spec_2 destination_jndi_name_2 authentication_alias_2]]
]')
CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-MDBBindingsStep [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0
META-INF/ejb-jar.xml/ExchangeRateMDB eis/ExchangeRate_Act_Spec
jms/ExchangeRateQueue ExchangeRate_Auth_Alias]
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.accountService 0.9.0
META-INF/ejb-jar.xml/CustomerDetailsMDB eis/CustomerDetails_Act_Spec
jms/CustomerDetailsQueue CustomerDetails_Auth_Alias]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-EJBMappingsStep [
[bundle_symbolic_name_1 bundle_version_1 ejb_name_1
ejb_interface_1 ejb_interface_type_1 jndi_name_1]
[bundle_symbolic_name_2 bundle_version_2 ejb_name_2
ejb_interface_2 ejb_interface_type_2 jndi_name_2]]
]')
CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-EJBMappingsStep [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0 ExchangeRate_ejb
com.ibm.ws.eba.ejb.ExchangeRate Local ejb/ExchangeRate]
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.accountServicee 0.9.0 CustomerDetails_ejb
com.ibm.ws.eba.ejb.CustomerDetails Remote ejb/CustomerDetails]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-EJBRefStep [
[bundle_symbolic_name_1 bundle_version_1 uri_1
ejb_reference_name_1 business_interface_1 jndi_name_1]
[bundle_symbolic_name_2 bundle_version_2 uri_2
ejb_reference_name_2 business_interface_2 jndi_name_2]]
]')
The uri parameter specifies the location where the EJB reference is defined.CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-EJBRefStep [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0
META-INF/ejb-jar.xml/CurrencyExchange ExchangeRate com.ibm.ws.eba.ejb.ExchangeRate
ejb:ExchangeRate]
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.accountService 0.9.0
WEB-INF/web.xml CustomerDetails com.ibm.ws.eba.ejb.CustomerDetails ejb:CustomerDetails]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-EJBResourceRefs [
[
bundle_symbolic_name
bundle_version
ejb_name
resource_reference_id
resource_type
target_jndi_name
resource_authentication_method
mapping_properties
extended_properties
]]
]')
WebSphere:name=property_name1,value=property_value1,description=property_description1
+WebSphere:name=property_name2,value=property_value2,description=property_description2
+ ...
property_name1=property_value1+property_name2=property_value2+ ...
CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-EJBResourceRefs [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0
ExchangeRate dataSource1 javax.sql.DataSource ref/ds1 ClientContainer
"WebSphere:name=mprop1,value=val1,description=desc1"
"exprop1=expropval1+exprop2=expropval2"]
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.accountService 0.9.0
CustomerDetails dataSource2 javax.sql.DataSource ref/ds2 WSLogin "" ""]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-EJBMsgDestRefs [
[
bundle_symbolic_name
bundle_version
ejb_name
resource_reference_id
resource_type
target_jndi_name
]]
]')
CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-EJBMsgDestRefs [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0
ExchangeRate jms/myQ javax.jms.Queue jms/workQ]
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.accountService 0.9.0
CustomerDetails jms/myT javax.jms.Topic jms/notificationTopic]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-EJBEnvEntryStep [
[
bundle_symbolic_name
bundle_version
ejb_name
env_entry_name
env_entry_type
env_entry_description
env_entry_value
]]
]')
CBA.symbolic.Name_CBA.bundle.version/EJBBundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=financeService
-cuID WebSphere:cuname=com.ibm.ws.eba.financeService_0001.eba
-EJBEnvEntryStep [
[com.ibm.ws.eba.financeCBA_1.0.0/com.ibm.ws.eba.currencyService 1.0.0
ExchangeRate CommissionRate java.lang.Double
"Commission rate applied to currency exchange transactions." 5.75]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-VirtualHostMappingStep [
[bundle_symbolic_name_1 bundle_version_1
web_module_name_1 virtual_host_1]
[bundle_symbolic_name_2 bundle_version_2
web_module_name_2 virtual_host_2]]
]')
CBA.symbolic.Name_CBA.bundle.version/WAB.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=helloWorldService
-cuID WebSphere:cuname=com.ibm.ws.eba.helloWorldService_0001.eba
-VirtualHostMappingStep [
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web
1.0.0 "HelloWorld service" default_host]
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.withContextRoot
0.9.0
"HelloWorld second service" test_host]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-BlueprintResourceRefPostDeployStep [
[
bundle_symbolic_name
bundle_version
blueprint_resource_reference_id
interface_name
jndi_name
authentication_type
sharing_setting
authentication_alias_name
]]
]')
CBA.symbolic.Name_CBA.bundle.version/inner_bundle.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=helloWorldService
-cuID WebSphere:cuname=com.ibm.ws.eba.helloWorldService_0001.eba
-BlueprintResourceRefPostDeployStep[
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.properties.bundle
1.0.0 resourceRef javax.sql.DataSource jdbc/Account Container Shareable alias1]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-WebModuleMsgDestRefs [
[
bundle_symbolic_name
bundle_version
resource_reference_id
resource_type
target_jndi_name
]]
]')
CBA.symbolic.Name_CBA.bundle.version/WAB.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=helloWorldService
-cuID WebSphere:cuname=com.ibm.ws.eba.helloWorldService_0001.eba
-WebModuleMsgDestRefs [
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web
1.0.0
jms/myQ javax.jms.Queue
jms/workQ]
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web
1.0.0
jms/myT javax.jms.Topic
jms/notificationTopic]]
]')
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=bla_name
-cuID WebSphere:cuname=cu_name
-WebModuleResourceRefs [
[
bundle_symbolic_name
bundle_version
resource_reference_id
resource_type
target_jndi_name
login_configuration
login_properties
extended_properties
]]
]')
CBA.symbolic.Name_CBA.bundle.version/WAB.symbolic.name
AdminTask.editCompUnit('[
-blaID WebSphere:blaname=helloWorldService
-cuID WebSphere:cuname=com.ibm.ws.eba.helloWorldService_0001.eba
-WebModuleResourceRefs [
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web
1.0.0
jdbc/jtaDs javax.sql.DataSource
jdbc/helloDs "" "" ""]
[com.ibm.ws.eba.helloWorldCBA_1.0.0/com.ibm.ws.eba.helloWorldService.web
1.0.0
jdbc/nonJtaDs javax.sql.DataSource
jdbc/helloDsNonJta "" "" "extprop1=extval1"]]
]')