Aakarsh Rawat asked 1 year ago
Title : How to Delete/export/import metatdata through wlst.

Question :

How to Delete/export/import metatdata through wlst.

1 Answers
ParwezParwez Staff answered 1 year ago

Oracle SOA 11G MDS is used as a shared repository for managing and reusing shared resources like WSDL, XSD, DVM, XREF, FAULT-POLICIES and CONSTANTS across applications.

Following is the description to use WLST commands to import , export and delete contents from MDS.

cd ${ORACLE_HOME}/oracle_common/common/bin
run wlst.sh as ./wlst.sh
connect to weblogic server as onnect('weblogic','welcome1','t3://soahost:soaport')

Import Content from MDS:

Import all files and folder :
-----------------------------
importMetadata(application='soa-infra',server='soa_server1',
               fromLocation='C:/Saba/soa11g/mds/',docs='/apps/**')

Import files under specified directory to MDS:
----------------------------------------------
importMetadata(application='soa-infra',server='soa_server1',
           fromLocation='C:/Saba/soa11g/mds/',docs='/apps/util/DVM/**')
importMetadata(application='soa-infra',server='soa_server1',
           fromLocation='C:/Saba/soa11g/mds/',docs='/apps/util/XREF/**')

Import specific file to MDS:
---------------------------------
importMetadata(application='soa-infra',server='soa_server1',
               fromLocation='C:/Saba/soa11g/mds/',
               docs='/apps/util/DVM/COUNTRYCODE.dvm')
Export content from MDS:

Export all files and folders from MDS:
--------------------------------------
exportMetadata(application='soa-infra', server='soa_server1',
               toLocation='C:/Saba/soa11g/mds/', docs='/**')

Export all files and folders inside "/apps" folder :
----------------------------------------------------
exportMetadata(application='soa-infra', server='soa_server1',
              toLocation='C:/Saba/soa11g/mds/', docs='/apps/**')

Export specific folder :
-----------------------
exportMetadata(application='soa-infra', server='soa_server1',
               toLocation='C:/Saba/soa11g/mds/', 
               docs='/apps/util/fault-policies/**')
exportMetadata(application='soa-infra', server='soa_server1',
           toLocation='C:/Saba/soa11g/mds/', docs='/apps/util/DVM/**')
exportMetadata(application='soa-infra', server='soa_server1',
           toLocation='C:/Saba/soa11g/mds/', docs='/apps/util/XREF/**')

Export specific file:
---------------------
exportMetadata(application='soa-infra', server='soa_server1',
               toLocation='C:/Saba/soa11g/mds/',
               docs='/apps/util/DVM/COUNTRYCODE.dvm')


Delete content form MDS:

Delete all files:
-----------------------------
deleteMetadata(application='soa-infra',server='soa_server1',docs='/apps/')

Delete files under specific folder:
-----------------------------------
deleteMetadata(application='soa-infra',server='soa_server1',
               docs='/apps/util/DVM')

Delete specific file:
---------------------
deleteMetadata(application='soa-infra',server='soa_server1',
               docs='/apps/util/DVM/COUNTRYCODE.dvm')


Delete folders from MDS:

Go to ${ORACLE_HOME}/Oracle_SOA1/common/bin
Execute wlst.sh file.
wls:/offline>connect('weblogic','welcome1','t3://localhost:7011')
wls:/SOA-domain/serverConfig> sca_removeSharedData('http://localhost:8011',
                                    'DVM')
Example: sca_removeSharedData('http://<ManagerServerHost>:<ManagedServerPort>',
                              'DVM')
 
 
 

Cubastion is among a very small number of specialized Siebel CRM Oracle Gold Partners in SME.