> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kinetica.com/llms.txt
> Use this file to discover all available pages before exploring further.

# gpudb::CreateProcRequest

> gpudb::CreateProcRequest — Kinetica C++ API

<div className="kinetica-doxygen">
  <div className="contents">
    <p>A set of parameters for <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#aece60959dc14eef09c0a3b390ddee6ea">GPUdb::createProc</a>. <a href="#details">More...</a></p>
    <p><code>#include \<<a className="el" href="/content/api/cpp/create__proc_8h_source">gpudb/protocol/create\_proc.h</a>></code></p>

    <table className="memberdecls">
      <tr className="heading">
        <td colSpan="2">
          <h2 className="groupheader"> Public Member Functions</h2>
        </td>
      </tr>

      <tr className="memitem:a7ca18f2159c7956f2043d13368e8f234" id="r_a7ca18f2159c7956f2043d13368e8f234">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a7ca18f2159c7956f2043d13368e8f234">CreateProcRequest</a> ()</td>
      </tr>

      <tr className="memdesc:a7ca18f2159c7956f2043d13368e8f234">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1CreateProcRequest" title="A set of parameters for GPUdb::createProc.">CreateProcRequest</a> object with default parameters. <br /></td>
      </tr>

      <tr className="separator:a7ca18f2159c7956f2043d13368e8f234">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a0b1edea3f78facd742d99f2cdc78d604" id="r_a0b1edea3f78facd742d99f2cdc78d604">
        <td className="memItemLeft" align="right" valign="top"> </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a0b1edea3f78facd742d99f2cdc78d604">CreateProcRequest</a> (const std::string \&procName\_, const std::string \&executionMode\_, const std::map\< std::string, std::vector\< uint8\_t > > \&files\_, const std::string \&command\_, const std::vector\< std::string > \&args\_, const std::map\< std::string, std::string > \&options\_)</td>
      </tr>

      <tr className="memdesc:a0b1edea3f78facd742d99f2cdc78d604">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1CreateProcRequest" title="A set of parameters for GPUdb::createProc.">CreateProcRequest</a> object with the specified parameters. <br /></td>
      </tr>

      <tr className="separator:a0b1edea3f78facd742d99f2cdc78d604">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>
    </table>

    <table className="memberdecls">
      <tr className="heading">
        <td colSpan="2">
          <h2 className="groupheader"> Public Attributes</h2>
        </td>
      </tr>

      <tr className="memitem:a437022c5e0005607d12b2a516b638f5c" id="r_a437022c5e0005607d12b2a516b638f5c">
        <td className="memItemLeft" align="right" valign="top">std::string </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a437022c5e0005607d12b2a516b638f5c">procName</a></td>
      </tr>

      <tr className="memdesc:a437022c5e0005607d12b2a516b638f5c">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Name of the proc to be created. <br /></td>
      </tr>

      <tr className="separator:a437022c5e0005607d12b2a516b638f5c">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a7624608317d319bcf276e0a8111ee995" id="r_a7624608317d319bcf276e0a8111ee995">
        <td className="memItemLeft" align="right" valign="top">std::string </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a7624608317d319bcf276e0a8111ee995">executionMode</a></td>
      </tr>

      <tr className="memdesc:a7624608317d319bcf276e0a8111ee995">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">The execution mode of the proc. <br /></td>
      </tr>

      <tr className="separator:a7624608317d319bcf276e0a8111ee995">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a579671c50c7f210da3dc829e63dc07c6" id="r_a579671c50c7f210da3dc829e63dc07c6">
        <td className="memItemLeft" align="right" valign="top">std::map\< std::string, std::vector\< uint8\_t > > </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a579671c50c7f210da3dc829e63dc07c6">files</a></td>
      </tr>

      <tr className="memdesc:a579671c50c7f210da3dc829e63dc07c6">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">A map of the files that make up the proc. <br /></td>
      </tr>

      <tr className="separator:a579671c50c7f210da3dc829e63dc07c6">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:aa0c2a1ff9bf1f6e3568d5a5e727a0eba" id="r_aa0c2a1ff9bf1f6e3568d5a5e727a0eba">
        <td className="memItemLeft" align="right" valign="top">std::string </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#aa0c2a1ff9bf1f6e3568d5a5e727a0eba">command</a></td>
      </tr>

      <tr className="memdesc:aa0c2a1ff9bf1f6e3568d5a5e727a0eba">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">The command (excluding arguments) that will be invoked when the proc is executed. <br /></td>
      </tr>

      <tr className="separator:aa0c2a1ff9bf1f6e3568d5a5e727a0eba">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:a0cad704e8fd3664bf18ec0ff3fe67b5c" id="r_a0cad704e8fd3664bf18ec0ff3fe67b5c">
        <td className="memItemLeft" align="right" valign="top">std::vector\< std::string > </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#a0cad704e8fd3664bf18ec0ff3fe67b5c">args</a></td>
      </tr>

      <tr className="memdesc:a0cad704e8fd3664bf18ec0ff3fe67b5c">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">An array of command-line arguments that will be passed to <a className="el" href="#aa0c2a1ff9bf1f6e3568d5a5e727a0eba">command</a> when the proc is executed. <br /></td>
      </tr>

      <tr className="separator:a0cad704e8fd3664bf18ec0ff3fe67b5c">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>

      <tr className="memitem:afe992abaab0d7de82dd7bd261c69415a" id="r_afe992abaab0d7de82dd7bd261c69415a">
        <td className="memItemLeft" align="right" valign="top">std::map\< std::string, std::string > </td>
        <td className="memItemRight" valign="bottom"><a className="el" href="#afe992abaab0d7de82dd7bd261c69415a">options</a></td>
      </tr>

      <tr className="memdesc:afe992abaab0d7de82dd7bd261c69415a">
        <td className="mdescLeft"> </td>
        <td className="mdescRight">Optional parameters. <br /></td>
      </tr>

      <tr className="separator:afe992abaab0d7de82dd7bd261c69415a">
        <td className="memSeparator" colSpan="2"> </td>
      </tr>
    </table>

    <h2 className="groupheader">Detailed Description</h2>

    <div className="textblock">
      <p>A set of parameters for <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#aece60959dc14eef09c0a3b390ddee6ea">GPUdb::createProc</a>. </p>
      <p>Creates an instance (proc) of the <a href="/content/concepts/udf/" target="_top">user-defined functions</a> (UDF) specified by the given command, options, and files, and makes it available for execution. </p>
      <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00019">19</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
    </div>

    <h2 className="groupheader">Constructor & Destructor Documentation</h2>
    <h2 className="memtitle"><span className="permalink"><a href="#a7ca18f2159c7956f2043d13368e8f234">◆ </a></span>CreateProcRequest() <span className="overload">\[1/2]</span></h2>

    <div className="memitem">
      <div className="memproto">
        <table className="mlabels">
          <tr>
            <td className="mlabels-left">
              <table className="memname">
                <tr>
                  <td className="memname">gpudb::CreateProcRequest::CreateProcRequest </td>
                  <td>(</td>

                  <td className="paramname">
                    <span className="paramname">
                      <span className="em" />
                    </span>
                  </td>

                  <td>)</td>

                  <td />
                </tr>
              </table>
            </td>

            <td className="mlabels-right"> <span className="mlabels"><span className="mlabel inline">inline</span></span> </td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1CreateProcRequest" title="A set of parameters for GPUdb::createProc.">CreateProcRequest</a> object with default parameters. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00024">24</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a0b1edea3f78facd742d99f2cdc78d604">◆ </a></span>CreateProcRequest() <span className="overload">\[2/2]</span></h2>

    <div className="memitem">
      <div className="memproto">
        <table className="mlabels">
          <tr>
            <td className="mlabels-left">
              <table className="memname">
                <tr>
                  <td className="memname">gpudb::CreateProcRequest::CreateProcRequest </td>
                  <td>(</td>
                  <td className="paramtype">const std::string &</td>
                  <td className="paramname"><span className="paramname"><span className="em">procName\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::string &</td>
                  <td className="paramname"><span className="paramname"><span className="em">executionMode\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::map\< std::string, std::vector\< uint8\_t > > &</td>
                  <td className="paramname"><span className="paramname"><span className="em">files\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::string &</td>
                  <td className="paramname"><span className="paramname"><span className="em">command\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::vector\< std::string > &</td>
                  <td className="paramname"><span className="paramname"><span className="em">args\_</span></span>, </td>
                </tr>

                <tr>
                  <td className="paramkey" />

                  <td />

                  <td className="paramtype">const std::map\< std::string, std::string > &</td>
                  <td className="paramname"><span className="paramname"><span className="em">options\_</span></span> )</td>
                </tr>
              </table>
            </td>

            <td className="mlabels-right"> <span className="mlabels"><span className="mlabel inline">inline</span></span> </td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Constructs a <a className="el" href="/content/api/cpp/structgpudb_1_1CreateProcRequest" title="A set of parameters for GPUdb::createProc.">CreateProcRequest</a> object with the specified parameters. </p>

        <div className="dl params">
          <div className="dt">Parameters</div>

          <div className="dd">
            <table className="params">
              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">procName\_</td>
                <td>Name of the proc to be created. Must not be the name of a currently existing proc. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">executionMode\_</td>

                <td>
                  The execution mode of the proc. Supported values:

                  <ul>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a5dd108a5fd72513cb0dd2a6f7f18f5f7">create\_proc\_distributed</a>: Input table data will be divided into data segments that are distributed across all nodes in the cluster, and the proc command will be invoked once per data segment in parallel. Output table data from each invocation will be saved to the same node as the corresponding input data. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a188933cd80dde132f4ee0bb4778f6104">create\_proc\_nondistributed</a>: The proc command will be invoked only once per execution, and will not have direct access to any tables named as input or output table parameters in the call to <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#aec2cf18c6185bf22d4fa351019b9924e">GPUdb::executeProc</a>. It will, however, be able to access the database using native API calls. </li>
                  </ul>

                  The default value is <a className="el" href="/content/api/cpp/namespacegpudb#a5dd108a5fd72513cb0dd2a6f7f18f5f7">create\_proc\_distributed</a>.
                </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">files\_</td>
                <td>A map of the files that make up the proc. The keys of the map are file names, and the values are the binary contents of the files. The file names may include subdirectory names (e.g. 'subdir/file') but must not resolve to a directory above the root for the proc. Files may be loaded from existing files in KiFS. Those file names should be prefixed with the uri kifs\:// and the values in the map should be empty. The default value is an empty map. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">command\_</td>
                <td>The command (excluding arguments) that will be invoked when the proc is executed. It will be invoked from the directory containing the proc <span className="em arg">files\_</span> and may be any command that can be resolved from that directory. It need not refer to a file actually in that directory; for example, it could be 'java' if the proc is a Java application; however, any necessary external programs must be preinstalled on every database node. If the command refers to a file in that directory, it must be preceded with './' as per Linux convention. If not specified, and exactly one file is provided in <span className="em arg">files\_</span>, that file will be invoked. The default value is ''. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">args\_</td>
                <td>An array of command-line arguments that will be passed to <span className="em arg">command\_</span> when the proc is executed. The default value is an empty vector. </td>
              </tr>

              <tr>
                <td className="paramdir">\[in]</td>
                <td className="paramname">options\_</td>

                <td>
                  Optional parameters.

                  <ul>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#ace370a61742e4767311a89a0373320a3">create\_proc\_max\_concurrency\_per\_node</a>: The maximum number of concurrent instances of the proc that will be executed per node. 0 allows unlimited concurrency. The default value is '0'. </li>
                    <li> <a className="el" href="/content/api/cpp/namespacegpudb#a9d2030eee6e2495ea4984266f6778992">create\_proc\_set\_environment</a>: A python environment to use when executing the proc. Must be an existing environment, else an error will be returned. The default value is ''. </li>
                  </ul>

                  The default value is an empty map.
                </td>
              </tr>
            </table>
          </div>
        </div>

        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00116">116</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="groupheader">Member Data Documentation</h2>
    <h2 className="memtitle"><span className="permalink"><a href="#a0cad704e8fd3664bf18ec0ff3fe67b5c">◆ </a></span>args</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::vector\<std::string> gpudb::CreateProcRequest::args</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>An array of command-line arguments that will be passed to <a className="el" href="#aa0c2a1ff9bf1f6e3568d5a5e727a0eba">command</a> when the proc is executed. </p>
        <p>The default value is an empty vector. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00188">188</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#aa0c2a1ff9bf1f6e3568d5a5e727a0eba">◆ </a></span>command</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::string gpudb::CreateProcRequest::command</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>The command (excluding arguments) that will be invoked when the proc is executed. </p>
        <p>It will be invoked from the directory containing the proc <a className="el" href="#a579671c50c7f210da3dc829e63dc07c6">files</a> and may be any command that can be resolved from that directory. It need not refer to a file actually in that directory; for example, it could be 'java' if the proc is a Java application; however, any necessary external programs must be preinstalled on every database node. If the command refers to a file in that directory, it must be preceded with './' as per Linux convention. If not specified, and exactly one file is provided in <a className="el" href="#a579671c50c7f210da3dc829e63dc07c6">files</a>, that file will be invoked. The default value is ''. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00181">181</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a7624608317d319bcf276e0a8111ee995">◆ </a></span>executionMode</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::string gpudb::CreateProcRequest::executionMode</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>The execution mode of the proc. </p>
        <p>Supported values: </p>

        <ul>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a5dd108a5fd72513cb0dd2a6f7f18f5f7">create\_proc\_distributed</a>: Input table data will be divided into data segments that are distributed across all nodes in the cluster, and the proc command will be invoked once per data segment in parallel. Output table data from each invocation will be saved to the same node as the corresponding input data. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a188933cd80dde132f4ee0bb4778f6104">create\_proc\_nondistributed</a>: The proc command will be invoked only once per execution, and will not have direct access to any tables named as input or output table parameters in the call to <a className="el" href="/content/api/cpp/classgpudb_1_1GPUdb#aec2cf18c6185bf22d4fa351019b9924e">GPUdb::executeProc</a>. It will, however, be able to access the database using native API calls. </li>
        </ul>

        <p>The default value is <a className="el" href="/content/api/cpp/namespacegpudb#a5dd108a5fd72513cb0dd2a6f7f18f5f7">create\_proc\_distributed</a>. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00155">155</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a579671c50c7f210da3dc829e63dc07c6">◆ </a></span>files</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::map\<std::string, std::vector\<uint8\_t> > gpudb::CreateProcRequest::files</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>A map of the files that make up the proc. </p>
        <p>The keys of the map are file names, and the values are the binary contents of the files. The file names may include subdirectory names (e.g. 'subdir/file') but must not resolve to a directory above the root for the proc.</p>
        <p>Files may be loaded from existing files in KiFS. Those file names should be prefixed with the uri kifs\:// and the values in the map should be empty. The default value is an empty map. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00167">167</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#afe992abaab0d7de82dd7bd261c69415a">◆ </a></span>options</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::map\<std::string, std::string> gpudb::CreateProcRequest::options</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Optional parameters. </p>

        <ul>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#ace370a61742e4767311a89a0373320a3">create\_proc\_max\_concurrency\_per\_node</a>: The maximum number of concurrent instances of the proc that will be executed per node. 0 allows unlimited concurrency. The default value is '0'. </li>
          <li> <a className="el" href="/content/api/cpp/namespacegpudb#a9d2030eee6e2495ea4984266f6778992">create\_proc\_set\_environment</a>: A python environment to use when executing the proc. Must be an existing environment, else an error will be returned. The default value is ''. </li>
        </ul>

        <p>The default value is an empty map. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00205">205</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <h2 className="memtitle"><span className="permalink"><a href="#a437022c5e0005607d12b2a516b638f5c">◆ </a></span>procName</h2>

    <div className="memitem">
      <div className="memproto">
        <table className="memname">
          <tr>
            <td className="memname">std::string gpudb::CreateProcRequest::procName</td>
          </tr>
        </table>
      </div>

      <div className="memdoc">
        <p>Name of the proc to be created. </p>
        <p>Must not be the name of a currently existing proc. </p>
        <p className="definition">Definition at line <a className="el" href="/content/api/cpp/create__proc_8h_source#l00130">130</a> of file <a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a>.</p>
      </div>
    </div>

    <hr />

    The documentation for this struct was generated from the following file:

    <ul>
      <li>gpudb/protocol/<a className="el" href="/content/api/cpp/create__proc_8h_source">create\_proc.h</a></li>
    </ul>
  </div>
</div>
