<commit_before>//
// Copyright (c) 2016-2018 Contributors to the Eclipse Foundation
//
// See the NOTICE file(s) distributed with this work for additional
// information regarding copyright ownership.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// SPDX-License-Identifier: Apache-2.0
//

=== Major changes to previous versions

Changes marked with icon:bolt[role="red"] are breaking changes relative to previous versions of the spec.

* Changes in 2.0
** icon:bolt[role="red"] Refactoring of Counters, as the old `@Counted` was misleading in practice.
*** Counters via `@Counted` are now always monotonic, the `monotonic` attribute is gone.
The `Counted` interface lost the `dec()` methods.
*** Former non-monotonic counters are now <<ConcurrentGaugeDef,`@ConcurrentGauge`>> and also in the output reported as gauges.
*** See <<migration-hint-to-20, Migration hints>> about migration of applications using MicroProfile Metrics.
** Removed unnecessary `@InterceptorBinding` annotation from `org.eclipse.microprofile.metrics.annotation.Metric`.
** icon:bolt[role="red"] Removed deprecated `org.eclipse.microprofile.metrics.MetricRegistry.register(String name, Metric, Metadata)`
** icon:bolt[role="red"]  `Metadata` is now immutable and built via a <<pgm-metadata,`MetadataBuilder`>>.
** Introduced a Tag object which represents a singular tag key/value pair.
** icon:bolt[role="red"] Metrics are now uniquely identified by a <<metricid-data-def,MetricID>> (combination of the metric's name and tags).
** MetricFilter modified to filter with MetricID instead of name
** The 'Metadata' is mapped to a unique metric name in the `MetricRegistry` and this relationship is immutable.
** Tag key names for labels are restricted to match the regex `[a-zA-Z_][a-zA-Z0-9_]*`.
** Tag values defined through MP_METRICS_TAGS must escape equal signs `=` and commas `,` with a backslash `\`.
** icon:bolt[role="red"] <<json-format-def,JSON output format>> for GET requests now appends tags along with the metric in `metricName;tag=value;tag=value` format.
JSON format for OPTIONS requests have been modified such that the 'tags' attribute is a list of nested lists which holds tags from different metrics that
 are associated with the metadata.
** Openmetrics format - formerly called Prometheus format
*** Reserved characters in OpenMetrics format must be escaped.
*** icon:bolt[role="red"] In OpenMetrics output format, the separator between scope and metric name is now a `_` instead of a `:`.
*** icon:bolt[role="red"] Metric names with camelCase are no longer converted to snake_case for OpenMetrics output.
*** icon:bolt[role="red"] The default value of the `reusable` attribute for metric objects created programmatically (not via annotations) is now `true`


* Changes in 1.1
** Improved TCK
** `org.eclipse.microprofile.metrics.MetricRegistry.register(String name, Metric, Metadata)` is deprecated.
Use `org.eclipse.microprofile.metrics.MetricRegistry.register(Metadata, Metric)` instead, where `Metadata`
already has a field for the name.
** Global tags are now supplied via the means of MicroProfile Config (the env variable is still valid).
** Annotations and `Metadata` can now have a flag `reusable` that indicates that the metric name can be registered
more than once. Default is `false` as in Metrics 1.0. See <<reusing_of_metrics>>.<commit_msg>Update changelog regarding base metric changes. Fixes #365 (#366)<commit_after>//
// Copyright (c) 2016-2018 Contributors to the Eclipse Foundation
//
// See the NOTICE file(s) distributed with this work for additional
// information regarding copyright ownership.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// SPDX-License-Identifier: Apache-2.0
//

=== Major changes to previous versions

Changes marked with icon:bolt[role="red"] are breaking changes relative to previous versions of the spec.

* Changes in 2.0
** icon:bolt[role="red"] Refactoring of Counters, as the old `@Counted` was misleading in practice.
*** Counters via `@Counted` are now always monotonic, the `monotonic` attribute is gone.
The `Counted` interface lost the `dec()` methods.
*** Former non-monotonic counters are now <<ConcurrentGaugeDef,`@ConcurrentGauge`>> and also in the output reported as gauges.
*** See <<migration-hint-to-20, Migration hints>> about migration of applications using MicroProfile Metrics.
** Removed unnecessary `@InterceptorBinding` annotation from `org.eclipse.microprofile.metrics.annotation.Metric`.
** icon:bolt[role="red"] Removed deprecated `org.eclipse.microprofile.metrics.MetricRegistry.register(String name, Metric, Metadata)`
** icon:bolt[role="red"]  `Metadata` is now immutable and built via a <<pgm-metadata,`MetadataBuilder`>>.
** Introduced a Tag object which represents a singular tag key/value pair.
** icon:bolt[role="red"] Metrics are now uniquely identified by a <<metricid-data-def,MetricID>> (combination of the metric's name and tags).
** MetricFilter modified to filter with MetricID instead of name
** The 'Metadata' is mapped to a unique metric name in the `MetricRegistry` and this relationship is immutable.
** Tag key names for labels are restricted to match the regex `[a-zA-Z_][a-zA-Z0-9_]*`.
** Tag values defined through MP_METRICS_TAGS must escape equal signs `=` and commas `,` with a backslash `\`.
** icon:bolt[role="red"] <<json-format-def,JSON output format>> for GET requests now appends tags along with the metric in `metricName;tag=value;tag=value` format.
JSON format for OPTIONS requests have been modified such that the 'tags' attribute is a list of nested lists which holds tags from different metrics that
 are associated with the metadata.
** Openmetrics format - formerly called Prometheus format
*** Reserved characters in OpenMetrics format must be escaped.
*** icon:bolt[role="red"] In OpenMetrics output format, the separator between scope and metric name is now a `_` instead of a `:`.
*** icon:bolt[role="red"] Metric names with camelCase are no longer converted to snake_case for OpenMetrics output.
*** icon:bolt[role="red"] The default value of the `reusable` attribute for metric objects created programmatically (not via annotations) is now `true`
** icon:bolt[role="red"]  Some base metrics' names have changed because they now use tags to distinguish metrics for multiple JVM objects. For example, 
each existing garbage collector now has its own `gc.count` metric with the name of the garbage collector being in a tag. Names
of some base metrics in the OpenMetrics output are also affected by the removal of conversion from camelCase to snake_case.

* Changes in 1.1
** Improved TCK
** `org.eclipse.microprofile.metrics.MetricRegistry.register(String name, Metric, Metadata)` is deprecated.
Use `org.eclipse.microprofile.metrics.MetricRegistry.register(Metadata, Metric)` instead, where `Metadata`
already has a field for the name.
** Global tags are now supplied via the means of MicroProfile Config (the env variable is still valid).
** Annotations and `Metadata` can now have a flag `reusable` that indicates that the metric name can be registered
more than once. Default is `false` as in Metrics 1.0. See <<reusing_of_metrics>>.
{'fraction_non_alphanumeric': 0.09573297469128256, 'fraction_numerical': 0.006602274116640176, 'mean_word_length': 4.93183466279913, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1994272', 'n_tokens_mistral': 2209, 'n_tokens_neox': 2095, 'n_words': 1004}