Skip to content

harikrishna-t-s/Jobly

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🎯 Jobly - Job Posting Platform

Java Spring Boot MySQL Thymeleaf License

A modern, role-based job posting platform built with Spring Boot

Features β€’ Quick Start β€’ Demo Accounts β€’ Documentation


πŸ“‹ Overview

Jobly is a full-featured job posting and application platform that connects job seekers with employers. Built with enterprise-grade technologies, it demonstrates best practices in Spring Boot development, security, and modern web architecture.

🎭 User Roles

  • πŸ‘” Candidates - Browse jobs, submit applications, track application status
  • 🏒 Companies - Create company profiles, post job openings
  • πŸ“Š Hiring Managers - Manage job postings, review applications
  • βš™οΈ Super Admin - Platform oversight and user management

πŸ“Έ Screenshots

Admin Dashboard

Admin Dashboard Comprehensive admin panel for managing users, companies, and job postings

Company Portal

Company Portal Company dashboard showing overview and quick actions

Company Jobs Posted View and manage all job postings for your company

Company Job Posting Create and edit job postings with detailed information

Candidate Portal

Candidate Portal Candidate dashboard with personalized job recommendations

Candidate Job View Detailed job listing view with company information

Candidate Job Application Submit job applications with cover letter and resume


✨ Features

Core Functionality

  • βœ… Role-Based Access Control - Secure authentication with 4 distinct user roles
  • βœ… Job Management - Full CRUD operations for job postings
  • βœ… Application System - Complete job application workflow with status tracking
  • βœ… Company Profiles - Dedicated company pages with job listings
  • βœ… Admin Dashboard - Comprehensive platform management tools

Technical Highlights

  • πŸ” Spring Security - BCrypt password encryption, session management
  • πŸ“Š JPA/Hibernate - Auto-generated database schema with audit trails
  • 🎨 Thymeleaf Templates - Server-side rendering with reusable components
  • πŸ“ Validation - Comprehensive input validation and error handling
  • πŸ“š API Documentation - Swagger/OpenAPI integration
  • πŸ” Exception Handling - Centralized error management

πŸš€ Quick Start

Prerequisites

  • Java 21 (LTS)
  • MySQL 8.0+
  • Maven 3.6+

Installation

  1. Clone the repository

    git clone https://github.com/yourusername/jobly.git
    cd jobly
  2. Create MySQL database

    CREATE DATABASE jobly;
    CREATE USER 'jobly_user'@'localhost' IDENTIFIED BY 'your_password';
    GRANT ALL PRIVILEGES ON jobly.* TO 'jobly_user'@'localhost';
    FLUSH PRIVILEGES;
  3. Configure application

    Update src/main/resources/application.properties:

    spring.datasource.url=jdbc:mysql://localhost:3306/jobly
    spring.datasource.username=jobly_user
    spring.datasource.password=your_password
  4. Run the application

    ./mvnw spring-boot:run
  5. Access the application

    Open your browser to: http://localhost:8080


πŸ‘₯ Demo Accounts

The application comes with pre-configured test accounts. See CREDENTIALS.txt for the complete list.

Quick Access

Role Email Password
Super Admin admin@jobly.com Admin@123
Candidate john.doe@example.com Password@123
Hiring Manager sarah.williams@techcorp.com Password@123

Sample Data Included:

  • 3 Candidates
  • 2 Companies (TechCorp Solutions, Innovate Labs)
  • 5 Job Postings
  • 4 Job Applications

πŸ—οΈ Architecture

Tech Stack

Backend

  • Spring Boot 3.3.5
  • Spring Security 6
  • Spring Data JPA
  • Hibernate ORM
  • MySQL 8.0

Frontend

  • Thymeleaf 3.1
  • HTML5 & CSS3
  • JavaScript

Tools & Libraries

  • Lombok - Reduce boilerplate code
  • Springdoc OpenAPI - API documentation
  • BCrypt - Password encryption
  • Maven - Build automation

Project Structure

