Add null check to hibernate decorator
MODIFY
dd-java-agent/instrumentation/hibernate/src/main/java/datadog/trace/instrumentation/hibernate/HibernateDecorator.java
dd-java-agent/instrumentation/hibernate/src/main/java/datadog/trace/instrumentation/hibernate/HibernateDecorator.java
@@ -47,6 +47,9 @@ public class HibernateDecorator extends OrmClientDecorator {
@Override
public String entityName(final Object entity) {
+ if (entity == null) {
+ return null;
+ }
String name = null;
final Set<String> annotations = new HashSet<>();
for (final Annotation annotation : entity.getClass().getDeclaredAnnotations()) {

Add null check to hibernate decorator