{"id":19441001,"url":"https://github.com/raaz2/nunamassignment","last_synced_at":"2026-05-09T07:40:04.273Z","repository":{"id":192109782,"uuid":"685666754","full_name":"Raaz2/NunamAssignment","owner":"Raaz2","description":"This project aims to handle data from electric taxis efficiently. It involves designing a database for real-time info, using Java to calculate daily stats like travel time and distance, and automating nightly processing. The GitHub repo includes code, diagrams, and clear instructions for setup and use.","archived":false,"fork":false,"pushed_at":"2023-09-01T18:09:36.000Z","size":72,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-25T07:38:46.535Z","etag":null,"topics":["java","mysql","spring-boot","swagger-ui"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Raaz2.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-08-31T18:26:23.000Z","updated_at":"2023-09-01T18:01:38.000Z","dependencies_parsed_at":"2023-09-02T16:32:06.207Z","dependency_job_id":"aaf106be-2913-4dda-ba13-ba2bbe91add0","html_url":"https://github.com/Raaz2/NunamAssignment","commit_stats":null,"previous_names":["raaz2/nunamassignment"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Raaz2/NunamAssignment","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Raaz2%2FNunamAssignment","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Raaz2%2FNunamAssignment/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Raaz2%2FNunamAssignment/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Raaz2%2FNunamAssignment/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Raaz2","download_url":"https://codeload.github.com/Raaz2/NunamAssignment/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Raaz2%2FNunamAssignment/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":285200705,"owners_count":27131412,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-11-19T02:00:05.673Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","mysql","spring-boot","swagger-ui"],"created_at":"2024-11-10T15:33:46.676Z","updated_at":"2025-11-19T07:04:52.701Z","avatar_url":"https://github.com/Raaz2.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NunamAssignment\nThis project aims to handle data from electric taxis efficiently. It involves designing a database for real-time info, using Java to calculate daily stats like travel time and distance, and automating nightly processing. The GitHub repo includes code, diagrams, and clear instructions for setup and use.\n\n# Vehicle Tracking System\n\nThe Vehicle Tracking System is a Java Spring Boot application that manages and monitors vehicle data. It provides RESTful APIs for creating, updating, retrieving, and analyzing vehicle information, data points, and statistics.\n\n## Technology Stack\n\n- **Java**: Programming language for backend development.\n- **Spring Boot**: Framework for building robust and scalable applications.\n- **Spring Data JPA**: Simplifies data access using JPA (Java Persistence API).\n- **MySQL**: Relational database for storing vehicle data.\n- **Swagger**: API documentation tool for easily testing and exploring endpoints.\n- **Lombok**: Reduces boilerplate code by generating getters, setters, and constructors.\n- **Jakarta Persistence (JPA)**: API for working with databases using Java EE.\n- **Maven**: Dependency management and build tool.\n\n## Prerequisites\n\nBefore running the application, ensure that you have the following prerequisites installed:\n\n- Java Development Kit (JDK)\n- MySQL Database\n- Maven\n\n## Getting Started\n\n1. Clone the repository:\n\n   ```shell\n   git clone \u003crepository-url\u003e\n   ```\n\n2. Configure the MySQL database settings in `application.properties`:\n\n   ```properties\n   spring.datasource.url=jdbc:mysql://localhost:3306/your_database_name\n   spring.datasource.username=your_database_username\n   spring.datasource.password=your_database_password\n   ```\n\n3. Build the project:\n\n   ```shell\n   mvn clean install\n   ```\n\n4. Run the application:\n\n   ```shell\n   mvn spring-boot:run\n   ```\n\nThe application should now be up and running on `http://localhost:8080`.\n\n## Usage\n\n### Endpoints\n\n- **Create a Vehicle**\n\n  ```http\n  POST /api/vehicles/add\n  ```\n\n  Request Body:\n\n  ```json\n  {\n    \"vehicleNumber\": 10,\n    \"load\": 40.0,\n    \"dataPoints\": [\n      {\n        \"timestamp\": \"2023-09-01T17:04:20.721000\",\n        \"latitude\": 10.0,\n        \"longitude\": 10.0,\n        \"speed\": 190.0,\n        \"status\": \"RUNNING\"\n      }\n    ]\n  }\n  ```\n\n- **Get Vehicle by Number**\n\n  ```http\n  GET /api/vehicles/{vehicleNumber}\n  ```\n\n- **Update a Vehicle**\n\n  ```http\n  PUT /api/vehicles/{vehicleNumber}\n  ```\n\n  Request Body:\n\n  ```json\n  {\n    \"vehicleNumber\": 10,\n    \"load\": 50.0,\n    \"dataPoints\": [\n      {\n        \"timestamp\": \"2023-09-01T17:04:20.721000\",\n        \"latitude\": 20.0,\n        \"longitude\": 30.0,\n        \"speed\": 150.0,\n        \"status\": \"RUNNING\"\n      }\n    ]\n  }\n  ```\n\n- **Delete a Vehicle by Number**\n\n  ```http\n  DELETE /api/vehicles/{vehicleNumber}\n  ```\n\n- **Get Vehicle Statistics by Date**\n\n  ```http\n  GET /api/vehicles/statistics?date=2023-09-01\n  ```\n\n  Returns statistics for all vehicles for the specified date.\n\n### Exception Handling\n\nThe application handles exceptions gracefully and provides detailed error messages when errors occur. Custom exception classes, such as `VehicleException`, are used for better error handling.\n\n## Swagger Documentation\n\nSwagger documentation is available to explore and test the API endpoints interactively. Access the Swagger UI at `http://localhost:8080/swagger-ui.html` when the application is running.\n\n## Contributing\n\nFeel free to contribute to this project by opening issues or submitting pull requests. Your contributions are highly appreciated!\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraaz2%2Fnunamassignment","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraaz2%2Fnunamassignment","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraaz2%2Fnunamassignment/lists"}