You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Main Question here is what's the best way to async in stream execute database requests that could return easily up to some million values paginated so that I can in process2 use the values to process them
the only working solution for me was creating 2 streams one that goes till process 1 and then emits from process1 the loop results till there are no once anymore
but I think I am missing something I am 100% sure there is a way that I can do that in a single stream
and not taking the values from the DB query results stream via onValue process and emit them.
My main problem is that i don't know how to loop over a stream value until i have all results :)
and then keep emmit results
I understand only that i could loop over it until it is complet processed and then return complet result but thats not possible because data size
i see no function that could do it only withHandler and Scan maybe.
// Constant string value from string
var first = Kefir.constant('str')
// First results for the constant returns stream of array itms
var firstResult = first.map(createFirst)
var process1 = firstResults.flatten().map(generateMoreStuffButKeepOld_Stuff) // WithHandler, Scan,
// Here it starts to get Complex because generateMoreStuffButKeepOld_Stuff will
// async produce results for each value of firstResult and we don't know how much it creates
// It could be easy around a million items so we need to emit results while processing
// Transforming results from process1 into its final state.
var process2 = process1.flatten().map()
The text was updated successfully, but these errors were encountered:
The Main Question here is what's the best way to async in stream execute database requests that could return easily up to some million values paginated so that I can in process2 use the values to process them
the only working solution for me was creating 2 streams one that goes till process 1 and then emits from process1 the loop results till there are no once anymore
but I think I am missing something I am 100% sure there is a way that I can do that in a single stream
and not taking the values from the DB query results stream via onValue process and emit them.
My main problem is that i don't know how to loop over a stream value until i have all results :)
and then keep emmit results
I understand only that i could loop over it until it is complet processed and then return complet result but thats not possible because data size
i see no function that could do it only withHandler and Scan maybe.
The text was updated successfully, but these errors were encountered: