// Get the deployed Composites
connect('weblogic', 'Welcome1', 't3://localhost:7001')
domainRuntime()
soaBean = ObjectName('oracle.soa.config:Location=AdminServer,name=soa-infra,j2eeType=CompositeLifecycleConfig,Application=soa-infra')
print soaBean
composites = mbs.getAttribute(soaBean, 'DeployedComposites')
for composite in composites:
print 'composite: ',composite
disconnect()
exit()
// Change the Composite auditLevel to Development
print 'starting the script ....'
username = 'weblogic'
password = 'Welcome1'
url='t3://localhost:7001'
connect(username,password,url)
domainRuntime()
helloworldComposite = ObjectName('oracle.soa.config:Location=AdminServer,partition=default,j2eeType=SCAComposite,revision=1.0,label=soa_2073ceb3-d703-453f-8867-79d3b44d637c,Application=soa-infra,wsconfigtype=WebServicesConfig,name="File1"')
print helloworldComposite
params = ['auditLevel','Development']
sign = ['java.lang.String','java.lang.String']
mbs.invoke(helloworldComposite, 'setProperty', params, sign)
print mbs.getAttribute(helloworldComposite, 'Properties')
disconnect()
exit()
disconnect()
exit()
// Print the Composite Properties
print 'starting the script ....'
username = 'weblogic'
password = 'Welcome1'
url='t3://localhost:7001'
connect(username,password,url)
domainRuntime()
helloworldComposite = ObjectName('oracle.soa.config:SCAComposite.SCAService=Test1,name=AdapterBinding,revision=1.0,partition=default,SCAComposite="File1",Location=AdminServer,label=soa_2073ceb3-d703-453f-8867-79d3b44d637c,j2eeType=SCAComposite.SCAService.SCABinding,Application=soa-infra')
print helloworldComposite
print mbs.getAttribute(helloworldComposite, 'Properties')
disconnect()
exit()
disconnect()
exit()
// Change the ExcludeFiles property of the File Adapter
print 'starting the script ....'
username = 'weblogic'
password = 'Welcome1'
url='t3://localhost:7001'
connect(username,password,url)
domainRuntime()
helloworldComposite = ObjectName('oracle.soa.config:SCAComposite.SCAService=Test1,name=AdapterBinding,revision=1.0,partition=default,SCAComposite="File1",Location=AdminServer,label=soa_2073ceb3-d703-453f-8867-79d3b44d637c,j2eeType=SCAComposite.SCAService.SCABinding,Application=soa-infra')
print helloworldComposite
print '-----------Before Changes------------------'
print mbs.getAttribute(helloworldComposite, 'Properties')
params = ['ExcludeFiles','*.akshay*']
sign = ['java.lang.String','java.lang.String']
mbs.invoke(helloworldComposite, 'setStringProperty', params, sign)
print '-----------After Changes------------------'
print mbs.getAttribute(helloworldComposite, 'Properties')
disconnect()
exit()
disconnect()
exit()
// Display the MDS listPartitions
connect('weblogic', 'Welcome1', 't3://localhost:7001')
domainRuntime()
mdsBean = ObjectName('oracle.mds.lcm:name=MDSDomainRuntime,type=MDSDomainRuntime')
print 'invoke listRepositories without parameters on mds bean'
repositories = mbs.invoke(mdsBean, 'listRepositories',None,None)
for repository in repositories:
mdsObject = ObjectName(repository)
Name = mbs.getAttribute(mdsObject, 'Name')
print 'mds repository object: ', Name
params = [Name]
sign = ['java.lang.String']
partitions = mbs.invoke(mdsBean, "listPartitions", params, sign)
for partition in partitions:
print 'partition: ', partition
disconnect()
exit()