From 8bdf916fda849ae76116587b800b1dad53e4b9bf Mon Sep 17 00:00:00 2001 From: TharmiganK Date: Tue, 5 Mar 2024 11:03:32 +0530 Subject: [PATCH 01/11] Fix overwriting the Host header --- .../api/client/actions/AbstractHTTPAction.java | 3 +++ .../stdlib/http/testutils/client/HttpClient.java | 15 +++++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/native/src/main/java/io/ballerina/stdlib/http/api/client/actions/AbstractHTTPAction.java b/native/src/main/java/io/ballerina/stdlib/http/api/client/actions/AbstractHTTPAction.java index b3c980957e..64bb9c8f0a 100644 --- a/native/src/main/java/io/ballerina/stdlib/http/api/client/actions/AbstractHTTPAction.java +++ b/native/src/main/java/io/ballerina/stdlib/http/api/client/actions/AbstractHTTPAction.java @@ -213,6 +213,9 @@ private static int getStartTime(BObject timestamp) { } private static void setHostHeader(String host, int port, HttpHeaders headers) { + if (headers.contains(HttpHeaderNames.HOST)) { + return; + } if (port == 80 || port == 443) { headers.set(HttpHeaderNames.HOST, host); } else { diff --git a/test-utils/src/main/java/io/ballerina/stdlib/http/testutils/client/HttpClient.java b/test-utils/src/main/java/io/ballerina/stdlib/http/testutils/client/HttpClient.java index ab3b218f69..4288ac9643 100644 --- a/test-utils/src/main/java/io/ballerina/stdlib/http/testutils/client/HttpClient.java +++ b/test-utils/src/main/java/io/ballerina/stdlib/http/testutils/client/HttpClient.java @@ -36,6 +36,7 @@ import io.netty.handler.codec.http.HttpHeaderValues; import io.netty.handler.codec.http.HttpMethod; import io.netty.handler.codec.http.HttpObjectAggregator; +import io.netty.handler.codec.http.HttpRequest; import io.netty.handler.codec.http.HttpResponseStatus; import io.netty.handler.codec.http.HttpVersion; import org.slf4j.Logger; @@ -100,7 +101,7 @@ private FullHttpResponse send(FullHttpRequest httpRequest) { this.responseHandler.setLatch(latch); this.responseHandler.setWaitForConnectionClosureLatch(this.waitForConnectionClosureLatch); - httpRequest.headers().set(HttpHeaderNames.HOST, host + ":" + port); + addHostHeader(httpRequest); this.connectedChannel.writeAndFlush(httpRequest); try { latch.await(); @@ -117,7 +118,7 @@ public List sendExpectContinueRequest(DefaultHttpRequest httpR this.responseHandler.setLatch(latch); this.responseHandler.setWaitForConnectionClosureLatch(this.waitForConnectionClosureLatch); - httpRequest.headers().set(HttpHeaderNames.HOST, host + ":" + port); + addHostHeader(httpRequest); httpRequest.headers().set(HttpHeaderNames.EXPECT, HttpHeaderValues.CONTINUE); this.connectedChannel.writeAndFlush(httpRequest); @@ -149,7 +150,7 @@ public LinkedList sendTwoInPipeline(FullHttpRequest httpReques this.responseHandler.setLatch(latch); this.responseHandler.setWaitForConnectionClosureLatch(this.waitForConnectionClosureLatch); - httpRequest.headers().set(HttpHeaderNames.HOST, host + ":" + port); + addHostHeader(httpRequest); this.connectedChannel.writeAndFlush(httpRequest.copy()); this.connectedChannel.writeAndFlush(httpRequest); @@ -161,6 +162,12 @@ public LinkedList sendTwoInPipeline(FullHttpRequest httpReques return this.responseHandler.getHttpFullResponses(); } + private void addHostHeader(HttpRequest httpRequest) { + if (!httpRequest.headers().contains(HttpHeaderNames.HOST)) { + httpRequest.headers().set(HttpHeaderNames.HOST, host + ":" + port); + } + } + /** * Send pipelined requests to the server. * @@ -236,7 +243,7 @@ public String sendMultiplePipelinedRequests(String path) { */ private FullHttpRequest getFullHttpRequest(String path, String requestId) { FullHttpRequest request = new DefaultFullHttpRequest(HttpVersion.HTTP_1_1, HttpMethod.GET, path); - request.headers().set(HttpHeaderNames.HOST, host + ":" + port); + addHostHeader(request); request.headers().set(HttpHeaderNames.CONNECTION, HttpHeaderValues.KEEP_ALIVE); request.headers().set("message-id", requestId); return request; From e2730b59295b05e78463f0296093ab4f158a21b9 Mon Sep 17 00:00:00 2001 From: TharmiganK Date: Tue, 5 Mar 2024 11:04:07 +0530 Subject: [PATCH 02/11] [Automated] Update the native jar versions --- ballerina/Ballerina.toml | 6 +++--- ballerina/CompilerPlugin.toml | 2 +- ballerina/Dependencies.toml | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/ballerina/Ballerina.toml b/ballerina/Ballerina.toml index 3e5e088a5a..e27e64ea79 100644 --- a/ballerina/Ballerina.toml +++ b/ballerina/Ballerina.toml @@ -1,7 +1,7 @@ [package] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" authors = ["Ballerina"] keywords = ["http", "network", "service", "listener", "client"] repository = "https://github.com/ballerina-platform/module-ballerina-http" @@ -16,8 +16,8 @@ graalvmCompatible = true [[platform.java17.dependency]] groupId = "io.ballerina.stdlib" artifactId = "http-native" -version = "2.10.7" -path = "../native/build/libs/http-native-2.10.7.jar" +version = "2.10.8" +path = "../native/build/libs/http-native-2.10.8-SNAPSHOT.jar" [[platform.java17.dependency]] groupId = "io.ballerina.stdlib" diff --git a/ballerina/CompilerPlugin.toml b/ballerina/CompilerPlugin.toml index d48d4d5249..d6586898cd 100644 --- a/ballerina/CompilerPlugin.toml +++ b/ballerina/CompilerPlugin.toml @@ -3,4 +3,4 @@ id = "http-compiler-plugin" class = "io.ballerina.stdlib.http.compiler.HttpCompilerPlugin" [[dependency]] -path = "../compiler-plugin/build/libs/http-compiler-plugin-2.10.7.jar" +path = "../compiler-plugin/build/libs/http-compiler-plugin-2.10.8-SNAPSHOT.jar" diff --git a/ballerina/Dependencies.toml b/ballerina/Dependencies.toml index b071ba7c4e..9bc6068fbe 100644 --- a/ballerina/Dependencies.toml +++ b/ballerina/Dependencies.toml @@ -25,7 +25,7 @@ modules = [ [[package]] org = "ballerina" name = "cache" -version = "3.7.0" +version = "3.7.1" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "jballerina.java"}, @@ -76,7 +76,7 @@ modules = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "auth"}, {org = "ballerina", name = "cache"}, @@ -283,7 +283,7 @@ modules = [ [[package]] org = "ballerina" name = "observe" -version = "1.2.0" +version = "1.2.2" dependencies = [ {org = "ballerina", name = "jballerina.java"} ] From b13d835312643e424450eb056a7f88c78b321986 Mon Sep 17 00:00:00 2001 From: TharmiganK Date: Tue, 5 Mar 2024 12:07:34 +0530 Subject: [PATCH 03/11] Add test cases --- .../tests/http_client_host_header_test.bal | 131 ++++++++++++++++++ .../tests/test_service_ports.bal | 3 + 2 files changed, 134 insertions(+) create mode 100644 ballerina-tests/http-client-tests/tests/http_client_host_header_test.bal diff --git a/ballerina-tests/http-client-tests/tests/http_client_host_header_test.bal b/ballerina-tests/http-client-tests/tests/http_client_host_header_test.bal new file mode 100644 index 0000000000..a81562d92d --- /dev/null +++ b/ballerina-tests/http-client-tests/tests/http_client_host_header_test.bal @@ -0,0 +1,131 @@ +// Copyright (c) 2024 WSO2 LLC. (http://www.wso2.org). +// +// WSO2 LLC. licenses this file to you under the Apache License, +// Version 2.0 (the "License"); you may not use this file except +// in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +import ballerina/http; +import ballerina/test; + +final http:Client http2ClientHost1 = check new("localhost:" + http2ClientHostHeaderTestPort.toString()); +final http:Client http2ClientHost2 = check new("localhost:" + httpClientHostHeaderTestPort.toString()); +final http:Client httpClientHost1 = check new("localhost:" + httpClientHostHeaderTestPort.toString(), httpVersion = http:HTTP_1_1); +final http:Client httpClientHost2 = check new("localhost:" + http2ClientHostHeaderTestPort.toString(), httpVersion = http:HTTP_1_1); + +service / on new http:Listener(http2ClientHostHeaderTestPort) { + + resource function 'default host(http:Request req) returns string|error { + return req.getHeader("Host"); + } +} + +service / on new http:Listener(httpClientHostHeaderTestPort, httpVersion = http:HTTP_1_1) { + + resource function 'default host(http:Request req) returns string|error { + return req.getHeader("Host"); + } +} + +@test:Config {} +function testHttpClientHostHeader1() returns error? { + string host = check httpClientHost1->/host; + test:assertEquals(host, "localhost:" + httpClientHostHeaderTestPort.toString()); + + host = check httpClientHost1->get("/host"); + test:assertEquals(host, "localhost:" + httpClientHostHeaderTestPort.toString()); + + host = check httpClientHost2->/host; + test:assertEquals(host, "localhost:" + http2ClientHostHeaderTestPort.toString()); + + host = check httpClientHost2->get("/host"); + test:assertEquals(host, "localhost:" + http2ClientHostHeaderTestPort.toString()); +} + +@test:Config {} +function testHttpClientHostHeader2() returns error? { + string host = check httpClientHost1->/host.get({"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check httpClientHost1->get("/host", {"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check httpClientHost2->/host.get({"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check httpClientHost2->get("/host", {"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); +} + +@test:Config {} +function testHttpClientHostHeader3() returns error? { + http:Request req = new; + req.setHeader("Host", "mock.com"); + string host = check httpClientHost1->/host.post(req); + test:assertEquals(host, "mock.com"); + + host = check httpClientHost1->post("/host", req, {"Host": "mock2.com"}); + test:assertEquals(host, "mock2.com"); + + host = check httpClientHost2->/host.post(req); + test:assertEquals(host, "mock2.com"); + + host = check httpClientHost2->post("/host", req, {"Host": "mock3.com"}); + test:assertEquals(host, "mock3.com"); +} + +@test:Config {} +function testHttp2ClientHostHeader1() returns error? { + string host = check http2ClientHost1->/host; + test:assertEquals(host, "localhost:" + http2ClientHostHeaderTestPort.toString()); + + host = check http2ClientHost1->get("/host"); + test:assertEquals(host, "localhost:" + http2ClientHostHeaderTestPort.toString()); + + host = check http2ClientHost2->/host; + test:assertEquals(host, "localhost:" + httpClientHostHeaderTestPort.toString()); + + host = check http2ClientHost2->get("/host"); + test:assertEquals(host, "localhost:" + httpClientHostHeaderTestPort.toString()); +} + +@test:Config {} +function testHttp2ClientHostHeader2() returns error? { + string host = check http2ClientHost1->/host.get({"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check http2ClientHost1->get("/host", {"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check http2ClientHost2->/host.get({"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); + + host = check http2ClientHost2->get("/host", {"Host": "mock.com"}); + test:assertEquals(host, "mock.com"); +} + +@test:Config {} +function testHttp2ClientHostHeader3() returns error? { + http:Request req = new; + req.setHeader("Host", "mock.com"); + string host = check http2ClientHost1->/host.post(req); + test:assertEquals(host, "mock.com"); + + host = check http2ClientHost1->post("/host", req, {"Host": "mock2.com"}); + test:assertEquals(host, "mock2.com"); + + host = check http2ClientHost2->/host.post(req); + test:assertEquals(host, "mock2.com"); + + host = check http2ClientHost2->post("/host", req, {"Host": "mock3.com"}); + test:assertEquals(host, "mock3.com"); +} diff --git a/ballerina-tests/http-client-tests/tests/test_service_ports.bal b/ballerina-tests/http-client-tests/tests/test_service_ports.bal index 2955ca91bb..ccf2e910fe 100644 --- a/ballerina-tests/http-client-tests/tests/test_service_ports.bal +++ b/ballerina-tests/http-client-tests/tests/test_service_ports.bal @@ -32,3 +32,6 @@ const int clientSchemeTestHttpsListenerTestPort = 9624; const int clientResourceMethodsTestPort = 9631; const int clientFormUrlEncodedTestPort = 9604; + +const int http2ClientHostHeaderTestPort = 9605; +const int httpClientHostHeaderTestPort = 9605; From 0449887c1031eb7217a563b588eb6bab21688179 Mon Sep 17 00:00:00 2001 From: TharmiganK Date: Tue, 5 Mar 2024 12:10:50 +0530 Subject: [PATCH 04/11] Update change log --- changelog.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/changelog.md b/changelog.md index 4d1e0b9b41..48566cc8ce 100644 --- a/changelog.md +++ b/changelog.md @@ -5,6 +5,12 @@ This file contains all the notable changes done to the Ballerina HTTP package th The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] + +### Added + +- [Make the `Host` header overridable](https://github.com/ballerina-platform/ballerina-library/issues/6133) + ## [2.10.7] - 2024-02-14 ### Fixed From abec3eba19d1d95a19646cd7a7c463c0c713406c Mon Sep 17 00:00:00 2001 From: TharmiganK Date: Tue, 5 Mar 2024 12:55:42 +0530 Subject: [PATCH 05/11] Change test ports --- ballerina-tests/http-client-tests/tests/test_service_ports.bal | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ballerina-tests/http-client-tests/tests/test_service_ports.bal b/ballerina-tests/http-client-tests/tests/test_service_ports.bal index ccf2e910fe..fce33b93e3 100644 --- a/ballerina-tests/http-client-tests/tests/test_service_ports.bal +++ b/ballerina-tests/http-client-tests/tests/test_service_ports.bal @@ -34,4 +34,4 @@ const int clientResourceMethodsTestPort = 9631; const int clientFormUrlEncodedTestPort = 9604; const int http2ClientHostHeaderTestPort = 9605; -const int httpClientHostHeaderTestPort = 9605; +const int httpClientHostHeaderTestPort = 9606; From 5a98fe16311d8648af0fbcce1abe0c04617627a4 Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Tue, 5 Mar 2024 10:59:02 +0000 Subject: [PATCH 06/11] [Automated] Update the native jar versions --- ballerina/Dependencies.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ballerina/Dependencies.toml b/ballerina/Dependencies.toml index 9bc6068fbe..924664b85d 100644 --- a/ballerina/Dependencies.toml +++ b/ballerina/Dependencies.toml @@ -25,7 +25,7 @@ modules = [ [[package]] org = "ballerina" name = "cache" -version = "3.7.1" +version = "3.7.0" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "jballerina.java"}, @@ -283,7 +283,7 @@ modules = [ [[package]] org = "ballerina" name = "observe" -version = "1.2.2" +version = "1.2.0" dependencies = [ {org = "ballerina", name = "jballerina.java"} ] From caa704eb599314d50e7bee94921f8f2446747830 Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Tue, 5 Mar 2024 11:29:14 +0000 Subject: [PATCH 07/11] [Automated] Update the native jar versions --- ballerina-tests/http-advanced-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-advanced-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-client-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-client-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-dispatching-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-dispatching-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-interceptor-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-interceptor-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-misc-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-misc-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-resiliency-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-resiliency-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-security-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-security-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-service-tests/Ballerina.toml | 6 +++--- ballerina-tests/http-service-tests/Dependencies.toml | 6 +++--- ballerina-tests/http-test-common/Ballerina.toml | 2 +- ballerina-tests/http-test-common/Dependencies.toml | 2 +- ballerina-tests/http2-tests/Ballerina.toml | 6 +++--- ballerina-tests/http2-tests/Dependencies.toml | 6 +++--- 20 files changed, 56 insertions(+), 56 deletions(-) diff --git a/ballerina-tests/http-advanced-tests/Ballerina.toml b/ballerina-tests/http-advanced-tests/Ballerina.toml index d05b212873..9e8157aeda 100644 --- a/ballerina-tests/http-advanced-tests/Ballerina.toml +++ b/ballerina-tests/http-advanced-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_advanced_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-advanced-tests/Dependencies.toml b/ballerina-tests/http-advanced-tests/Dependencies.toml index 8ce3788866..9d4bf12ebc 100644 --- a/ballerina-tests/http-advanced-tests/Dependencies.toml +++ b/ballerina-tests/http-advanced-tests/Dependencies.toml @@ -72,7 +72,7 @@ modules = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -105,7 +105,7 @@ modules = [ [[package]] org = "ballerina" name = "http_advanced_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "crypto"}, {org = "ballerina", name = "file"}, @@ -125,7 +125,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-client-tests/Ballerina.toml b/ballerina-tests/http-client-tests/Ballerina.toml index 1e2ade93ab..c30228db9e 100644 --- a/ballerina-tests/http-client-tests/Ballerina.toml +++ b/ballerina-tests/http-client-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_client_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-client-tests/Dependencies.toml b/ballerina-tests/http-client-tests/Dependencies.toml index f59f6a17d2..9d6c0aa7c0 100644 --- a/ballerina-tests/http-client-tests/Dependencies.toml +++ b/ballerina-tests/http-client-tests/Dependencies.toml @@ -69,7 +69,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -102,7 +102,7 @@ modules = [ [[package]] org = "ballerina" name = "http_client_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "http"}, @@ -121,7 +121,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-dispatching-tests/Ballerina.toml b/ballerina-tests/http-dispatching-tests/Ballerina.toml index c6d49935b5..40363e4d1b 100644 --- a/ballerina-tests/http-dispatching-tests/Ballerina.toml +++ b/ballerina-tests/http-dispatching-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_dispatching_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-dispatching-tests/Dependencies.toml b/ballerina-tests/http-dispatching-tests/Dependencies.toml index ce9ceb0d4e..2508d76f05 100644 --- a/ballerina-tests/http-dispatching-tests/Dependencies.toml +++ b/ballerina-tests/http-dispatching-tests/Dependencies.toml @@ -69,7 +69,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -102,7 +102,7 @@ modules = [ [[package]] org = "ballerina" name = "http_dispatching_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "http"}, @@ -124,7 +124,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-interceptor-tests/Ballerina.toml b/ballerina-tests/http-interceptor-tests/Ballerina.toml index f45dab869c..69f6b8aa9f 100644 --- a/ballerina-tests/http-interceptor-tests/Ballerina.toml +++ b/ballerina-tests/http-interceptor-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_interceptor_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-interceptor-tests/Dependencies.toml b/ballerina-tests/http-interceptor-tests/Dependencies.toml index 7d783f40c7..36b4e946bc 100644 --- a/ballerina-tests/http-interceptor-tests/Dependencies.toml +++ b/ballerina-tests/http-interceptor-tests/Dependencies.toml @@ -66,7 +66,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -99,7 +99,7 @@ modules = [ [[package]] org = "ballerina" name = "http_interceptor_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "http"}, {org = "ballerina", name = "http_test_common"}, @@ -115,7 +115,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-misc-tests/Ballerina.toml b/ballerina-tests/http-misc-tests/Ballerina.toml index 7417b68167..c063726352 100644 --- a/ballerina-tests/http-misc-tests/Ballerina.toml +++ b/ballerina-tests/http-misc-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_misc_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-misc-tests/Dependencies.toml b/ballerina-tests/http-misc-tests/Dependencies.toml index 785da1af67..4ca78719a0 100644 --- a/ballerina-tests/http-misc-tests/Dependencies.toml +++ b/ballerina-tests/http-misc-tests/Dependencies.toml @@ -66,7 +66,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -99,7 +99,7 @@ modules = [ [[package]] org = "ballerina" name = "http_misc_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "http"}, {org = "ballerina", name = "http_test_common"}, @@ -118,7 +118,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-resiliency-tests/Ballerina.toml b/ballerina-tests/http-resiliency-tests/Ballerina.toml index 3e8cbe907f..3a197dafdf 100644 --- a/ballerina-tests/http-resiliency-tests/Ballerina.toml +++ b/ballerina-tests/http-resiliency-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_resiliency_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-resiliency-tests/Dependencies.toml b/ballerina-tests/http-resiliency-tests/Dependencies.toml index 89695a1567..cf07df92b0 100644 --- a/ballerina-tests/http-resiliency-tests/Dependencies.toml +++ b/ballerina-tests/http-resiliency-tests/Dependencies.toml @@ -66,7 +66,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -99,7 +99,7 @@ modules = [ [[package]] org = "ballerina" name = "http_resiliency_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "http"}, {org = "ballerina", name = "http_test_common"}, @@ -116,7 +116,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-security-tests/Ballerina.toml b/ballerina-tests/http-security-tests/Ballerina.toml index 5612602016..dada9cc9c5 100644 --- a/ballerina-tests/http-security-tests/Ballerina.toml +++ b/ballerina-tests/http-security-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_security_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-security-tests/Dependencies.toml b/ballerina-tests/http-security-tests/Dependencies.toml index 11a49267a4..6312adafe4 100644 --- a/ballerina-tests/http-security-tests/Dependencies.toml +++ b/ballerina-tests/http-security-tests/Dependencies.toml @@ -69,7 +69,7 @@ dependencies = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -102,7 +102,7 @@ modules = [ [[package]] org = "ballerina" name = "http_security_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "auth"}, {org = "ballerina", name = "http"}, @@ -120,7 +120,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-service-tests/Ballerina.toml b/ballerina-tests/http-service-tests/Ballerina.toml index ac7da9f76f..0729085261 100644 --- a/ballerina-tests/http-service-tests/Ballerina.toml +++ b/ballerina-tests/http-service-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http_service_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http-service-tests/Dependencies.toml b/ballerina-tests/http-service-tests/Dependencies.toml index a65a07c799..b7e929b104 100644 --- a/ballerina-tests/http-service-tests/Dependencies.toml +++ b/ballerina-tests/http-service-tests/Dependencies.toml @@ -69,7 +69,7 @@ modules = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -102,7 +102,7 @@ modules = [ [[package]] org = "ballerina" name = "http_service_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "file"}, {org = "ballerina", name = "http"}, @@ -121,7 +121,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, diff --git a/ballerina-tests/http-test-common/Ballerina.toml b/ballerina-tests/http-test-common/Ballerina.toml index d6a0ffc7c4..13e730bcd5 100644 --- a/ballerina-tests/http-test-common/Ballerina.toml +++ b/ballerina-tests/http-test-common/Ballerina.toml @@ -1,4 +1,4 @@ [package] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" diff --git a/ballerina-tests/http-test-common/Dependencies.toml b/ballerina-tests/http-test-common/Dependencies.toml index 6e28d40f89..2f555ac451 100644 --- a/ballerina-tests/http-test-common/Dependencies.toml +++ b/ballerina-tests/http-test-common/Dependencies.toml @@ -10,7 +10,7 @@ distribution-version = "2201.8.0" [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "lang.string"}, {org = "ballerina", name = "mime"}, diff --git a/ballerina-tests/http2-tests/Ballerina.toml b/ballerina-tests/http2-tests/Ballerina.toml index 7fb6720376..8465187165 100644 --- a/ballerina-tests/http2-tests/Ballerina.toml +++ b/ballerina-tests/http2-tests/Ballerina.toml @@ -1,17 +1,17 @@ [package] org = "ballerina" name = "http2_tests" -version = "2.10.7" +version = "2.10.8" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.10.7" +version = "2.10.8" [platform.java17] graalvmCompatible = true [[platform.java17.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.10.7.jar" +path = "../../test-utils/build/libs/http-test-utils-2.10.8.jar" diff --git a/ballerina-tests/http2-tests/Dependencies.toml b/ballerina-tests/http2-tests/Dependencies.toml index b1eb5922a1..067e98aa46 100644 --- a/ballerina-tests/http2-tests/Dependencies.toml +++ b/ballerina-tests/http2-tests/Dependencies.toml @@ -69,7 +69,7 @@ modules = [ [[package]] org = "ballerina" name = "http" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -102,7 +102,7 @@ modules = [ [[package]] org = "ballerina" name = "http2_tests" -version = "2.10.7" +version = "2.10.8" dependencies = [ {org = "ballerina", name = "file"}, {org = "ballerina", name = "http"}, @@ -121,7 +121,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.10.7" +version = "2.10.8" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, From 5c6bf0ed87a405e517414aebd964c6cb478458b9 Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Tue, 5 Mar 2024 11:29:14 +0000 Subject: [PATCH 08/11] [Automated] Update the native jar versions --- ballerina/Ballerina.toml | 2 +- ballerina/CompilerPlugin.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ballerina/Ballerina.toml b/ballerina/Ballerina.toml index e27e64ea79..bf077c5d87 100644 --- a/ballerina/Ballerina.toml +++ b/ballerina/Ballerina.toml @@ -17,7 +17,7 @@ graalvmCompatible = true groupId = "io.ballerina.stdlib" artifactId = "http-native" version = "2.10.8" -path = "../native/build/libs/http-native-2.10.8-SNAPSHOT.jar" +path = "../native/build/libs/http-native-2.10.8.jar" [[platform.java17.dependency]] groupId = "io.ballerina.stdlib" diff --git a/ballerina/CompilerPlugin.toml b/ballerina/CompilerPlugin.toml index d6586898cd..3ac82bd2e9 100644 --- a/ballerina/CompilerPlugin.toml +++ b/ballerina/CompilerPlugin.toml @@ -3,4 +3,4 @@ id = "http-compiler-plugin" class = "io.ballerina.stdlib.http.compiler.HttpCompilerPlugin" [[dependency]] -path = "../compiler-plugin/build/libs/http-compiler-plugin-2.10.8-SNAPSHOT.jar" +path = "../compiler-plugin/build/libs/http-compiler-plugin-2.10.8.jar" From 0652d549ec77bf844aefaac370c9afc81b62e2ba Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Tue, 5 Mar 2024 11:29:15 +0000 Subject: [PATCH 09/11] [Gradle Release Plugin] - pre tag commit: 'v2.10.8'. --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 55117217c1..905145cfe3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,6 +1,6 @@ org.gradle.caching=true group=io.ballerina.stdlib -version=2.10.8-SNAPSHOT +version=2.10.8 ballerinaLangVersion=2201.8.0 ballerinaTomlParserVersion=1.2.2 commonsLang3Version=3.12.0 From 1adf05fb419dfc3ab9554f5ac56d09134b0cc402 Mon Sep 17 00:00:00 2001 From: ballerina-bot Date: Tue, 5 Mar 2024 11:29:16 +0000 Subject: [PATCH 10/11] [Gradle Release Plugin] - new version commit: 'v2.10.9-SNAPSHOT'. --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 905145cfe3..d7a09bf533 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,6 +1,6 @@ org.gradle.caching=true group=io.ballerina.stdlib -version=2.10.8 +version=2.10.9-SNAPSHOT ballerinaLangVersion=2201.8.0 ballerinaTomlParserVersion=1.2.2 commonsLang3Version=3.12.0 From 3456e8a82d1487141037345e3af1c221435bcf79 Mon Sep 17 00:00:00 2001 From: Krishnananthalingam Tharmigan <63336800+TharmiganK@users.noreply.github.com> Date: Tue, 5 Mar 2024 17:24:24 +0530 Subject: [PATCH 11/11] Update change log --- changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index 48566cc8ce..505e055d65 100644 --- a/changelog.md +++ b/changelog.md @@ -5,7 +5,7 @@ This file contains all the notable changes done to the Ballerina HTTP package th The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [Unreleased] +## [2.10.8] - 2024-03-05 ### Added