wm.hadoop.hdfs:open
The wm.hadoop.hdfs:open service enables you to open a stream to an HDFS file to perform read and write operations. In addition, the service allows you to specify rollover properties for writing to the file based on its size or the duration of the write operation.
Input Parameters
| ConnectionName | String Name of the Adapter for HDFS connection for connecting to the HDFS cluster. | |
| hdfsFilePath | String Path to the HDFS file to open. You can specify either the relative path to the file (for example, files/abc.txt) or its absolute path (for example, /users/hduser/files/abc.txt). | |
| rolloverType | String Type of rollover to
be performed. You can specify either the file size or duration for the write
operation.
Specify the following parameters only if you want the write operation to be performed until the file reaches a specified size or for a specified duration. After the specified file size or duration is reached, the write operation continues in a new file. Set to:
|
|
| openType | String Specifying the type
of operation to be performed for which the file is being opened.
Set to:
|
|
| rolloverUnit | String Specify the unit of the rollover for write operations. | |
| writeMode | String The mode in which to
write to the specified HDFS file.
Specify this parameter only if
openType is set to
Set to:
|
|
| permissions | String Name of a registered, IANA character set. If you specify an unsupported encoding, the system throws an exception | |
Output Parameters
| status | String The status of the
open operation. The valid value of this parameter can either be
success or
failure.
|
| message | String A detailed message specifying the reason for the success or failure of the open operation. |
| handle | String Handle of the HDFS file to which the stream is opened. |