# What's an interactive task? Does it pause a running task?

**URL:** https://discourse.julialang.org/t/whats-an-interactive-task-does-it-pause-a-running-task/93532
**Category:** General Usage
**Created:** [January 25, 2023, 7:47pm UTC](https://discourse.julialang.org/t/whats-an-interactive-task-does-it-pause-a-running-task/93532 "2023-01-25T19:47:15Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Ashlin\_Harris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ashlin_harris/32/210166_2.png) [@Ashlin\_Harris](https://discourse.julialang.org/u/Ashlin_Harris)
#### Post date: [January 25, 2023, 7:47pm UTC](https://discourse.julialang.org/t/whats-an-interactive-task-does-it-pause-a-running-task/93532/1 "2023-01-25T19:47:15Z")

</div>

[Julia 1.9 includes interactive tasks](https://docs.julialang.org/en/v1.9-dev/manual/multi-threading/#man-threadpools), but I can’t find an example or a description of what they do. I assume that they designate low latency tasks that should take priority over other tasks. For instance, in the following example, the interactive task (printing) stays asleep while the calculations are performed. Is there any way in Julia to pause a task that is running so that something can be printed?

```julia
julia> VERSION
v"1.9.0-beta3"

julia> using Base.Threads

julia> nthreads(:interactive)
1

julia> do_some_printing(T) = (i=0;while i<T print("-");sleep(0.1);i+=1 end);

julia> do_some_work(X) = sum(map(i->BigInt(999)^10_000_000 % i, 1:X));

julia> @spawn :interactive do_some_printing(10); do_some_work(10)

```
