Improving the TechEmpower results

Hi there,

I’ve added Hanami to the TechEmpower benchmarks:

I’d like to improve the results.

Currently I’m doing the following to update the the World model:

The problem here is that this loads the world model twice (once on line 11 and once on line 16 for the update). Is there a more ideomatic way to solve this?

It’s also allowed to do a batch update and update multiple Worlds at once.
This would improve the score a lot more.

1 Like

I’ve updated the code to the following, which only does the required calls.

1 Like

Good solve, @p81! This is what I would have suggested too. If you already have the attributes you want to persist, there’s no need to load the rest of the record beforehand.

Sorry for the delay in my reply. Please let us know if there’s anything else we can do to help. Did you also find a solution for batch updating multiple worlds?

Thanks. I’ll let you know if I run into other issues.

1 Like