I have a series of streams in a category with ids like:
category-instanceid
the events in the stream are all of the same type. what I want is a way to get the last event of every instance stream in the category
I can project them into a stream which has every event based on the category, then read all of those events and just take the last one for each instance id in my aggregate, but I want to know if there is a way I can make my projection only take the last event in each instance stream to save me loading all events.
Any thoughts?