Conversation
a6e29dd to
35556e5
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #201 +/- ##
=======================================
Coverage ? 59.05%
Complexity ? 477
=======================================
Files ? 151
Lines ? 3417
Branches ? 235
=======================================
Hits ? 2018
Misses ? 1229
Partials ? 170 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
KeranYang
left a comment
There was a problem hiding this comment.
Thanks for contributing! @ankiiitraj
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
examples/src/test/java/io/numaproj/numaflow/examples/sink/forkjoin/ConcurrentSinkTest.java
Outdated
Show resolved
Hide resolved
|
updated the tests to better reflect the concurrent implementation. |
| @Slf4j | ||
| public class ConcurrentSink extends Sinker { | ||
|
|
||
| private static final int DEFAULT_THREAD_POOL_SIZE = 10; |
There was a problem hiding this comment.
use number of available cores.
| @Override | ||
| public Thread newThread(Runnable r) { | ||
| Thread t = new Thread(r, "ConcurrentSink-Worker-" + (++counter)); | ||
| t.setDaemon(true); |
There was a problem hiding this comment.
taken care, shouldn't be daemon thread.
| Server server = new Server(concurrentSink); | ||
| server.start(); | ||
| server.awaitTermination(); | ||
| } |
There was a problem hiding this comment.
invoke shutdown after the server terminates?
Signed-off-by: Ankit Raj <ankitatiiitr@gmail.com>
Signed-off-by: Ankit Raj <ankitatiiitr@gmail.com>
Signed-off-by: Ankit Raj <ankitatiiitr@gmail.com>
fa9c78d to
ef37100
Compare
|
I merged the change. Thank you @ankiiitraj ! |
|
Hey @ankiiitraj , I just want to share a good news that here at Intuit, one of our internal Numaflow users is able to refer to your example and successfully support their concurrency use case. Thank you! |
closes #179