-
Notifications
You must be signed in to change notification settings - Fork 0
maven wrapper and application properties
Shelson Ferrari edited this page Jul 23, 2024
·
5 revisions
The Maven Wrapper is a tool that allows a project to use a specific version of Maven without needing to install Maven manually on the development machine. This ensures that all developers use the same version of Maven, avoiding compatibility issues.
- mvnw: Script for Unix/Linux.
- mvnw.cmd: Script for Windows.
- .mvn/wrapper/maven-wrapper.jar: Maven Wrapper executable.
- .mvn/wrapper/maven-wrapper.properties: Maven Wrapper configuration.
To add the Maven Wrapper to your project, run the following command in the root directory of your project:
mvn -N io.takari:maven:wrapper
This will generate the necessary Maven Wrapper files.
The src/main/resources/application.properties file is used to configure various properties of the Spring Boot application.
# ---------------------------------
# _____ __ __ ______ _
# / ___// /_ ___ / /________ ____ / ____/__ ______________ ______(_)
# \__ \/ __ \/ _ \/ / ___/ __ \/ __ \ / /_ / _ \/ ___/ ___/ __ `/ ___/ /
# ___/ / / / / __/ (__ ) /_/ / / / / / __/ / __/ / / / / /_/ / / / /
# /____/_/ /_/\___/_/____/\____/_/ /_/ /_/ \___/_/ /_/ \__,_/_/ /_/
# ---------------------------------
# Currency Conversion API
# Application configuration file (application.properties)
# - Defines the location of the custom banner file
# - Configures the banner variables
# - Configures the H2 datasource
# - Enables the H2 console
# - Configures JPA/Hibernate
# - Defines logging configurations
# - Configures the server port
# - Configures springdoc-openapi
# - Maven project properties
# ---------------------------------
# ---------------------------------
# Defines the location of the custom banner file
# ---------------------------------
spring.banner.location=classpath:banner.txt
# ---------------------------------
# Defines a banner variable for the application version
# ---------------------------------
spring.banner.variable.app_version=${java.version}
# ---------------------------------
# H2 datasource configurations
# ---------------------------------
spring.datasource.url=jdbc:h2:mem:shelson;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE
spring.datasource.driverClassName=org.h2.Driver
spring.datasource.username=sa
spring.datasource.password=
# ---------------------------------
# Enables the H2 console
# ---------------------------------
spring.h2.console.enabled=true
spring.h2.console.path=/h2-console
spring.h2.console.settings.web-allow-others=true
# ---------------------------------
# JPA/Hibernate configurations
# ---------------------------------
spring.jpa.database-platform=org.hibernate.dialect.H2Dialect
spring.jpa.hibernate.ddl-auto=update
spring.jpa.show-sql=false
spring.jpa.properties.hibernate.format_sql=true
# ---------------------------------
# Hibernate logging configurations
# ---------------------------------
logging.level.org.hibernate.SQL=OFF
logging.level.org.hibernate.type.descriptor.sql.BasicBinder=OFF
# ---------------------------------
# Spring logging configurations
# ---------------------------------
logging.level.org.springframework.web=ERROR
logging.level.org.springframework.boot=ERROR
logging.level.root=INFO
# logging.pattern.console=%d{yyyy-MM-dd HH:mm:ss} - %msg%n
# logging.pattern.file=%d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{36} - %msg%n
# ---------------------------------
# Server port
# ---------------------------------
server.port=8080
# ---------------------------------
# springdoc-openapi configurations
# ---------------------------------
springdoc.api-docs.path=/api-docs
springdoc.swagger-ui.path=/swagger-ui.html
# ---------------------------------
# Maven project properties (these will be replaced during resource filtering)
# ---------------------------------
project.name=@project.name@
project.description=@project.description@
project.phase=@project.phase@
# project.basedir=@project.basedir@
springdoc.swagger-ui.enabled=true
# ---------------------------------
# Swagger
# ---------------------------------
api.title=Currency Conversion API
api.description=API for converting currency rates
api.version=1.0
swagger.group=shelson-api
swagger.packages-to-scan=com.shelson
swagger.paths-to-match=/**- Overview: Presentation of the project, highlighting its purpose and the context in which it is embedded.
- Project Objectives: Enumeration of the main objectives that the project aims to achieve.
- Scope and Functionalities: Description of the main functionalities offered by the project and its scope of operation.
- Initial Configurations: Steps required to set up the development or production environment.
- Installation Instructions: Detailed procedures for installing the project in different environments.
- Docker Configuration: Specifications on how to configure and use Docker for the project.
- Folder Structure: Description of the organization of the project directories.
- Project Architecture: Explanation of the architecture used, including design patterns and technical decisions.
- Development Flow: Description of the development process adopted, including planning, coding, and review stages.
- Apache Camel Integration: Guide on integrating Apache Camel into the project, including configuration and usage.
- Contributors and Authors: Recognition of the contributors to the project.
- Contributions: Guidelines on how to contribute to the project, including code standards and pull request requirements, tips and best practices.
- Code of Conduct: Behavioral guidelines expected for the project community.
- OpenAPI Specification: Details about the OpenAPI specification used to document the API endpoints.
- API Documentation with Swagger: Information on how to access and use the interactive API documentation generated by Swagger.
- Javadoc Documentation: Information on the Javadoc documentation generated for the project.
- Endpoint Description: Details of the available API endpoints, including methods, parameters, and usage examples.
- Database Management: Strategies and practices for efficient management of the database used by the project.
- Testing Strategies: Approach and methods used to test the software, including unit, integration, and E2E tests.
- Testing Tools: Description of the testing tools used in the project and how to configure them.
- CI/CD Pipeline: Explanation of the continuous integration and delivery pipeline, detailing each stage and its function.
- Automations and Artifact Generation: Description of the automations incorporated into the CI/CD, including documentation generation and build artifacts.
- .gitignore, .editorconfig and project.properties: Utility of these files to maintain code consistency and quality.
- Maven Wrapper and application.properties.
- .env File and Travis CI Settings: Use of these files to configure the environment and CI integrations.
- Code Standards and Security: Guidelines for maintaining code quality and security.
- Monitoring and Logging Practices: Recommended techniques for monitoring and logging in the project.
- Licensing: Information about the rights and restrictions associated with the use of the software.
- Terms of Use: Information about the terms and conditions for using the software.
- Future Plans: Discussion on functionalities and improvements considered for future versions of the project.
- Improvement Proposals: Space for the community to suggest and debate improvements and innovations.
- External Links and References: Additional resources and external documentation relevant to the project.
- Security Policy: Details on the supported versions, reporting vulnerabilities, and general security practices.