Skip to content

Web application for digital accounting of books in the library and accounting information about library readers.

Notifications You must be signed in to change notification settings

StasonMendelso/Digital-accounting-of-books-in-the-library-v1.0

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Digital accounting of books in the library

What is the project about?

Repository is for implementing the technical task from the course - creating a web-application for digital accounting of books in the library and accounting information about library's readers. You can find more information about task here.

What is the purpose of this project?

The purpose of the project is using knowledge in practice, learned about the Spring framework on the course, how it should be used to implement the task. As for me, I haven't got almost any experience of using Spring in such tasks, so I want to try it instead of using the Servlet API in web-applications.

In addition to, it is the first project, where I use the Spring framework for implementing such technical task.

Getting Started

For running the app you need to download the latest version from the main branch and configure the database and connection to it. Follow the next chapters.

Prerequisites

For running some branches of the projects you need the next:

  • Tomcat 9.0.60 - for running the Spring MVC application part.
  • PostgreSQL 15 - for running the app with database. Also you can use another database. You can find the script of creating database in directory with name "database".

Installation Instruction

How to download project on my local machine?

For downloading the project locally you can use two variants:

  1. Download the ZIP archive from the repository page.

    The method is easy, the next steps helps you:

    1. Find the button Code and press it.
    2. Find the button Download ZIP and press it. The downloading must start.
    3. Unzip the archive in soe directory and run the IDEA in this directory.

    Project has been installed. After opening it in your IDEA, the Maven downloads some additional dependencies.

  2. Use the Git for downloading the repository locally.

    The method a lit bit difficult, but the project will be downloaded with the help of several commands, and not manually, as in the previous method. For this method you need to install the Git Bash on your computer, make some configuration and have a primary skill of using this system of version control.

    1. Enter your name, email of GitHub account locally on your machine.

    2. Create an empty directory and initialize it as git repository. Use the next command - git init.

    3. Adds this repository to yours with name origin (you can change it, if you want):

      $ git remote add origin git@github.com:StasonMendelso/Digital-accounting-of-books-in-the-library.git
      

      But you need configure your SSH connection to your GitHub profile in Git Bash. See more here.

      For viewing that the repository has been added successfully to your local repository, you need execute the next command and get the following result:

      $ git remote -v
      

      git remote repository

      After this step your local repository has got a 'connection' to the remote project from the GitHub repository.

    4. For downloading the project use the following command:

      $ git pull origin
      

      After these steps your project directory must contain the project files from GitHub repository. In addition to, you can create a new branch, make some changes and create a pull request for suggesting your improvements. Also, all changes are observed by the git and you can always make a rollback of all changes git reset --hard.

What things you need to install the software and how to install them?

Database configuration

For running the database you can use as me PostgreSQL or create your own database on another SQL server using the script file of creating the database. Note: if you use another server not such PostgreSQL you should change JDBC driver for working with it and configurate the connection to your server in appropriate property file, which you must create manually.
You can find an empty database configuration file, which must be renamed to "database.properties" instead of "database.properties.origin". This file contains only keys for configuration the database, so you can put your values to the file and run application with this database configuration.

Server configuration

For running the code you need install the Tomcat and configure it in your idea. If you use the Intellij IDEA you can click on Run button and choose Edit configuration, then add configuration for Tomcat server. Almost all configuration of app must be added automatically, but check it before running. You can see official guide. After configuration, you can press run button of the server and go to browser to check the application work.

Examples of web-application's pages. Endpoints.

If you want to open them in browser you need to enter one of the two URL:

  • "localhost:{port}/{applicationContext}/people" - to open a page with all peoples;
  • "localhost:{port}/{applicationContext}/books" - to open a page with all books,

where {port} - is a port, on which you server is running; {applicationContext} - is an application context name, which you give in your server configuration for this app.

Here you can find the screenshots of the web-application:

People page

You can find more photos here.

Built With

  • Maven - Dependency Management

Author

About

Web application for digital accounting of books in the library and accounting information about library readers.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published