I. Prerequisites:
- Java 11 or higher
IDE
(preferably IntelIJ, the candidate must choose what he feels most comfortable with)Postman
- GitHub client
Maven
II. External Validation API
- Clone GitHub repository:
[email protected]:laurentiu-miu/validator.git
- Start the application from command line
- Read the
OpenAPI Documentation of External API
III. What to do:
- Initialize a maven Spring Boot Application named Person Manager.
- Create an entity Person that contains name, email, phone.
- Create REST endpoints to address CRUD operations for the entity Person.
- Copy past (from validator project) the class rest.api.client.Mailer into Person Manager and use it to send email (after saving it to the database) to newly added email. from: [email protected] subject: "Welcome to Person Manager" body: "Now you are on our list mwahahaha!!!"
- All newly added persons must have email & phone validated (using external API validator):
- if the phone or email is not valid the person must not be added.
- all modifications on email & phone must be validated in order to be updated
- if a 5xx category error appear then a retry 3 times with a backoff of 5 sec
- Schedule a job to publish to log total number of persons every 5 minutes
- Use spring async(with sleep 5 sec) to send invalid phones and emails to log
- Check what are the transitive maven dependency
- Perform Unit Test on created endpoint