Home > Mobile >  What is the best practice for creating a User entity and an Admin entity in a Springboot application
What is the best practice for creating a User entity and an Admin entity in a Springboot application

Time:04-13

What is the best practice for creating user entities in a Spring Boot application - creating separate entities for users and administrators, or creating a single user entity with a role attribute?

CodePudding user response:

Usually, going with a single user entity is the best practice, and you could add the role attribute to it to handle any functionality access through that role.

  • Related