Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Library throw exception in rx flow #111

Open
Vaek opened this issue Mar 8, 2019 · 4 comments
Open

Library throw exception in rx flow #111

Vaek opened this issue Mar 8, 2019 · 4 comments

Comments

@Vaek
Copy link

Vaek commented Mar 8, 2019

Actually we log exceptions from library. What fix you suggest?

java.io.IOException: Operation not permitted
    at java.net.PlainDatagramSocketImpl.send(PlainDatagramSocketImpl.java)
    at java.net.DatagramSocket.send(DatagramSocket.java:696)
    at com.instacart.library.truetime.SntpClient.requestTime(SntpClient.java:116)
    at com.instacart.library.truetime.TrueTime.requestTime(TrueTime.java:133)
    at com.instacart.library.truetime.TrueTimeRx$4$1$2.subscribe(TrueTimeRx.java:211)
    at io.reactivex.internal.operators.flowable.FlowableCreate.subscribeActual(FlowableCreate.java:72)
    at io.reactivex.Flowable.subscribe(Flowable.java:14409)
    at io.reactivex.Flowable.subscribe(Flowable.java:14356)
    at io.reactivex.internal.operators.flowable.FlowableSubscribeOn$SubscribeOnSubscriber.run(FlowableSubscribeOn.java:82)
    at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66)
    at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57)
    at java.util.concurrent.FutureTask.run(FutureTask.java:237)
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:272)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
    at java.lang.Thread.run(Thread.java:761)
@jemshit
Copy link

jemshit commented Mar 14, 2019

Use #101 (comment)

@Vaek
Copy link
Author

Vaek commented Mar 14, 2019

Thanks but it is not solution. We already have set global rx error handler. Error should be catched by subscribed observer, if it would be thrown in init flow, but these errors are thrown in library scheduled work. What about add subscription for these scheduled work? In global error handler we are not able to recognise this IOException from other errors.

@LosDanieloss
Copy link

LosDanieloss commented Jul 10, 2019

I know it's been a while but I've posted my finding in here: #119 (comment) . Maybe this will help you somehow

@DidUNooono
Copy link

SDK
Sdk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants