A geração de links de convite é segura contra data races?

I want to create invitation links every time a user submits a request, but if there is a data race in which two users request a Discourse invitation link at the same time, I am afraid that one or even both of them will not receive a link because Discourse may not know how to handle the data race. This is critical for me since they have paid to obtain it, and creating them in advance is not an option because that would complicate the project architecture too much.

I don’t think there should be any problems.

Even with a thousand (to exaggerate) requests at the same time?

Without looking at the code, yes. Between Postgres and Rails, I’m pretty sure they thought of race conditions. It’s not really a difficult or unexpected problem.