-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat/1 weather api #5
Open
fronzec
wants to merge
31
commits into
main
Choose a base branch
from
feat/1-weather-api
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Introduce `go.mod` file to define the module as `weather-service` and set Go version to 1.23. Include a basic `main.go` file with a sample program to print a greeting and iterate through a loop with calculations.
This commit introduces a .gitignore file to prevent tracking of binaries, logs, OS-generated files, and IDE-specific settings. It helps maintain a cleaner repository by excluding build outputs and dependency directories.
Created a README file introducing the Weather API Service. It includes a brief project description and a reference to the problem it solves.
Introduced an OpenAPI 3.0.0 specification with /ping and /weather endpoints, supporting basic application functionality. Expanded the README file to include a detailed project roadmap using a Gantt chart.
Replaced placeholder code with an HTTP server using net/http. Added a new /ping endpoint responding with an empty JSON object, and organized logic into a separate handlers package for better modularity. Logging was introduced to track server startup and errors.
This commit includes a basic `.air.toml` configuration file to enable live reloading for the development environment. It specifies build commands, file inclusion/exclusion rules, and other useful settings to streamline the development workflow using the Air tool.
Introduced a Taskfile.yml to streamline task execution. Added a "test" task for simple functionality testing and an "air" task to launch a development server on port 8080. This simplifies dev workflows.
This change ensures that temporary files located in the /tmp/ directory are excluded from version control. It helps prevent unnecessary clutter in the repository and avoids committing unintended files.
Introduced a new /weather route that responds with hardcoded weather data based on a required 'address' query parameter. Returns a JSON object with location, temperature, humidity, and condition, improving the API's functionality.
Create a new file `test.http` with sample requests to ping the server and fetch weather data by address. This helps in quick testing and debugging of API endpoints.
Introduce a `docker-compose.yml` file with a Redis service and update the Taskfile with environment setup and container management tasks. This improves local development workflows by providing consistent and reproducible environments.
Renamed `_devenvironment` to `_devenv` and adjusted file paths accordingly. Updated `Taskfile.yml` commands to reference the new directory and included `--project-name` for podman commands. These changes improve organization and clarity in the development setup.
Removed unnecessary `--port 808` option from the `air` command since it defaults to the correct value. This improves configuration clarity and reduces redundancy.
… database settings
…d improve code readability
…r weather data caching
Added `http-client.private.env.json` to `.gitignore` for better environment configuration management. Extended `test.http` with new sample API requests, including a third-party weather service demonstration.
…est steps for weather-service
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Weather API service
Solves this problem