Skip to content

Instantly share code, notes, and snippets.

@Renkai
Last active August 21, 2019 06:20
Show Gist options
  • Save Renkai/a6f0e9c0a43f8137a59996097411bb4d to your computer and use it in GitHub Desktop.
Save Renkai/a6f0e9c0a43f8137a59996097411bb4d to your computer and use it in GitHub Desktop.
give a execution fixed thread execution context
val pool = Executors.newFixedThreadPool(16)
implicit val ec = ExecutionContext.fromExecutor(pool)
pool.shutdown()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment