Pre-release version of a Stroom authentication service.
A service that accepts HTTP requests for authentication, and returns JWS tokens.
You can interrogate the service using HTTPie.
You can use this token to make requests to secured endpoints. The default email and password is admin:admin.
$ http POST localhost:8099/authentication/login email=admin password=admin
In the below you'd have to paste your JWS token.
The following would get all users, with 10 per page.
$ http GET 'http://localhost:8099/user/?fromEmail=&usersPerPage=10&orderBy=id' Authorization:"Bearer <TOKEN>"
The following would get users from testUser, with 10 per page.
$ http GET 'http://localhost:8099/user/?fromEmail=testUser&usersPerPage=2&orderBy=id' Authorization:"Bearer <TOKEN>"
This module accesses the existing Stroom database. Eventually the relevant tables will be migrated to a service. But until then we'll access them in this fashion, using JOOQ.
Obviously you'll lose test data if you do this.
- Stop the database container and delete it
- Change the migrations to whatever SQL you need
- Run the app to perform the migrations (or use the Flyway command line)
- Delete the old models at
stroom-persistence/src/main/java/stroom. - Run
./gradlew generateAuthdbJooqSchemaSourceto generate the models again - Restart app