com.jobly/
β”œβ”€β”€ config/              # Configuration classes
β”‚   β”œβ”€β”€ SecurityConfig   # Spring Security setup
β”‚   β”œβ”€β”€ DataInitializer  # Dummy data seeding
β”‚   └── OpenApiConfig    # Swagger configuration
β”œβ”€β”€ controller/          # MVC Controllers
β”‚   β”œβ”€β”€ AuthController
β”‚   β”œβ”€β”€ JobController
β”‚   β”œβ”€β”€ ApplicationController
β”‚   └── AdminController
β”œβ”€β”€ dto/                 # Data Transfer Objects
β”œβ”€β”€ exception/           # Exception handling
β”œβ”€β”€ model/              # JPA Entities
β”‚   β”œβ”€β”€ User
β”‚   β”œβ”€β”€ Role
β”‚   β”œβ”€β”€ Company
β”‚   β”œβ”€β”€ Job
β”‚   └── JobApplication
β”œβ”€β”€ repository/         # Spring Data repositories
β”œβ”€β”€ security/           # Security components
└── service/            # Business logic

πŸ—„οΈ Database Schema

Core Entities

erDiagram
    User ||--o{ JobApplication : submits
    User ||--o{ Job : posts
    User }o--o{ Role : has
    Company ||--o{ Job : owns
    Job ||--o{ JobApplication : receives

    User {
        Long id PK
        String fullName
        String email UK
        String phone
        String password
        boolean enabled
    }

    Company {
        Long id PK
        String name UK
        String description
        String website
        String address
        Long ownerId FK
    }

    Job {
        Long id PK
        String title
        String description
        String location
        EmploymentType type
        Integer salaryMin
        Integer salaryMax
        JobStatus status
        Long companyId FK
        Long postedById FK
    }

    JobApplication {
        Long id PK
        Long jobId FK
        Long candidateId FK
        String coverLetter
        String resumeUrl
        ApplicationStatus status
    }
Loading

πŸ” Security

Authentication & Authorization

  • Session-based authentication with Spring Security
  • BCrypt password hashing with secure work factor
  • Role-based access control using method-level security
  • CSRF protection enabled for all forms
  • SQL injection prevention via JPA prepared statements

Security Features

@PreAuthorize("hasRole('SUPER_ADMIN')")
public void adminOnlyMethod() { }

@PreAuthorize("hasAnyRole('COMPANY', 'HIRING_MANAGER')")
public void postJob() { }

πŸ“‘ API Documentation

Interactive API documentation is available via Swagger UI:

URL: http://localhost:8080/swagger-ui.html

Key Endpoints

Method Endpoint Description Access
GET /jobs List all jobs Public
GET /jobs/{id} Job details Public
POST /jobs Create job Hiring Manager
POST /jobs/{id}/apply Apply to job Candidate
GET /admin/dashboard Admin panel Super Admin

πŸ§ͺ Testing

Running Tests

# Run all tests
./mvnw test

# Run with coverage
./mvnw test jacoco:report

Test Structure

  • Unit Tests - Service layer logic with Mockito
  • Integration Tests - Full application context with test database
  • Controller Tests - MVC layer with @WebMvcTest

πŸ“¦ Deployment

Building for Production

# Create executable JAR
./mvnw clean package

# Run the JAR
java -jar target/Jobly-0.0.1-SNAPSHOT.jar

Docker Deployment

FROM eclipse-temurin:21-jre
COPY target/*.jar app.jar
ENTRYPOINT ["java","-jar","/app.jar"]

Environment Variables

SPRING_DATASOURCE_URL=jdbc:mysql://db:3306/jobly
SPRING_DATASOURCE_USERNAME=jobly_user
SPRING_DATASOURCE_PASSWORD=secure_password

🀝 Contributing

Contributions are welcome! Please follow these steps:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Coding Standards

  • Follow Java naming conventions
  • Use meaningful variable and method names
  • Write JavaDoc for public methods
  • Include unit tests for new features
  • Format code with Google Java Format

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

About

No description or website provided.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors