Coder Social home page Coder Social logo

contextlogger's Introduction

TracEE Context-Logger

Maven Central Build Status Coverage Status

The TracEE Context-Logger is a java framework for providing contextual information in log files (or other kind of targets - for example by sending the data via HTTP). The contextual information is provided in a human and machine readable format (JSON).

It does the following things:

  • offers handlers for most popular java frameworks that are used to detect errors (uncaught exceptions) automatically and to provide information about the invocation context that lead to the error.
  • offers a fluent API that is helping you to create human and machine readable string representations for any kind of instances. This is very handy if you want to provide complex contextual information in manual log statements.
  • offers a plugin mechanism that allows you to use customized output builders for specific types
  • offers a plugin mechanism to allow writing of contextual information to other kinds of targets than log files (for example: to send invocation context via HTTP to another server)
  • offers predefined and customized profiles to configure the output
  • offers a static output format that eases automatic detection of errors ( no more customer driven bug detection ;) ).
  • integration is very easy with low impact on production code
  • uses slf4j as a log abstraction. Therefore most log frameworks are supported.

At the moment the following Java technologies / frameworks are supported:

  • servlet 2.5+
  • jax-ws
  • jax-rs2
  • cdi / ejb
  • jms
  • AspectJ / Spring-AOP
  • Spring

Motivation

Think about getting a call from a customer who informs you about an error, that has happened in your application. In most cases the only information you get is the name of the user, the time of the error and in which part of the application the error has occurred. All other information must be gathered from the log files of the applications servers or the connected databases. Success and speed of analyzing the error hardly depends on what has been written to the logs. Most of the useful output is provided manually by log statements implemented by the developer or in worst case not even at all. And databases aren't a reliable source of information, because data could have changed since the error has occurred.

That is where the TracEE Context Logger is going to help you. It automatically detects errors and writes the invocation context to the logs. It offers handlers for the most commonly used Java Frameworks (Java EE, Spring and others). For example it is possible to output requests parameters in Servlet container or to output soap request of JAX-WS webservices.

Example

The following output was generated by the tracee-examples applications after an uncaught exception in a JAX-WS service was thrown. The output was written by a JAX-WS service handler and a servlet filter provided by the TracEE Context-Logger.

// JAX-WS SERVICE - BACKEND APPLICATION
13:51:36.929 [http-bio-9080-exec-5] ERROR i.t.c.connector.LogConnector - [08f0d3700af5309b0ee3d140dd740cf4|6P22I7Z28VWEFMBV6U1HH5GITO8PTZ3M] - TRACEE_CL_ERROR[JAX-WS]  : [
  "TYPE:Object[]",
  {
	"TYPE":"jaxWs",
	"soapResponse":"String['<soap:Envelope xmlns:soap=\"http:\/\/schemas.xmlsoap.org\/soap\/envelope\/\"><SOAP-ENV:Header xmlns:SOAP-ENV=\"http:\/\/schemas.xmlsoap.org\/soap\/envelope\/\"\/><soap:Body><soap:Fault><faultcode>soap:Server<\/faultcode><faultstring>JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].<\/faultstring><\/soap:Fault><\/soap:Body><\/soap:Envelope>']",
	"soapRequest":"String['<soap:Envelope xmlns:soap=\"http:\/\/schemas.xmlsoap.org\/soap\/envelope\/\"><SOAP-ENV:Header xmlns:SOAP-ENV=\"http:\/\/schemas.xmlsoap.org\/soap\/envelope\/\"><TPIC xmlns=\"http:\/\/tracee.io\/tpic\/1.0\"><entry key=\"TPIC.invocationId\">6P22I7Z28VWEFMBV6U1HH5GITO8PTZ3M<\/entry><entry key=\"TPIC.sessionId\">08f0d3700af5309b0ee3d140dd740cf4<\/entry><\/TPIC><\/SOAP-ENV:Header><soap:Body><ns2:error xmlns:ns2=\"https:\/\/github.com\/tracee\/tracee\/examples\/jaxws\/service\/wsdl\"><arg0>3121<\/arg0><arg1>0<\/arg1><\/ns2:error><\/soap:Body><\/soap:Envelope>']"
  }
]

