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

IObservable signature #40

Open
buybackoff opened this issue Mar 14, 2016 · 3 comments
Open

IObservable signature #40

buybackoff opened this issue Mar 14, 2016 · 3 comments

Comments

@buybackoff
Copy link
Member

Maybe it should be just or only and should be used to signal a consumer that synchronous MoveNext should return true. There are cases when we do not want to evaluate every CurrentValue, e.g. to take Nth value. With IObservable the only way to do so is to not send values inside OnNext.

@buybackoff
Copy link
Member Author

All observables are cold in Spreads - that is the point of having a key, which adds ability to subscribe from history. We should have an overload to subscribe from a particular key, not only from start. Or we could use .Range(this.Last.Key, null).Subsribe() - range/from methods already change the first key. This must be documented.

@buybackoff
Copy link
Member Author

Series is a getter of a mapper function (implemented as a cursor). IAsyncEnumerable/IObservable are just to dual ways to get all values. It is just a coincidence that IEnumerable MoveNext is a part of ICursor. For IEnumerable it is used for value consumption, for ICursor it is used for navigation.

When IEnumerable.MoveNext returns false it is not the same as Rx's OnComplete, it means that we do not have values right now (hot path) and should switch to async pull. Rx is pushing, but with reactive streams (#29) Request(n) we could control the pace.

This was referenced Apr 19, 2016
@buybackoff buybackoff changed the title IObserbale signature IObservable signature Jul 13, 2016
@buybackoff buybackoff mentioned this issue Mar 24, 2017
@buybackoff buybackoff added this to the Beta milestone May 2, 2017
@buybackoff
Copy link
Member Author

For the milestone need to implement reactive streams logic, but without binary dependency to the package.

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

No branches or pull requests

1 participant