It’s probably significantly easier to just not use user manager, but to use a standalone RADIUS server instead that directly connects to that database.
RADIUS just takes login requests and either accepts or denies them. It can handle hundreds of requests per minute. How many user accounts can be stored depends entirely on the database backend.