// SERVLET BASED FRONTEND APPLICATION
13:51:37.368 [http-bio-9080-exec-3] ERROR i.t.c.connector.LogConnector - [08f0d3700af5309b0ee3d140dd740cf4|6P22I7Z28VWEFMBV6U1HH5GITO8PTZ3M] - TRACEE_CL_ERROR[TraceeErrorLoggingFilter]  : [
  "TYPE:Object[]",
  {
	"TYPE":"servletRequest",
	"http-method":"String['POST']",
	"http-parameters":[
	  "TYPE:ArrayList",
	  {
		"name":"String['j_idt13']",
		"value":"String['j_idt13']"
	  },
	  {
		"name":"String['j_idt13:j_idt23']",
		"value":"String['3121']"
	  },
	  {
		"name":"String['j_idt13:j_idt25']",
		"value":"String[]"
	  },
	  {
		"name":"String['j_idt13:j_idt43']",
		"value":"String['Trigger uncaught Exception']"
	  },
	  {
		"name":"String['javax.faces.ViewState']",
		"value":"String['-7205603806442056524:-6891029251268203353']"
	  }
	],
	"url":"String['http:\/\/localhost:9080\/traceeTestWebapp\/index.jsf']"
  },
  {
	"TYPE":"servletResponse",
	"http-status-code":"Integer['500']"
  },
  {
	"TYPE":"throwable",
	"stacktrace":"String['javax.servlet.ServletException: javax.xml.ws.soap.SOAPFaultException: JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].\r\n\tat javax.faces.webapp.FacesServlet.service(FacesServlet.java:606)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)\r\n\tat org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)\r\n\tat io.tracee.binding.servlet.TraceeFilter.doFilterHttp(TraceeFilter.java:63)\r\n\tat io.tracee.binding.servlet.TraceeFilter.doFilter(TraceeFilter.java:48)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)\r\n\tat io.tracee.contextlogger.contextprovider.servlet.TraceeErrorLoggingFilter.doFilter(TraceeErrorLoggingFilter.java:30)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)\r\n\tat io.tracee.examples.webapp.TraceeExampleFilter.doFilter(TraceeExampleFilter.java:27)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)\r\n\tat org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)\r\n\tat org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)\r\n\tat org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)\r\n\tat org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)\r\n\tat org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501)\r\n\tat org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)\r\n\tat org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)\r\n\tat org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)\r\n\tat org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)\r\n\tat org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)\r\n\tat org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070)\r\n\tat org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)\r\n\tat org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\r\n\tat org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)\r\n\tat java.lang.Thread.run(Thread.java:745)\r\nCaused by: javax.faces.el.EvaluationException: javax.xml.ws.soap.SOAPFaultException: JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].\r\n\tat javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)\r\n\tat com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)\r\n\tat javax.faces.component.UICommand.broadcast(UICommand.java:315)\r\n\tat javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:794)\r\n\tat javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1259)\r\n\tat com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)\r\n\tat com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)\r\n\tat com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)\r\n\tat javax.faces.webapp.FacesServlet.service(FacesServlet.java:593)\r\n\t... 31 more\r\nCaused by: javax.xml.ws.soap.SOAPFaultException: JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].\r\n\tat org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:158)\r\n\tat com.sun.proxy.$Proxy224.error(Unknown Source)\r\n\tat io.tracee.examples.webapp.TestWebappController.triggerJaxWsRemoteError(TestWebappController.java:80)\r\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\r\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)\r\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\r\n\tat java.lang.reflect.Method.invoke(Method.java:497)\r\n\tat org.apache.el.parser.AstValue.invoke(AstValue.java:278)\r\n\tat org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:273)\r\n\tat com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:105)\r\n\tat javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)\r\n\t... 39 more\r\nCaused by: org.apache.cxf.binding.soap.SoapFault: JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].\r\n\tat org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.unmarshalFault(Soap11FaultInInterceptor.java:84)\r\n\tat org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:51)\r\n\tat org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessage(Soap11FaultInInterceptor.java:40)\r\n\tat org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:263)\r\n\tat org.apache.cxf.interceptor.AbstractFaultChainInitiatorObserver.onMessage(AbstractFaultChainInitiatorObserver.java:113)\r\n\tat org.apache.cxf.jaxws.handler.soap.SOAPHandlerInterceptor.handleMessage(SOAPHandlerInterceptor.java:140)\r\n\tat org.apache.cxf.jaxws.handler.soap.SOAPHandlerInterceptor.handleMessage(SOAPHandlerInterceptor.java:71)\r\n\tat org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:263)\r\n\tat org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:845)\r\n\tat org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:1705)\r\n\tat org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1538)\r\n\tat org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1445)\r\n\tat org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:56)\r\n\tat org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:660)\r\n\tat org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)\r\n\tat org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:263)\r\n\tat org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:570)\r\n\tat org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:479)\r\n\tat org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:382)\r\n\tat org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:335)\r\n\tat org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96)\r\n\tat org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:136)\r\n\t... 49 more\r\n']",
	"message":"String['javax.xml.ws.soap.SOAPFaultException: JAXWS Tracee Example : Triggered exception with passed parameters '3121' and '0' while invoking public int io.tracee.examples.jaxws.service.TraceeJaxWsTestService.error(int,int) with params [3121, 0].']"
  }
]

