You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: readme.md
+15-4Lines changed: 15 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -90,7 +90,7 @@ The _End user_ can use their mobile application (yet to be built, however the RE
90
90
5. Filter search results with a date option
91
91
6. Book a ticket for a given trip schedule
92
92
93
-
Admin interface and REST APIs both have their independent authentication mechanisms, the web application uses the cookie based authentication (provided by default by Spring security) and the RESTAPI uses the JWT authentication for access. This application assumes the availability of 'MongoDB' installation on the localhost where the server will run or the use of docker-compose to boot up a mongodb container and link the application with it within the realm of docker.
93
+
Admin interface and REST APIs both have their independent authentication mechanisms, the web application uses the cookie based authentication (provided by default by Spring security) and the REST API uses the JWT authentication for access. This application assumes the availability of 'MongoDB' installation on the localhost where the server will run or the use of docker-compose to boot up a mongodb container and link the application with it within the realm of docker.
94
94
95
95
Any changes that the admin users will do on the web portal will impact the search results of the end users, there will be certain use cases which you may find missing here, I hope you will appreciate that the overall idea was to present a way to create such an application completely inside the realm of Spring Boot and not to actually building a fully functional reservation system.
96
96
@@ -153,7 +153,7 @@ I have tried to experiment a bit with the RuntimeExceptions and come up with a m
153
153
154
154
The BRSException class has two static classes _EntityNotFoundException_ and _DuplicateEntityException_ which are the two most widely thrown exceptions from the service layer. It also contains a set of overloaded methods _throwException_ which take the EntityType, ExceptionType and arguments to come up with a formatted message whose template is present under the **_custom.properties_** file. Using this class I was able to empower the entire services layer to throw entity exceptions in a uniform manner without cluttering the code base with all sorts of NOT_FOUND and DUPLICATE entity exceptions.
155
155
156
-
For example, while login if you try to use a email address which is not regisered, an exception is raised and thrown using the following single line of code -
156
+
For example, while login if you try to use a email address which is not registered, an exception is raised and thrown using the following single line of code -
@@ -234,7 +234,7 @@ The individual areas in this layout serve the following purpose :
234
234
-**Sidebar**: a sidebar for additional information
235
235
-**Footer**: the footer area that provides the copyright info
236
236
237
-
These components can be located in the resources/templates directory at the root as well as under the sub-directories fragements and layout. The content area in this layout will host the following pages :
237
+
These components can be located in the resources/templates directory at the root as well as under the sub-directories fragments and layout. The content area in this layout will host the following pages :
238
238
239
239
- Dashboard
240
240
- Agency
@@ -268,7 +268,7 @@ You can also use Maven plugin to run the app. Use the below example to run your
268
268
mvn spring-boot:run
269
269
```
270
270
271
-
You can follow any/all of the above commands, or simply use the run configuration provided by your favorite IDE and run/debug the app from there for development purposes. Once the server is setup you should be able to access the admin interface at the following URL :
271
+
You can follow any/all of the above commands, or simply use the run configuration provided by your favourite IDE and run/debug the app from there for development purposes. Once the server is setup you should be able to access the admin interface at the following URL :
272
272
273
273
http://localhost:8080
274
274
@@ -286,6 +286,7 @@ Some of the important api endpoints are as follows :
@@ -300,6 +301,16 @@ docker run -p 8080:8080 spring/starterkit
300
301
301
302
Please **note** when you build the container image and if mongodb is running locally on your system, you will need to provide your system's IP address (or cloud hosted database's IP) in the application.properties file to be able to connect to the database from within the container.
302
303
304
+
##### Docker Compose #####
305
+
Another alternative to run the application is to use the docker-compose.yml file and utility. To build the application using docker-compose simply execute the following command :
306
+
```
307
+
docker-compose build
308
+
```
309
+
310
+
And to run the application, please execute the following command :
311
+
```
312
+
docker-compose up
313
+
```
303
314
304
315
## User Interface ##
305
316
Here are the various screens of the Admin portal that you should be able to use once the application is setup properly :
0 commit comments