stream topic create

Creates a topic in the specified stream.

To run this command, your user ID must have the adminperm or topicperm permission on the stream.
Note: The mapr user is not treated as a superuser. MapR Streams does not allow the mapr user to run this command unless that user is given the relevant permission or permissions with access-control expressions.

Syntax

CLI
stream topic create
	 -path Stream Path 
	 -topic Topic Name 
	[ -partitions Number of partitions. default: attribute defaultpartitions on the stream ]
REST http[s]://<host>:<port>/rest/stream/topic/create?path=<path>&topic=<name>

Parameters

Parameter Description
path The path and name of the stream in which to create the topic.
topic The name of the topic to create.

A name can include alphanumeric characters and the following characters: . , _ , and - .

partitions The number of partitions to use for the topic. After you create the topic, you can increase the number of partitions, but you cannot reduce the number. The default number of partitions for new topics is set by the defaultpartitions parameter in the commands maprcli stream create and maprcli stream edit.