IBM Integration Bus, Version 9.0.0.8 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

mqsicreatemsgdefsfromwsdl command

Use the mqsicreatemsgdefsfromwsdl command to import a single WSDL definition into a message set.

Supported platforms

  • Windows
  • Linux on x86

Purpose

If the WSDL is split into multiple files then the file specified must contain the WSDL service definition or binding definition. The WS-I validator can be run automatically on the imported WSDL under the control of the -vfa flag.

  1. Ensure that only the files that are required for the WSDL definition you are importing exist in the directory and subdirectory structure. One of the actions the mqsicreatemsgdefsfromwsdl command performs is to copy all the files in the directory and subdirectories into the workspace prior to creating the message definition. Files that are not associated to that WSDL definition but exist in the directory are also copied.
  2. If the WSDL definition uses a relative path that includes files outside of the directory or subdirectory structure specified, you must import these files into the workspace before you run the command. Make sure that the relative paths are still valid after importing these files into the workspace.
  3. Message sets that are created are namespace enabled.
  4. Existing message sets must be namespace enabled and have an XML physical format.
  5. If you are creating a new message set for runtime parsing, you should base it on an existing message set which has an XML physical format.

Syntax

Read syntax diagramSkip visual syntax diagram
>>-mqsicreatemsgdefsfromwsdl-- -p --MessageSetProjectName------->

>-- -d --Pathname of source files folder-- -f--WSDL file name--->

>-- -data --WorkspacePath--------------------------------------->

>--+-------------------------------------------------------+---->
   '- -base --baseMessageSetProjectName\baseMessageSetName-'   

>--+------------------------+--+----------------------------+--->
   '- -binding--BindingName-'  '- -log --ReportFilePathName-'   

>--+--------+--+--------+--------------------------------------->
   '- -rmp -'  '- -rmd -'   

>--+----------------------------------+--+------+--------------><
   '- -vfa--Validation failure action-'  '- -v -'   

Parameters

-p MessageSetProjectName
(Required) The name of the message set project. If the project exists, it must be namespace-enabled. If the project does not exist, a new namespace-enabled project is created.
-base baseMessageSetProjectName\baseMessageSetName
(Optional) If a new message set is to be created, specify the existing message set project and message set on which it is based
-binding BindingName
(Optional) The name of a binding to be imported. This parameter is mandatory if the WSDL definition includes more than one binding, but optional if the WSDL definition includes a single binding
-d Pathname of source files folder
(Required) The absolute or relative path name of the directory where the top-level WSDL file is located. The top-level WSDL file can contain the entire WSDL definition, or it can be the top of a hierarchy of files, each of which can import further files via import elements. An import element specifies the location of the resource to import with a location attribute

The importer attempts to resolve all relative import locations relative to the specified directory; the importer also attempts to resolve any absolute import locations that it encounters. However, avoid using absolute import locations, because any further imports in the hierarchy must use absolute locations after the first time you specify an absolute location. If relative paths are used to resolve relative imports, then the actual imported files must be under the source files folder or a subfolder under the source files folder.

-data WorkspacePath
(Required) The path of the workspace in which your projects are created.

The workspace location is also the default location for projects. Relative paths are interpreted as being relative to the directory from which the command was started.

-f <WSDL file name>
(Required) The file name of the top-level WSDL file to be imported.

Where a path is required to fully identify the filename, the path should be specified using the -d parameter.

-log ReportFilePathName
(Optional) Absolute or relative path name of the report file; if omitted, the report is written to the default log file and is named Wsdl-file-name.wsdl.report.txt. Wsdl-file-name is the name of the WSDL definition you are importing and it is placed in the directory from which the command is invoked.
-rmd
(Optional) Replaces an existing message definition file of the same name.
Note:
  1. If you omit this flag, and a message definition file of the same name exists, a warning is returned.
  2. The location of the generated message definition file in the message set is determined by the target namespace.
-rmp
(Optional) Replaces the existing project of the same name.
-v
(Optional) Verbose report.
-vfa
(Optional) Validation failure action. Specifies the required action if WS-I compliance checking detects a problem in the WSDL to be imported. The default is set to fail. Select from:
  • fail: If the WSDL definition is not WS-I compliant, the import process stops, and errors are written to the log file.
  • warn: If the WSDL definition is not WS-I compliant, the import process writes warning errors to the log file.
  • ignore: If the WSDL definition is not WS-I compliant, the import process ignores them and informational messages of how this WSDL definition is not compliant to the WS-I profile are written to the logfile.

Authorization

On Windows systems, the user ID used to run this command must be running with elevated privileges on the local system:
  • The user ID must be a member of the group Administrators.
  • The command must be started from an environment that has Run as Administrator authority.

If you do not run the command from a privileged environment, you are asked to confirm that you want to continue. When you click OK, a new privileged command console is created and the command completed, but all responses are written to the privileged environment and are lost when that console closes when the command completes.

On other platforms, no specific authority is required to run this command.

Examples

In the following example, the WSDL document service.wsdl which exists in the directory wsdlfiles, is to be imported into the project myProject and overwrite the project if it exists.

mqsicreatemsgdefsfromwsdl  -p myProject -d .\wsdlfiles -f service.wsdl -rmd -data .\wsdlfilewspc

In the following example, the WSDL document service.wsdl which exists in the directory wsdlfiles, is to be imported to create a new message set project (newProj) based on an existing project (existingProj).

mqsicreatemsgdefsfromwsdl  -p newProj -base existingProj -d .\wsdlfiles -f service.wsdl -data .\wsdlfilewspc

an07355_.htm | Last updated Friday, 21 July 2017