start-transform.asciidoc 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. [role="xpack"]
  2. [testenv="basic"]
  3. [[start-transform]]
  4. === Start {transform} API
  5. [subs="attributes"]
  6. ++++
  7. <titleabbrev>Start {transform}</titleabbrev>
  8. ++++
  9. Starts one or more {transforms}.
  10. beta[]
  11. [[start-transform-request]]
  12. ==== {api-request-title}
  13. `POST _transform/<transform_id>/_start`
  14. [[start-transform-prereqs]]
  15. ==== {api-prereq-title}
  16. * If the {es} {security-features} are enabled, you must have `manage_transform`
  17. cluster privileges to use this API. You must also have `view_index_metadata`
  18. privileges on the source index for the {transform}. For more information, see
  19. <<security-privileges>> and <<built-in-roles>>.
  20. [[start-transform-desc]]
  21. ==== {api-description-title}
  22. When you start a {transform}, it creates the destination index if it
  23. does not already exist. The `number_of_shards` is set to `1` and the
  24. `auto_expand_replicas` is set to `0-1`.
  25. The {transform} deduces the mapping definitions from the source indices. For
  26. scripted fields, it uses <<dynamic-mapping,dynamic mappings>>. If a field in the
  27. destination index is created by `scripted_metric` or `bucket_script`
  28. aggregations, the {transform} uses dynamic mappings unless a template exists or
  29. the destination index already exists. Mapping definitions in the destination
  30. index take precedence over dynamic mappings and templates.
  31. When the {transform} starts, a series of validations occur to ensure
  32. its success. If you deferred validation when you created the
  33. {transform}, they occur when you start the {transform}--with the
  34. exception of privilege checks. When {es} {security-features} are enabled, the
  35. {transform} remembers which roles the user that created it had at the
  36. time of creation and uses those same roles. If those roles do not have the
  37. required privileges on the source and destination indices, the
  38. {transform} fails when it attempts unauthorized operations.
  39. [[start-transform-path-parms]]
  40. ==== {api-path-parms-title}
  41. `<transform_id>`::
  42. (Required, string)
  43. include::{docdir}/rest-api/common-parms.asciidoc[tag=transform-id]
  44. [[start-transform-example]]
  45. ==== {api-examples-title}
  46. [source,console]
  47. --------------------------------------------------
  48. POST _transform/ecommerce_transform/_start
  49. --------------------------------------------------
  50. // TEST[skip:set up kibana samples]
  51. When the {transform} starts, you receive the following results:
  52. [source,console-result]
  53. ----
  54. {
  55. "acknowledged" : true
  56. }
  57. ----