Wednesday, January 4, 2017

Promise in java

Asynchronous programming becomes popular in java world. But if you come from Javascript world, you wonder whether java has such as facility like Promise. Yes, it does. Moreover, it is more powerful than Promise. Why? Java is a multi-threaded programming language. A promise can be executed in another thread concurrently or by a thread pool.  On the other hand, javascript is single-threaded language. All promises are executed in the main event thread.
Here is Java Promise API comparison with javascript Promise API.

1 comment:

  1. i know this world is technologies world. thanks for sharing tips. java is using one of the platform ios application developers company oman thanks for sharing your ideas.