The example consists of two log statements generated by the context logger of two related applications (Servlet based frontend and JAX-WS service). The Log statements were aggregated by using the TracEE Framework.

Both statements will help you to analyze the error and to determine if the reason of the error is located in the frontend or the JAX-WS service.

The output can be configured easily via predefined or customized profiles.

Integrating TracEE Context-Logger into your application

There are two possibilties on how to use the TracEE Context-Logger:

  • manually driven : by using the fluent API to generate string representations for instances
  • automatically driven : by using handlers and inteceptors provided by the technolgy dependent context provider artifacts

Basically you just have to add the following dependency to your pom.xml to get started

    <dependency>
        <groupId>io.tracee.contextlogger</groupId>
        <artifactId>contextlogger-core</artifactId>
    </dependency>

Additionally - depending on your technolgy stack - you have to add some context provider artifacts. Please take a look at the modules section for further information.

Write log statements manually by using the Fluent API

String representaions of contextual information can be added manually to the logs by using the Fluent API. Building of the string representation is done via reflection. Multiple referenced instances and loops are detected and handled gently.

The TraceeToStringBuilder is very easy to use:

// generates a string representation for passed instance using default profiles
TraceeToStringBuilder.createDefault().toString(instance1,instance2,...);

// Prepares preconfigured TraceeToStringBuilder instance. Note: output will be generated on first toString() method call. Should be used with log frameworks.
TraceeToStringBuilder.createDefault().wrap(instance1,instance2,...);

// overrides default config
TraceeToStringBuilder.create()
	// override output style
	.enforceOutputWriterConfiguration(BasicOutputWriterConfiguration.JSON_INTENDED)  
	// override Tracee context provider profile settings
	.enforceProfile(Profile.FULL)	
	// disabled processing of passed types
	.disableTypes(TypeX.class)
	// closes configuration
	.apply()
	.toString(instance1,instance2,...);

Detect errors and provide log statements automatically by using technology dependent context providers.

Framework Adapter
Servlet Use contextprovider-servlet as a servlet filter.
EJB3/CDI/JMS Use contextprovider-javaee as an interceptor
JAX-RS Use contextprovider-servlet as a servlet filter.
JAX-RS2 TODO
JAX-WS Use contextprovider-jaxws as a message listener.
SPRING-MVC Use contextprovider-springmvc as a handler interceptor.
SPRING-AOP Use [contextprovider-aspectj] (contextprovider/aspectj) by offering an aspect triggered by a simple java annotation
ASPECTJ Use [contextprovider-aspectj] (contextprovider/aspectj) by offering an aspect triggered by a simple java annotation

Automatic detection of errors

Automatic detection of errors in logfiles is a difficult task. A common approach is to search for known errors like NullPointerExceptions, TimeoutExceptions or other error types you have encountered in the past.

The TracEE Context-Logger project is helping you to detect errors easily by using a fix log statement structure:

<LOG STATEMENT HEADER PROVIDED BY LOG FRAMEWORK> TRACEE_CL_ERROR[<SOURCE>]  : <CONTEXUAL DATA> 

The TracEE Context-Logger uses a static log statement prefix. So it's easy to detect all errors just by searching for the log statement prefix string "TRACEE_CL_ERROR" on your log server.

Modules

TracEE context logger is built highly modular. The modules you need depend on your application and the underlying frameworks and containers. The following table describes all available TracEE-contextlogger modules and their usage scenarios.

Module Usage
contextlogger-connectors Provides support for writing contextual data to other target as log files (f.e. send error via Http)
contextlogger-core The core of the context logger
contextlogger-integration-test Does some integration test for custom data providers
contextprovider-javaee Provides support for EJB / CDI /JMS by offering interceptors
contextprovider-jaxws Provides support for JAXWS via Message handlers.
contextprovider-provider-api Provides support for Servlets via ServletFilter
contextprovider-servlet Provides support for Servlets via ServletFilter
contextprovider-aspectj AspectJ / Spring-AOP powered contextual logging
contextprovider-springmvc Spring-MVC powered contextual logging

Configuration

Output Profile Selection

The output produced by the TracEE contextual logger can be configured very flexible by allowing you to choose between predefined and custom profiles or by offering you the possibility to overwrite profile settings by system properties. You can choose between those profiles by setting the io.tracee.contextlogger.profile system property in your application server or by adding a ProfileSelector.properties file to your application. The property file must define the io.tracee.contextlogger.profile property. Possible values are:

Value Description
BASIC Default profile, provides most important and secure contextual information.
ENHANCED Provides additional contextual information not included in basic profile
FULL Outputs almost everything available to the handlers - even security related data, therefore this profile shouldn't be used in production environments

You can combine those configurations in any way you want. The settings will be applied in a specific order. Application server wide profile selection will be overwritten by application based profile selection. If no profile selection is configured, basic profile will be used as default.

TracEE common context information

You can add the following optional system properties to your application server configuration to configure the common context information:

Property name Description Default
io.tracee.contextlogger.tracee-standard-stage Defines the stage of the system - for example DEV, INT, TEST,... won't be used if not set explicitly
io.tracee.contextlogger.tracee-standard-system Defines the name of the system system name will be determined automatically by calling InetAddress.getLocalHost().getHostName()

contextlogger's People

Contributors

danielwegener avatar tobiasstamann avatar svenbunge avatar srsp avatar

Stargazers

Charlee Chitsuk avatar  avatar

Watchers

James Cloos avatar Charlee Chitsuk avatar  avatar  avatar  avatar  avatar

Forkers

tobiasstamann

contextlogger's Issues

Handle primitive type arrays correctly

Using the context logger with primitive arrays like float[], char[], byte[] currently triggers a ClassCastException:

