Тёмный

Kotlin Coroutine Cancellation: Cooperative cancellation, Handle Exceptions, and Timeouts 

Smartherd
Подписаться 136 тыс.
Просмотров 21 тыс.
50% 1

Опубликовано:

 

15 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 35   
@SriyankSiddhartha
@SriyankSiddhartha 4 года назад
00:00 Welcome 00:22 Prerequisites 01:00 Cooperative Coroutine Cancellation 10:00 yield function 11:45 isActive flag 16:18 Handling CancellationException 18:59 withContext 20:49 Exception with message 22:12 Timeouts 27:12 Summary 28:30 What's Next?
@sumit180288
@sumit180288 3 года назад
You are better than the courses offered on Udemy. Keep going and give us awesome videos!! Can you please make a series on MVVM and Jetpack compose !!
@RahulVerma-fz2jf
@RahulVerma-fz2jf 3 года назад
Keep up the good work. Learnt a lot from your 4videos on coroutines. Will fill the gaps (if any) with the kotlin docs.
@smartherd
@smartherd 3 года назад
Great to hear!
@Syed-wj4pj
@Syed-wj4pj 2 года назад
​@@smartherd nice job, your channel has the most simple and lucid explanations for the most complex concepts. Keep working.. You're gonna be very successfull one day
@sagarghare9829
@sagarghare9829 4 года назад
Done this video Thanks for very clean and easy explanation.
@wizardy6267
@wizardy6267 2 года назад
Nice tutorials, thanks. 24:55 I am using kotlin 1.6.21 and coroutines-core library 1.6.1 by some reasons. The try-catch block needs to surround the builder `withTImeout` to catch the TimeoutCancellationException.
@kingmenagent215
@kingmenagent215 2 года назад
Looks like you are best , Thank you
@behappyandsmile1486
@behappyandsmile1486 3 года назад
Why at video timing 11:24 of yield() demo job.cancelAndJoin() after delay(10), coroutine didn't through the exception ?
@hardcodeandroid
@hardcodeandroid 4 года назад
Sir, I am beginner and I am following all your tutorials, I want to learn Android development too soon so please advice
@ChrisAthanas
@ChrisAthanas 3 года назад
Start small and don’t give up, it will take at least a year of daily study to be proficient. Andriod is constantly changing so you will need to continue studying to keep up, and specialize in a narrow area to be valuable on a large team. For small team development, you need to have good general knowledge of all Jetpack architecture components
@hardcodeandroid
@hardcodeandroid 3 года назад
@@ChrisAthanas thanks you sir
@jumajuma9311
@jumajuma9311 4 года назад
You're back
@smartherd
@smartherd 4 года назад
Indeed, to put things on 🔥
@David-tj9rq
@David-tj9rq 3 года назад
Really amazing
@sumit180288
@sumit180288 3 года назад
is withTimeout and withTimeoutorNull blocking ?
@sumitkushwaha3731
@sumitkushwaha3731 3 года назад
Sir, here in launch you said that it will run on some background thread but in previous video you taught us that launch inherits the scope from immediate parent which is main( ) in this case. So why here it is running on some background thread? Kindly help.
@virujthakur9260
@virujthakur9260 2 года назад
Did you find the answer yet?
@bumble_bee_09
@bumble_bee_09 2 года назад
@@virujthakur9260 It runs on main thread only in this example, because coroutineContext is inherited from runBlocking which is running on main
@bumble_bee_09
@bumble_bee_09 2 года назад
It runs on main thread only in this example, because coroutineContext is inherited from runBlocking which is running on main
@latikakapoor6371
@latikakapoor6371 2 года назад
Hey ...I want to load bitmap in coroutines How can I do that ?? Can I send you the code ?
@tarunasharma4477
@tarunasharma4477 3 года назад
thnk u
@amitmondal7427
@amitmondal7427 4 года назад
Felling good. :)
@RaviKumar-do1ng
@RaviKumar-do1ng 3 года назад
Did that hurt?
@RahulRawat-rj8ol
@RahulRawat-rj8ol 2 года назад
sir one project on mvvm design pattern please
@venkatesh4307
@venkatesh4307 4 года назад
Sir , Can you suggest me on jetpack compose. How can I prepare for it.
@TheAbhidugar
@TheAbhidugar 3 года назад
You can watch channel called Phillipp Lackner for that. But I would suggest not to go into compose as of now.
@muhmmedalsadig7706
@muhmmedalsadig7706 3 года назад
@@TheAbhidugar why you suggested him to not go into compose as now?
@TheAbhidugar
@TheAbhidugar 3 года назад
@@muhmmedalsadig7706 it was not stable then, just used for experimenting. But now it is production ready.
@karanchaudhry8277
@karanchaudhry8277 4 года назад
sir please koi naya bada or badiya sa kotlin mein app ka tutorial banao na...pls
@David-tj9rq
@David-tj9rq 3 года назад
without runblocking launch is not working why ? Even launch creadtes a coroutine scope then why
@GiridharaSaiPavanKumarGurram
@GiridharaSaiPavanKumarGurram 3 года назад
use lifecyclescope or viewmodel scope
@mikec4220
@mikec4220 3 года назад
It needs a scope in order to be launched. Probably will be mentioned in later videos.
@alexanderk9767
@alexanderk9767 3 года назад
ANDROID G0D
@ojamsivasaikumarreddy7884
@ojamsivasaikumarreddy7884 2 года назад
Hey @Smartherd , if we launch coroutines using " CoroutineScope.launch(Dispatchers.IO){} " , do coroutines end or get destroyed after their execution by default or do we need to explicitly end the coroutines in Kotlin ?
Далее
Куда пропали ЗДРАЙВЕРЫ?
11:38
Просмотров 599 тыс.
Let, Also, Apply, Run, With - Kotlin Scope Functions
11:44
How to avoid 5 common Kotlin Coroutine mistakes
15:59
Просмотров 4,8 тыс.
5 Fatal Coroutine Mistakes Nobody Tells You About
18:15
The Flaws of Inheritance
10:01
Просмотров 940 тыс.
Understand Kotlin Coroutines on Android (Google I/O'19)
37:49