2 * Copyright © 2016-2018 European Support Limited
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 * <p>Client-visible API for logging, implemented according to
19 * <a href="https://wiki.onap.org/download/attachments/1015849/ONAP%20application%20logging%20guidelines.pdf?api=v2">
20 * ONAP application logging guidelines</a>. The actual implementation is delegated to a service provider bound through
21 * the <a href="https://docs.oracle.com/javase/tutorial/ext/basics/spi.html">Java SPI</a> mechanism. The provider must
22 * implement {@link org.openecomp.sdc.logging.spi.LoggingServiceProvider}.</p>
23 * <p>The logging API collects the following types of data:</p>
25 * <li>Context that must be propagated throughout the application, and available at any point for debug and error
27 * <li>Audit data, reflecting the invocation of a local, usually REST, API.</li>
28 * <li>Metrics data, reflecting the invocation of a remote API by current system (component).</li>
30 * <p>The construction of all three types of data follows the same pattern for consistency. The builder pattern has
31 * been chosen over an interface to enable to gracefully add new fields without affecting the client code. Also, the
32 * builder can be implemented differently if needed, also without affecting client code. For instance, it may delegate
33 * the instantiation and population of a data object to the service provider.</p>
38 package org.openecomp.sdc.logging.api;