Comments (5)
This client is just exposing the API provided by Event Store, so I can't speak for the design decisions behind the API itself.
Usually, what you would want to do is subscribe to a stream, and you'll receive a callback each time a new event is posted. When you subscribe, you receive in the response the event ID of the most recent event in the stream, so you can use this to decide if you need to load any history from the stream since before the subscription was started.
from event-store-client.
This is possible using the native event store, by using ReadSingleEvent with StreamPosition.End
. See here: http://docs.geteventstore.com/dotnet-api/3.0.0/reading-events/#reading-a-single-event-1
from event-store-client.
StreamPosition.End has the magic value -1, so you can try using that. I can look at defining that as a constant in a future release of the client.
from event-store-client.
-1 did the trick! Might be worth adding to the docs somewhere, or as a constant as you suggest, must be a failry common use case.
from event-store-client.
Ok, cool.
I'll add the StreamPosition constants into the client.
from event-store-client.
Related Issues (20)
- Wish list for version 1.0.0 HOT 1
- handling of "socket has been ended by the other party" HOT 3
- Transaction support HOT 1
- Client connection lost during heartbeat timeout HOT 4
- Support for large messages
- Subscription dropout HOT 8
- TypeScript typings HOT 4
- How to handle connection errors? HOT 2
- Support for SSL HOT 1
- Many concurrent subscriptions on a connection closes connection with no error
- Error from long-running event handler HOT 14
- Support for Angular 5 + Typescript client-side app ? HOT 2
- Persistent Subscriptions/ Competing consumer HOT 1
- typedefinition bug HOT 1
- StoredEvent data and others received as Buffer HOT 3
- Support for async/await on the onEventAppeared for subscribeToStreamFrom HOT 2
- Accessing linked event information HOT 1
- Handling for circuit breaker HOT 1
- Minor bug in typescript definition file
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from event-store-client.