tkalkirill commented on code in PR #3209:
URL: https://github.com/apache/ignite-3/pull/3209#discussion_r1489433293
##########
modules/core/src/test/java/org/apache/ignite/internal/thread/IgniteThreadFactoryTest.java:
##########
@@ -46,4 +49,19 @@ void producesCorrectThreadNames() throws Exception {
assertThat(threadName1Ref.get(), is("%nodeName%poolName-0"));
assertThat(threadName2Ref.get(), is("%nodeName%poolName-1"));
}
+
+ @Test
+ void producesRequestedAllowedOperations() throws Exception {
+ ThreadFactory threadFactory = IgniteThreadFactory.create("nodeName",
"poolName", LOG, STORAGE_WRITE);
+
+ AtomicReference<Set<ThreadOperation>> allowedOperationsRef = new
AtomicReference<>();
+
+ Thread thread = threadFactory.newThread(() -> {
+ allowedOperationsRef.set(((ThreadAttributes)
Thread.currentThread()).allowedOperations());
+ });
+ thread.start();
+ thread.join();
Review Comment:
Maybe join with timeout
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]