Skip to content

phoboy725/WeatherTracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WeatherTracker

WeatherTracker is a web application for real-time weather monitoring. The application integrates with the OpenWeatherMap API, allowing authenticated users to search for locations, select specific matches from search results, and maintain a personalized dashboard of weather cards.

Features

  • Authentication: User registration and login system with BCrypt password hashing.
  • Location Search: Integration with OpenWeather Geocoding API to find and select locations by name.
  • Weather Dashboard: Persistent storage of user-tracked locations with real-time weather data.
  • Data Management: Functionality to add or remove locations from the personal tracking list.

Tech Stack

  • Backend: Java 21, Spring Framework 6.2 (MVC, ORM), Hibernate 7.2
  • Database: PostgreSQL 14
  • Database Migration: Liquibase
  • JSON Processing: Jackson
  • Frontend: Thymeleaf, Bootstrap 5
  • Web Server: Tomcat 11.0
  • Build Tool: Maven 3.9.9

API Endpoints

Authentication

  • GET /auth/sign-in — Login page.
  • POST /auth/sign-in — Process user authentication.
  • GET /auth/sign-up — Registration page.
  • POST /auth/sign-up — Create a new user account.
  • POST /sign-out — Terminate user session.

Weather & Locations

  • GET / — User dashboard displaying weather cards for saved locations.
  • GET /search?city={query} — Search for locations by name using the Geocoding API.
  • POST /add-location — Add a selected location to the user's tracking list.
  • DELETE /delete — Remove a location from the tracking list.

Configuration

The application requires an OpenWeatherMap API key.

  1. Obtain an API key at OpenWeatherMap.
  2. Configure the following properties in src/main/resources/application.properties:
    • spring.datasource.url
    • spring.datasource.username
    • spring.datasource.password
    • openweathermap.api.key

Installation

  1. Clone the repository:
    git clone https://github.com
  2. Build the project using Maven:
    mvn clean install
  3. Deploy the generated WAR file to Tomcat 11.0 or run via Maven:
    mvn cargo:run

This project is a part of Sergey Zhukov's Java backend developer course https://zhukovsd.github.io/java-backend-learning-course/projects/weather-viewer/

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors