diff --git a/.codecov.yaml b/.codecov.yaml deleted file mode 100644 index 3516cd38a0..0000000000 --- a/.codecov.yaml +++ /dev/null @@ -1,5 +0,0 @@ - -# TODO Enable these modules once they are finished (remove this file) -ignore: - - port_store - - store_mongodb diff --git a/.github/issue_template.md b/.github/issue_template.md index 37f9bbf497..07a34f20ae 100644 --- a/.github/issue_template.md +++ b/.github/issue_template.md @@ -6,7 +6,7 @@ For an Improvement Detailed description. -Acceptance criteria: +Acceptance criteria. A list of requirements with the following format: * When *action* then *result* * When this is done then other thing should happen diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 9301a44a2b..c602852c2f 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -7,5 +7,8 @@ Please check: - If the PR refers to an issue, it should be referenced with the Github format (*#ID*). - The PR is done to the `develop` branch. - The code pass all PR checks. +- All public members are documented using Dokka. +- The code follow the Kotlin Coding Conventions. With the exception of final brace position in + `else`, `catch` and `finally` (in its own line). --> diff --git a/.travis.yml b/.travis.yml index 5169bbaded..4740b1fc75 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,7 +7,7 @@ language: java jdk: oraclejdk8 branches: - except: /^\d+.*$/ + except: [ /^\d+.*$/ ] env: global: @@ -34,9 +34,9 @@ services: - postgresql install: - - git remote set-url origin https://$GRGIT_USER:$GRGIT_PASS@github.com/hexagonkt/hexagon.git - - git pull origin develop - - git pull origin master +# - git remote set-url origin https://$GRGIT_USER:$GRGIT_PASS@github.com/hexagonkt/hexagon.git +# - git pull origin develop +# - git pull origin master - mongo hexagon_benchmark/mongodb.js - psql -U postgres -f hexagon_benchmark/postgresql.sql diff --git a/code_of_conduct.md b/code_of_conduct.md index 067fd079e2..7654a1b5f6 100644 --- a/code_of_conduct.md +++ b/code_of_conduct.md @@ -64,4 +64,4 @@ This Code of Conduct is adapted from the [Contributor Covenant][homepage], versi [http://contributor-covenant.org/version/1/4][version] [homepage]: http://contributor-covenant.org -[version]: http://contributor-covenant.org/version/1/4/ +[version]: http://contributor-covenant.org/version/1/4/code-of-conduct.html diff --git a/contributing.md b/contributing.md index 8215e64c94..a32266e558 100644 --- a/contributing.md +++ b/contributing.md @@ -39,28 +39,30 @@ You can define some useful aliases like: ```bash alias gw='./gradlew' -alias dcupd='docker-compose up -d' +alias dcup='docker-compose up -d' ``` It is recommended that you add: -`gw clean all publishToMavenLocal` to your `.git/hooks/pre-push` script. As this command will be -executed before pushing code to the repository (saving time fixing [Travis] build errors). +`gw --quiet --stacktrace clean all publishToMavenLocal` to your `.git/hooks/pre-push` script. As +this command will be executed before pushing code to the repository (saving time fixing [Travis] +build errors). If you want to commit to the project. It is convenient to setup your own [Travis] account to execute the CI job defined in `.travis.yml` when code is pushed to your fork. -Inside Idea IDE, you need to review Kotlin's settings to make sure JVM 1.8 and API 1.1 is used -(`Project Structure > Modules > > Kotlin > Target Platform`). +Inside [IntelliJ Idea IDE], you need to review Kotlin's settings to make sure the JVM version is +1.8+ and API one is 1.3+ (`Project Structure > Modules > > Kotlin > Target Platform`). ## Benchmarking -The benchmark are the same run inside [TechEmpower Framework Benchmarks][TFB], to run them: +The benchmark is the same that runs inside [TechEmpower Framework Benchmarks][TFB], to run it: 1. Start the benchmark's compose file. From the project's root execute: `docker-compose -f docker-compose.yaml -f hexagon_benchmark/docker-compose.yaml up -d` 2. Run `gw hexagon_benchmark:test -Phost=localhost -Pport=9020` where "localhost" and "9020" should - point to the endpoint with the benchmark application you want to test. + point to the endpoint with the benchmark instance you want to test. +[IntelliJ Idea IDE]: https://www.jetbrains.com/idea [TFB]: https://www.techempower.com/benchmarks ## Tools Used @@ -84,10 +86,12 @@ The benchmark are the same run inside [TechEmpower Framework Benchmarks][TFB], t * New features should be discussed within an issue in the issue tracker before actual coding. -* For code, file names, tags and branches use either camel case or snake case only. Ie: avoid `-` in - file names if it is possible. +* For code, file names, tags and branches use either camel case or snake case only. Ie: avoid `-` or + `.` in file names if it is possible. * For a Pull Request to be accepted: + - The PR should have a meaningful title. + - If the PR refers to an issue, it should be referenced with the Github format (*#ID*). - It should be done to the `develop` branch. - The code has to pass all PR checks. - All public methods and field must be documented using [Dokka](https://github.com/Kotlin/dokka). @@ -116,13 +120,23 @@ The benchmark are the same run inside [TechEmpower Framework Benchmarks][TFB], t Then something happened And I expected this other thing ``` + + If it is possible, add a link to the code that produced the error. And the stack trace if + available. + +* A feature requests: should have a detailed description and Acceptance criteria (a list of + requirements) with the following format: + + * When *action* then *result* + * When this is done then other thing should happen + [Quick Start]: http://hexagonkt.com/quick_start.html [Kotlin Coding Conventions]: https://kotlinlang.org/docs/reference/coding-conventions.html ## Tasks and Milestones Project's tasks and milestones are tracked in a [Github board]. You can use that board to check the -roadmap, vote the features you want (using [issue ractions]) or to pick tasks that you wish to +roadmap, vote the features you want (using [issue reactions]) or to pick tasks that you wish to contribute. [Github board]: https://github.com/hexagonkt/hexagon/projects/1 diff --git a/gradle.properties b/gradle.properties index 9636772859..64eb02b9d9 100644 --- a/gradle.properties +++ b/gradle.properties @@ -39,9 +39,6 @@ jacksonVersion=2.9.7 # hexagon_scheduler cronutilsVersion=7.0.6 -# hexagon_vertx -vertxVersion=3.5.4 - # messaging_rabbitmq rabbitVersion=5.5.0 qpidVersion=6.1.4 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index d76b502e22..0bd704f47e 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-5.0-rc-2-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/hexagon_benchmark/src/main/kotlin/Benchmark.kt b/hexagon_benchmark/src/main/kotlin/Benchmark.kt index cd901b27aa..841e417733 100644 --- a/hexagon_benchmark/src/main/kotlin/Benchmark.kt +++ b/hexagon_benchmark/src/main/kotlin/Benchmark.kt @@ -123,7 +123,7 @@ internal fun createEngine(engine: String): ServerPort = when (engine) { else -> error("Unsupported server engine") } -fun main(vararg args: String) { +fun main() { val engine = createEngine(Environment.systemSetting("WEBENGINE", "jetty")) benchmarkStores = storageEngines.map { it to createStore(it) }.toMap() diff --git a/hexagon_starters/hexagon-service/src/main/kotlin/Service.kt b/hexagon_starters/hexagon-service/src/main/kotlin/Service.kt index f701693919..4ec7521164 100644 --- a/hexagon_starters/hexagon-service/src/main/kotlin/Service.kt +++ b/hexagon_starters/hexagon-service/src/main/kotlin/Service.kt @@ -19,7 +19,7 @@ val server: Server = server(JettyServletAdapter(), SettingsManager.settings) { /** * Start the service from the command line. */ -fun main(vararg args: String) { +fun main() { server.run() } diff --git a/hexagon_starters/src/main/kotlin/Service.kt b/hexagon_starters/src/main/kotlin/Service.kt index 06912293a6..3c72b4b08c 100644 --- a/hexagon_starters/src/main/kotlin/Service.kt +++ b/hexagon_starters/src/main/kotlin/Service.kt @@ -18,7 +18,7 @@ val server: Server = server(JettyServletAdapter(), SettingsManager.settings) { /** * Start the service from the command line. */ -fun main(vararg args: String) { +fun main() { server.run() } diff --git a/readme.md b/readme.md index f044ba71b6..98ffb9d72f 100644 --- a/readme.md +++ b/readme.md @@ -95,7 +95,7 @@ What are NOT project goals: ```kotlin import com.hexagonkt.server.jetty.serve - fun main(vararg args: String) { + fun main() { serve { get("/hello/{name}") { "Hello ${request["name"]}!" } } diff --git a/settings.gradle b/settings.gradle index 96889e7c4b..1c9c8f40ee 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,6 +1,4 @@ -enableFeaturePreview 'STABLE_PUBLISHING' // TODO Remove when this feature becomes enabled by default - rootProject.name = name include (