start-transform.asciidoc 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. [role="xpack"]
  2. [[start-transform]]
  3. = Start {transform} API
  4. [subs="attributes"]
  5. ++++
  6. <titleabbrev>Start {transform}</titleabbrev>
  7. ++++
  8. Starts a {transform}.
  9. [[start-transform-request]]
  10. == {api-request-title}
  11. `POST _transform/<transform_id>/_start`
  12. [[start-transform-prereqs]]
  13. == {api-prereq-title}
  14. Requires the following privileges:
  15. * cluster: `manage_transform` (the `transform_admin` built-in role grants this
  16. privilege)
  17. * source indices: `read`, `view_index_metadata`.
  18. [[start-transform-desc]]
  19. == {api-description-title}
  20. When you start a {transform}, it creates the destination index if it does not
  21. already exist. The `number_of_shards` is set to `1` and the
  22. `auto_expand_replicas` is set to `0-1`.
  23. If it is a pivot {transform}, it deduces the mapping definitions for the
  24. destination index from the source indices and the transform aggregations. If
  25. fields in the destination index are derived from scripts (as in the case of
  26. `scripted_metric` or `bucket_script` aggregations), the {transform} uses
  27. <<dynamic-mapping,dynamic mappings>> unless an index template exists.
  28. If it is a latest {transform}, it does not deduce mapping definitions; it uses
  29. dynamic mappings.
  30. TIP: To use explicit mappings, create the destination index before you start the
  31. {transform}. Alternatively, you can create an index template, though it does not
  32. affect the deduced mappings in a pivot {transform}.
  33. When the {transform} starts, a series of validations occur to ensure
  34. its success. If you deferred validation when you created the
  35. {transform}, they occur when you start the {transform}--with the
  36. exception of privilege checks. When {es} {security-features} are enabled, the
  37. {transform} remembers which roles the user that created it had at the
  38. time of creation and uses those same roles. If those roles do not have the
  39. required privileges on the source and destination indices, the
  40. {transform} fails when it attempts unauthorized operations.
  41. [[start-transform-path-parms]]
  42. == {api-path-parms-title}
  43. `<transform_id>`::
  44. (Required, string)
  45. Identifier for the {transform}.
  46. [[start-transform-query-parms]]
  47. == {api-query-parms-title}
  48. `timeout`::
  49. (Optional, time)
  50. Period to wait for a response. If no response is received before the timeout
  51. expires, the request fails and returns an error. Defaults to `30s`.
  52. [[start-transform-example]]
  53. == {api-examples-title}
  54. [source,console]
  55. --------------------------------------------------
  56. POST _transform/ecommerce_transform/_start
  57. --------------------------------------------------
  58. // TEST[skip:set up kibana samples]
  59. When the {transform} starts, you receive the following results:
  60. [source,console-result]
  61. ----
  62. {
  63. "acknowledged" : true
  64. }
  65. ----