RxJava v1.1.6 發布,一個實現異步操作的庫
RxJava一個在 Java VM 上使用可觀測的序列來組成異步的、基于事件的程序的庫。說到根上,它就是一個實現異步操作的庫,而別的定語都是基于這之上的。同樣是做異步,為什么人們用它,而不用現成的 AsyncTask / Handler / XXX / ... ?,原因是RxJava簡潔,異步操作很關鍵的一點是程序的簡潔性,因為在調度過程比較復雜的情況下,異步代碼經常會既難寫也難被讀懂。 Android 創造的 AsyncTask 和Handler ,其實都是為了讓異步代碼更加簡潔。RxJava 的優勢也是簡潔,但它的簡潔的與眾不同之處在于,隨著程序邏輯變得越來越復雜,它依然能夠保持簡潔。
更新日志
API增強
- Pull 3934:
TestSubscriber
extra info on assertion failures - Pull 3948: add
Completable.andThen(Completable)
- Pull 3942: add
Completable.subscribe
to be safe, addunsafeSubscribe
option +RxJavaPlugins
hook support - Pull 3936: promote
UnicastSubject
to be a standard+experimentalSubject
- Pull 3971: add
Observable.rebatchRequests
operator to change and stabilize request amounts of the downstream. - Pull 3986: add
Schedulers.reset()
for better testing - Pull 3918:
ReplaySubject
now supports backpressure
API棄用
- Pull 3948 deprecate
Completable.endWith()
in favor ofandThen()
性能增強
- Pull 3470:
replay
request coordination reduce overhead
Bug修復
- Pull 3924: fix
RxRingBuffer
-pool depending on thecomputation
scheduler - Pull 3922: fix
using()
resource cleanup when factory throws or being non-eager - Pull 3941: fix
Single.flatMap
not composing subscription through - Pull 3958: fix
just()
construction to call theonCreate
execution hook - Pull 3977: Use the correct
Throwable
to set the cause forCompositeException
- Pull 4005: Fix Spsc queues reporting not empty but then poll() returns null.
下載
本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!