--- a/src/jdk.jfr/share/classes/jdk/jfr/internal/consumer/RecordingInternals.java Fri May 17 15:53:21 2019 +0200
+++ b/src/jdk.jfr/share/classes/jdk/jfr/internal/consumer/RecordingInternals.java Fri May 17 16:02:27 2019 +0200
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -34,6 +34,19 @@
public abstract class RecordingInternals {
+ public static RecordingInternals instance() {
+ if (INSTANCE == null) {
+ // Force initialization
+ try {
+ Class<?> c = RecordedObject.class;
+ Class.forName(c.getName(), true, c.getClassLoader());
+ } catch (ClassNotFoundException e) {
+ new InternalError("shuld not happen");
+ }
+ }
+ return INSTANCE;
+ }
+
public static RecordingInternals INSTANCE;
public abstract boolean isLastEventInChunk(RecordingFile file);
@@ -44,4 +57,5 @@
public abstract void sort(List<RecordedEvent> events);
+ public abstract Parser newStringParser();
}