Exception in thread "main" java.lang.ClassCastException: [F cannot be cast to [Ljava.lang.Object;
at io.tracee.contextlogger.outputgenerator.RecursiveOutputElementTreeBuilderImpl.convertInstanceRecursively(RecursiveOutputElementTreeBuilderImpl.java:93)
at io.tracee.contextlogger.outputgenerator.RootOutputElementTreeBuilder.buildOutputElementTreeMain(RootOutputElementTreeBuilder.java:35)
at io.tracee.contextlogger.outputgenerator.RootOutputElementTreeBuilder.buildOutputElementTree(RootOutputElementTreeBuilder.java:69)
at io.tracee.contextlogger.outputgenerator.TraceeContextStringRepresentationBuilderImpl.createStringRepresentation(TraceeContextStringRepresentationBuilderImpl.java:18)
at io.tracee.contextlogger.TraceeContextLogger.provideOutput(TraceeContextLogger.java:92)
at io.tracee.contextlogger.connector.LogConnector.sendErrorReport(LogConnector.java:40)
at io.tracee.contextlogger.ConnectorFactory.sendErrorReportToConnectors(ConnectorFactory.java:82)
at io.tracee.contextlogger.TraceeContextLogger.logWithPrefixedMessage(TraceeContextLogger.java:67)
at io.tracee.contextlogger.TraceeContextLogger.log(TraceeContextLogger.java:58)

Refactor adding of Implicit context providers to output

It should be possible to add implicit context providers to string representation builder output by using enum values.

This could be achieved by offering an interface which must be implemented by those enums used for mapping.

Stacktrace Simplifyer

The contextprovider for Throwables should offer the possibility to simplify output.

Basically only the following entries of the stacktrace might be relevant:

  • initial stack entries
  • last stack entries
  • own code (determined by package name)
  • foreign code that calls own code
  • foreign code called by own code

Foreign code (like 3rd Party Frameworks or Container) is mostly irrelevant for anylyzing the stacktrace.

Add Property to configure package names that should be handled as own code and switch for deactivating simplifyer

Alter object id output behavior for Java base types (Strings, atomic and boxing types)

The contextlogger adds the object id to the output for strings and other Java base types, if it detects that the corresponding OutputElement in the Output Element tree is referenced multiple times:

String@426726579['dsdadsa']

This behavior reduces the readability and bloats the output of Java base type output.

String handling should be done according to its length.
For example show object id at the first output of the String for Strings longer than 50 chars.
Just output the reference at all other references.

Add trimming for long strings.

Refactoring project structure and package naming

At the moment almost all modules are build from project root.
So the purpose of the modules is not clear.

That's why we should use a directory structure like

/
/connector
/connector/api
/connector/http-connector
/core
/contextprovider
/contextprovider/api
/contextprovider/servlet
/contextprovider/...
/testhelper
/...

We should also apply that structure to our maven artifact and group ids:
Group Ids
io.tracee.contextlogger
io.tracee.contextlogger.contextprovider
io.tracee.contextlogger.connector

Artifact Ids
contextlogger-...
contextprovider-...
connector-...
the contextprovider/watchdog module should be renamed to contextprovider/aspectj

Additionally we should use unique base package names for all modules to prevent conflicts...

Refactoring of Log Message Creation

The tracEE context logger supports different connectors to send context information to log or external systems. At the moment all connectors will send the same context-information, because the contextual information is passed to them as a String.

But not all informations are relevant for all conector types. For example the Common Context infomation containing date, system, ... are worthless for log output, because all information are defined implicit.

Therefore the Connector interface should be altered that the sendErrorReport method uses an output builder instance as a parameter.

Update documentation

Configuration of profiles has changed and needs to be altered

Additionally the bindings are now done via SPI.

Should add section for providing a custom context providers or bindings.
Should describe the Annotation Processor in this context.

Minimize dependencies to Tracee core

The Tracee artifcats shouldn't import or inherit tracee core classes.

There are only a few exceptions allowed:
Tracee
TraceeBackend
TraceeLogger
TraceeLoggerFactory

TraceeException in tests
NoopTraceeLoggerFactory in tests

This maximizes compatibilty between various Tracee core and contextlogger versions.

For example:
AbstractTraceeErrorLoggingHandler class must be refactored.

Remove external Dependencies

Building of context information is based on a mix of ReflectionToStringBuilder and Gson.
This is suboptimal, because the produced output doesn't look very nice and is not parseable.

Move contextproviders from impl to their related contextlogger artifacts

At the moment all contextproviders reside in the impl project. Therefore all related frameworks are bound as provided dependencies.

We will be able to remove those dependencies, if we move the contextprovider classes to their related binding artifacts

All contextproviders are initialized via reflection. Therefore we still need to keep all context provider types inside the
io.tracee.contextlogger.internal.wrappercontextproviders
io.tracee.contextlogger.internal.implicitcontextproviders
files.

We need to check the stability of the framework in case of an context provider type cannot be found.

We should add an itest to check the correctness of those full qualified class names.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.