Including Spring Security Basic configuration
- run
docker.sh
ordocker.bat
to start mongo - start the app through main() in Application.kt
- users are defined in application.yaml
- use HTTP Basic Authorization. Token can be generated in TokenGenerator test (after removing @Ignored)
EndToEndTest.kt has tests mentioned in requirements test.http - sample http requests
- Caching customers queries
API will be used by bank employee for auditing operations on accounts. For simplicity the user will be authenticated using Basic HTTP Authorization. The users list may be predefined in any way ie. the properties file. The API interface accepts two parameters: client's identification number and the identifier of account type. In response the user gets a list of transactions, sorted ascending by transaction amount, with transaction date, amount, id, name of the account type, and first and last name of the ordering client.
- transactions.csv - transactions with their amount, customers' ids and account type id
- accounttypes.csv - account types with their identifiers
- customers.csv - customers data
a) account_type - it may be a single account type id (ie. "1"), list of identifiers ("1, 3") or the special value "ALL" which returns all account types. Empty parameter equals the "ALL" wildcard. b) Ordering client id - analogous a single id, a list, "ALL" value or empty.
Spring Boot application written in Kotlin. Provided data should be loaded at the start of application to MongoDB. Every time the application is started the data should be removed and loaded again. Collections can be splitted however one wants. Read speed should be priority.
Preferred build tools: Maven or Gradle 5+
The endpoint should have at least 3 unit tests - with both arguments stated, one argument empty and both arguments empty or "ALL".