Eternal Mori
Eternal Mori
CCConvex Community
Created by Eternal Mori on 4/12/2025 in #support-community
Is this the correct way of processing data?
I am kinda new to convex and I am experimenting to check if I should migrate my existing app to convex. So I try to migrate the most demanding part of my existing app over to convex. If it can handle that, it can handle everything else to. I just started and created a workflow that truncates a summary table and go recursivly over all the data needed to do processing on to fill back up the summary table. In my old app, the script takes around 30 seconds to run. With the exact same data for only the current part of the code (below) it is still going (23 mins at the moment) without even processing anything. My question is, is this the correct way of doing this work in convex? https://pastebin.com/KjQYtYwM
5 replies
CCConvex Community
Created by Eternal Mori on 4/11/2025 in #support-community
What should I use for processing a large dataset?
I have a dataset containing a +5 million rows. I need to do a lot of calculations on those rows. What should I use? a mutation, action, scheduled job, workflow? I am self hosting and the functions takes more than 10 minutes. That is why I think I need a workflow. Is this right?
6 replies
CCConvex Community
Created by Eternal Mori on 4/11/2025 in #support-community
Cant see logs of actions called inside my workflow
When I start a workflow, I see all the logs in the function definition. But when I call queries or mutations from the workflow I dont see the logs. This makes it very hard to debug when writing code.
workflow.define({
handler: async (ctx) => {
console.log("hey, ..."); // this log I can see

// the console log inside this query function does not show up
await ctx.runQuery(...)
},
});
workflow.define({
handler: async (ctx) => {
console.log("hey, ..."); // this log I can see

// the console log inside this query function does not show up
await ctx.runQuery(...)
},
});
2 replies