equal
deleted
inserted
replaced
|
1 package jdk.jfr.api.consumer.streaming; |
|
2 |
|
3 import jdk.jfr.consumer.EventStream; |
|
4 |
|
5 /** |
|
6 * @test |
|
7 * @summary Verifies that is possible to open a stream when a repository doesn't |
|
8 * exists |
|
9 * @key jfr |
|
10 * @requires vm.hasJFR |
|
11 * @library /test/lib |
|
12 * @run main/othervm jdk.jfr.api.consumer.streaming.TestUnstarted |
|
13 */ |
|
14 public class TestUnstarted { |
|
15 public static void main(String... args) throws Exception { |
|
16 try (EventStream es = EventStream.openRepository()) { |
|
17 es.onEvent(e -> { |
|
18 // ignore |
|
19 }); |
|
20 es.startAsync(); |
|
21 } |
|
22 } |
|
23 } |