upgrade-transforms.asciidoc 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. [role="xpack"]
  2. [testenv="basic"]
  3. [[upgrade-transforms]]
  4. = Upgrade {transforms} API
  5. [subs="attributes"]
  6. ++++
  7. <titleabbrev>Upgrade {transforms}</titleabbrev>
  8. ++++
  9. Upgrades all {transforms}.
  10. [[upgrade-transforms-request]]
  11. == {api-request-title}
  12. `POST _transform/_upgrade`
  13. [[upgrade-transforms-prereqs]]
  14. == {api-prereq-title}
  15. Requires the following privileges:
  16. * cluster: `manage_transform` (the `transform_admin` built-in role grants this
  17. privilege)
  18. [[upgrade-transforms-desc]]
  19. == {api-description-title}
  20. {transforms-cap} are compatible across minor versions and between supported
  21. major versions. However, over time, the format of {transform} configuration
  22. information may change. This API identifies {transforms} which have a legacy
  23. configuration format and upgrades them to the latest version; including clean up
  24. of the internal data structures that store {transform} state and checkpoints.
  25. {transform-cap} upgrade does not affect the source and destination indices.
  26. If a {transform} upgrade step fails, the upgrade stops, and an error is returned
  27. about the underlying issue. Resolve the issue then re-run the process again. A
  28. summary is returned when the upgrade is finished.
  29. To ensure {ctransforms} remain running during a major version upgrade of the
  30. cluster – for example, from 7.16 to 8.0 – it is recommended to upgrade
  31. {transforms} before upgrading the cluster. You may want to perform a recent
  32. cluster backup prior to the upgrade.
  33. [IMPORTANT]
  34. ====
  35. * When {es} {security-features} are enabled, your {transform} remembers the
  36. roles of the user who created or updated it last. In contrast to
  37. <<update-transform,update transform>>, a {transform} upgrade does not change the
  38. stored roles, therefore the role used to read source data and write to the
  39. destination index remains unchanged.
  40. ====
  41. [[upgrade-transforms-query-parms]]
  42. == {api-query-parms-title}
  43. `dry_run`::
  44. (Optional, Boolean) When `true`, only checks for updates but does not execute
  45. them. Defaults to `false`.
  46. [[upgrade-transforms-response-body]]
  47. == {api-response-body-title}
  48. `needs_update`::
  49. (integer) The number of {transforms} that need to be upgraded.
  50. `no_action`::
  51. (integer) The number of {transforms} that don't require upgrading.
  52. `updated`::
  53. (integer) The number of {transforms} that have been upgraded.
  54. [[upgrade-transforms-example]]
  55. == {api-examples-title}
  56. To upgrade the legacy {transforms} to the latest configuration format, perform
  57. the following API call:
  58. [source,console]
  59. --------------------------------------------------
  60. POST _transform/_upgrade
  61. --------------------------------------------------
  62. // TEST[setup:simple_kibana_continuous_pivot]
  63. When all {transforms} are upgraded, you receive a summary:
  64. [source,console-result]
  65. ----
  66. {
  67. "needs_update": 0,
  68. "updated": 2,
  69. "no_action": 1
  70. }
  71. ----
  72. // TESTRESPONSE[skip:TBD]