Identity Services - quark-bits/identity-services GitHub Wiki
Requirements
Develop RESTful Webservice
- Creation of new user.
- Login an existing user with username/password.
- Track Successful/Failure Login Events.
Assumptions
- REST service responses will be JSON.
- Login just returns success/failure. There is no session management.
Technical Approach
Persistence Layer
Database: Relational vs NoSQL: The requirement has fairly structured data and defined relationship can be established. Hence Relational Database is considered. ORM: Hibernate
Service Layer
Framework: Vanilla Jersey vs SpringBoot. SpringBoot has rich integration support with various components like ORMs, Security so on.
Tools/Libraries Used
- SpringBoot: Jersey(Jax-RS), Hibernate JPA(Default),
- Database: H2 DB
- RunTime: Jetty
- Encryption: Apache commons Codec
Limitations
- Caching is not implemented. -> Use spring-boot-starter cache with JCache or any other supported provider.
- Data Validation is currently Broken.-> Bean/Entity validation annotations not working. TODO
- Password Encryption to be more stronger -> Add Random SALT and store.
- Cover more test-cases.
- Include Logging.
Improvements to extend to Full-Blown Services
- Include NFR testing.
- Swagger/RestAPI Documentation
- Client Libraries - Helps in quick uptake and adoption of services.
- Permissions is not implemented.