Skip to content

Commit

Permalink
Append details about the default script.max_compilations_per_minute (
Browse files Browse the repository at this point in the history
  • Loading branch information
sandyandi authored and dakrone committed Feb 15, 2017
1 parent bd6fd12 commit 16ec7af
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion docs/reference/migration/migrate_5_0/scripting.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -389,4 +389,17 @@ The following helper methods have been removed from GeoPoint scripting:

Instead use `arcDistance`, `arcDistanceWithDefault`, `planeDistance`, `planeDistanceWithDefault`, `geohashDistance`,
`geohashDistanceWithDefault` and convert from default units (meters) to desired units using the appropriate constance
(e.g., multiply by `0.001` to convert to Km).
(e.g., multiply by `0.001` to convert to Km).

==== Only 15 unique scripts can be compiled per minute by default

If you compile too many unique scripts within a small amount of time,
Elasticsearch will reject the new dynamic scripts with a
`circuit_breaking_exception` error. By default, up to 15 inline scripts per
minute will be compiled. You can change this setting dynamically by setting
`script.max_compilations_per_minute`.

You should watch out for this if you are hard-coding values into your scripts.

Elasticsearch recommends the usage of parameters for efficient script handling.
See details <<prefer-params,here>>.

0 comments on commit 16ec7af

Please sign in to comment.