diff --git a/ballerina-tests/http-advanced-tests/Ballerina.toml b/ballerina-tests/http-advanced-tests/Ballerina.toml index b26d857fd3..6bf7c030e7 100644 --- a/ballerina-tests/http-advanced-tests/Ballerina.toml +++ b/ballerina-tests/http-advanced-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_advanced_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-advanced-tests/Dependencies.toml b/ballerina-tests/http-advanced-tests/Dependencies.toml index 074a72d3fd..24f4f752eb 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -104,7 +104,7 @@ modules = [ [[package]] org = "ballerina" name = "http_advanced_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "crypto"}, {org = "ballerina", name = "file"}, @@ -124,7 +124,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -311,7 +311,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -321,7 +321,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -343,7 +343,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-client-tests/Ballerina.toml b/ballerina-tests/http-client-tests/Ballerina.toml index 65f28857f1..5dfd5ae208 100644 --- a/ballerina-tests/http-client-tests/Ballerina.toml +++ b/ballerina-tests/http-client-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_client_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-client-tests/Dependencies.toml b/ballerina-tests/http-client-tests/Dependencies.toml index 81c6689ab7..1e13040a67 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -101,7 +101,7 @@ modules = [ [[package]] org = "ballerina" name = "http_client_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "http"}, @@ -120,7 +120,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -307,7 +307,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -317,7 +317,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -339,7 +339,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-dispatching-tests/Ballerina.toml b/ballerina-tests/http-dispatching-tests/Ballerina.toml index 17404bbb1b..b649038281 100644 --- a/ballerina-tests/http-dispatching-tests/Ballerina.toml +++ b/ballerina-tests/http-dispatching-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_dispatching_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-dispatching-tests/Dependencies.toml b/ballerina-tests/http-dispatching-tests/Dependencies.toml index 2a1fbcf817..93113af52f 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -101,7 +101,7 @@ modules = [ [[package]] org = "ballerina" name = "http_dispatching_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "constraint"}, {org = "ballerina", name = "http"}, @@ -123,7 +123,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -346,7 +346,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -356,7 +356,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -378,7 +378,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-dispatching-tests/tests/header_params_binding_test.bal b/ballerina-tests/http-dispatching-tests/tests/header_params_binding_test.bal index dd6f3ad547..f4984515e9 100644 --- a/ballerina-tests/http-dispatching-tests/tests/header_params_binding_test.bal +++ b/ballerina-tests/http-dispatching-tests/tests/header_params_binding_test.bal @@ -121,3 +121,66 @@ function testHeaderParamBindingCase9() returns error? { http:Response res = check resourceHeaderParamBindingClient->/header/case9(headers); test:assertEquals(res.statusCode, 400); } + +@test:Config {} +function testHeaderParamBindingCase10() returns error? { + int:Signed32 resPayload = check resourceHeaderParamBindingClient->/header/case10({header: "32"}); + test:assertEquals(resPayload, 32); + + resPayload = check resourceHeaderParamBindingClient->/header/case10({header: "-32"}); + test:assertEquals(resPayload, -32); + + http:Response res = check resourceHeaderParamBindingClient->/header/case10({header: "5000000000"}); + test:assertEquals(res.statusCode, 400); +} + +@test:Config {} +function testHeaderParamBindingCase11() returns error? { + int:Unsigned32 resPayload = check resourceHeaderParamBindingClient->/header/case11({header: "32"}); + test:assertEquals(resPayload, 32); + + http:Response res = check resourceHeaderParamBindingClient->/header/case11({header: "-32"}); + test:assertEquals(res.statusCode, 400); + + res = check resourceHeaderParamBindingClient->/header/case11({header: "5000000000"}); + test:assertEquals(res.statusCode, 400); +} + +@test:Config {} +function testHeaderParamBindingCase12() returns error? { + int:Signed8[] resPayload = check resourceHeaderParamBindingClient->/header/case12({header: ["32", "-38", "1", "-43"]}); + test:assertEquals(resPayload, [32, -38, 1, -43]); + + http:Response res = check resourceHeaderParamBindingClient->/header/case12({header: ["32", "-38", "1", "-43", "-50000000"]}); + test:assertEquals(res.statusCode, 400); +} + +@test:Config {} +function testHeaderParamBindingCase13() returns error? { + string:Char resPayload = check resourceHeaderParamBindingClient->/header/case13({header: "a"}); + test:assertEquals(resPayload, "a"); + + resPayload = check resourceHeaderParamBindingClient->/header/case13({header: "*"}); + test:assertEquals(resPayload, "*"); + + http:Response res = check resourceHeaderParamBindingClient->/header/case13({header: "ab"}); + test:assertEquals(res.statusCode, 400); +} + +@test:Config {} +function testHeaderParamBindingCase14() returns error? { + [StringCharacter, SmallInt] resPayload = check resourceHeaderParamBindingClient->/header/case14({header1: "a", header2: "32"}); + test:assertEquals(resPayload, ["a", 32]); + + resPayload = check resourceHeaderParamBindingClient->/header/case14({header1: "*", header2: "-32"}); + test:assertEquals(resPayload, ["*", -32]); + + http:Response res = check resourceHeaderParamBindingClient->/header/case14({header1: "ab", header2: "32"}); + test:assertEquals(res.statusCode, 400); + + res = check resourceHeaderParamBindingClient->/header/case14({header1: "a", header2: "5000000000"}); + test:assertEquals(res.statusCode, 400); + + res = check resourceHeaderParamBindingClient->/header/case14({header1: "ab", header2: "5000000000"}); + test:assertEquals(res.statusCode, 400); +} diff --git a/ballerina-tests/http-dispatching-tests/tests/path_params_binding_test.bal b/ballerina-tests/http-dispatching-tests/tests/path_params_binding_test.bal index 3d1b809f58..8e04b4e2a4 100644 --- a/ballerina-tests/http-dispatching-tests/tests/path_params_binding_test.bal +++ b/ballerina-tests/http-dispatching-tests/tests/path_params_binding_test.bal @@ -17,6 +17,7 @@ import ballerina/test; import ballerina/http; import ballerina/http_test_common as common; +import ballerina/url; final http:Client resourcePathParamBindingClient = check new("http://localhost:" + resourceParamBindingTestPort.toString()); @@ -145,3 +146,69 @@ function testPathParamBindingCase10() returns error? { http:Response res = check resourcePathParamBindingClient->/path/case10/value1/value9/value3; test:assertEquals(res.statusCode, 404, "Status code mismatched"); } + +@test:Config {} +function testPathParamBindingCase11() returns error? { + int:Signed32 resPayload = check resourcePathParamBindingClient->/path/case11/'32; + test:assertEquals(resPayload, 32, "Payload mismatched"); + + resPayload = check resourcePathParamBindingClient->/path/case11/\-32; + test:assertEquals(resPayload, -32, "Payload mismatched"); + + http:Response res = check resourcePathParamBindingClient->/path/case11/'5000000000; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testPathParamBindingCase12() returns error? { + int:Unsigned32 resPayload = check resourcePathParamBindingClient->/path/case12/'32; + test:assertEquals(resPayload, 32, "Payload mismatched"); + + http:Response res = check resourcePathParamBindingClient->/path/case12/\-32; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourcePathParamBindingClient->/path/case12/'5000000000; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testPathParamBindingCase13() returns error? { + int:Signed8[] resPayload = check resourcePathParamBindingClient->/path/case13/'32/\-38/'1/\-43; + test:assertEquals(resPayload, [32, -38, 1, -43], "Payload mismatched"); + + http:Response res = check resourcePathParamBindingClient->/path/case13/'32/\-38/'1/\-43/'5000000000; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testPathParamBindingCase14() returns error? { + string:Char resPayload = check resourcePathParamBindingClient->/path/case14/a; + test:assertEquals(resPayload, "a", "Payload mismatched"); + + resPayload = check resourcePathParamBindingClient->/path/case14/[check url:encode("*", "UTF-8")]; + test:assertEquals(resPayload, "*", "Payload mismatched"); + + resPayload = check resourcePathParamBindingClient->/path/case14/[check url:encode(" ", "UTF-8")]; + test:assertEquals(resPayload, " ", "Payload mismatched"); + + http:Response res = check resourcePathParamBindingClient->/path/case14/abc; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testPathParamBindingCase15() returns error? { + [StringCharacter, SmallInt] resPayload = check resourcePathParamBindingClient->/path/case15/[check url:encode("*", "UTF-8")]/'34; + test:assertEquals(resPayload, ["*", 34], "Payload mismatched"); + + resPayload = check resourcePathParamBindingClient->/path/case15/[check url:encode(" ", "UTF-8")]/\-34; + test:assertEquals(resPayload, [" ", -34], "Payload mismatched"); + + http:Response res = check resourcePathParamBindingClient->/path/case15/a/'5000000; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourcePathParamBindingClient->/path/case15/ab/'32; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourcePathParamBindingClient->/path/case15/abc/'5000000; + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} diff --git a/ballerina-tests/http-dispatching-tests/tests/query_params_binding_test.bal b/ballerina-tests/http-dispatching-tests/tests/query_params_binding_test.bal index ee43cbcf02..03c72a9a30 100644 --- a/ballerina-tests/http-dispatching-tests/tests/query_params_binding_test.bal +++ b/ballerina-tests/http-dispatching-tests/tests/query_params_binding_test.bal @@ -152,3 +152,68 @@ function testQueryParamBindingCase10() returns error? { test:assertEquals(res.statusCode, 400, "Status code mismatched"); } +@test:Config {} +function testQueryParamBindingCase11() returns error? { + int:Signed32 resPayload = check resourceQueryParamBindingClient->/query/case11(query = 32); + test:assertEquals(resPayload, 32, "Payload mismatched"); + + resPayload = check resourceQueryParamBindingClient->/query/case11(query = -32); + test:assertEquals(resPayload, -32, "Payload mismatched"); + + http:Response res = check resourceQueryParamBindingClient->/query/case11(query = 5000000000); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testQueryParamBindingCase12() returns error? { + int:Unsigned32 resPayload = check resourceQueryParamBindingClient->/query/case12(query = 32); + test:assertEquals(resPayload, 32, "Payload mismatched"); + + http:Response res = check resourceQueryParamBindingClient->/query/case12(query = -32); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourceQueryParamBindingClient->/query/case12(query = 5000000000); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testQueryParamBindingCase13() returns error? { + int:Signed8[] resPayload = check resourceQueryParamBindingClient->/query/case13(query = [32, -38, 1, -43]); + test:assertEquals(resPayload, [32, -38, 1, -43], "Payload mismatched"); + + http:Response res = check resourceQueryParamBindingClient->/query/case13(query = [32, -38, 1, -43, 50000000]); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testQueryParamBindingCase14() returns error? { + string:Char resPayload = check resourceQueryParamBindingClient->/query/case14(query = "a"); + test:assertEquals(resPayload, "a", "Payload mismatched"); + + resPayload = check resourceQueryParamBindingClient->/query/case14(query = "*"); + test:assertEquals(resPayload, "*", "Payload mismatched"); + + resPayload = check resourceQueryParamBindingClient->/query/case14(query = "."); + test:assertEquals(resPayload, ".", "Payload mismatched"); + + http:Response res = check resourceQueryParamBindingClient->/query/case14(query = "ab"); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} + +@test:Config {} +function testQueryParamBindingCase15() returns error? { + [StringCharacter, SmallInt] resPayload = check resourceQueryParamBindingClient->/query/case15(query1 = "*", query2 = 34); + test:assertEquals(resPayload, ["*", 34], "Payload mismatched"); + + resPayload = check resourceQueryParamBindingClient->/query/case15(query1 = " ", query2 = -34); + test:assertEquals(resPayload, [" ", -34], "Payload mismatched"); + + http:Response res = check resourceQueryParamBindingClient->/query/case15(query1 = "ab", query2 = 34); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourceQueryParamBindingClient->/query/case15(query1 = "*", query2 = 500000); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); + + res = check resourceQueryParamBindingClient->/query/case15(query1 = "abc", query2 = 500000); + test:assertEquals(res.statusCode, 400, "Status code mismatched"); +} diff --git a/ballerina-tests/http-dispatching-tests/tests/resource_params_binding_test_common.bal b/ballerina-tests/http-dispatching-tests/tests/resource_params_binding_test_common.bal index d254a6f801..20579dd415 100644 --- a/ballerina-tests/http-dispatching-tests/tests/resource_params_binding_test_common.bal +++ b/ballerina-tests/http-dispatching-tests/tests/resource_params_binding_test_common.bal @@ -44,6 +44,9 @@ type QueryRecord record {| type QueryRecordCombined QueryRecord|map; +type StringCharacter string:Char; +type SmallInt int:Signed8; + listener http:Listener resourceParamBindingListener = new(resourceParamBindingTestPort); service /path on resourceParamBindingListener { @@ -104,6 +107,26 @@ service /path on resourceParamBindingListener { } return result; } + + resource function get case11/[int:Signed32 path]() returns int:Signed32 { + return path; + } + + resource function get case12/[int:Unsigned32 path]() returns int:Unsigned32 { + return path; + } + + resource function get case13/[int:Signed8... path]() returns int:Signed8[] { + return path; + } + + resource function get case14/[string:Char path]() returns string:Char { + return path; + } + + resource function get case15/[StringCharacter path1]/[SmallInt path2]() returns [StringCharacter, SmallInt] { + return [path1, path2]; + } } service /query on resourceParamBindingListener { @@ -176,6 +199,26 @@ service /query on resourceParamBindingListener { } return result; } + + resource function get case11(int:Signed32 query) returns int:Signed32 { + return query; + } + + resource function get case12(int:Unsigned32 query) returns int:Unsigned32 { + return query; + } + + resource function get case13(int:Signed8[] query) returns int:Signed8[] { + return query; + } + + resource function get case14(string:Char query) returns string:Char { + return query; + } + + resource function get case15(StringCharacter query1, SmallInt query2) returns [StringCharacter, SmallInt] { + return [query1, query2]; + } } service /header on resourceParamBindingListener { @@ -226,5 +269,25 @@ service /header on resourceParamBindingListener { resource function get case9(@http:Header HeaderRecord? header) returns map|string { return header ?: "default"; } + + resource function get case10(@http:Header int:Signed32 header) returns int:Signed32 { + return header; + } + + resource function get case11(@http:Header int:Unsigned32 header) returns int:Unsigned32 { + return header; + } + + resource function get case12(@http:Header int:Signed8[] header) returns int:Signed8[] { + return header; + } + + resource function get case13(@http:Header string:Char header) returns string:Char { + return header; + } + + resource function get case14(@http:Header StringCharacter header1, @http:Header SmallInt header2) returns [StringCharacter, SmallInt] { + return [header1, header2]; + } } diff --git a/ballerina-tests/http-interceptor-tests/Ballerina.toml b/ballerina-tests/http-interceptor-tests/Ballerina.toml index 84ea138b12..422a000ade 100644 --- a/ballerina-tests/http-interceptor-tests/Ballerina.toml +++ b/ballerina-tests/http-interceptor-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_interceptor_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-interceptor-tests/Dependencies.toml b/ballerina-tests/http-interceptor-tests/Dependencies.toml index 36ad473fad..54b786e5fe 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -98,7 +98,7 @@ modules = [ [[package]] org = "ballerina" name = "http_interceptor_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "http"}, {org = "ballerina", name = "http_test_common"}, @@ -114,7 +114,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -298,7 +298,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -308,7 +308,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -330,7 +330,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-misc-tests/Ballerina.toml b/ballerina-tests/http-misc-tests/Ballerina.toml index 6ce7ea2acf..0abc2361ef 100644 --- a/ballerina-tests/http-misc-tests/Ballerina.toml +++ b/ballerina-tests/http-misc-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_misc_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-misc-tests/Dependencies.toml b/ballerina-tests/http-misc-tests/Dependencies.toml index 097f469c29..e8316b368d 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -98,7 +98,7 @@ modules = [ [[package]] org = "ballerina" name = "http_misc_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "http"}, {org = "ballerina", name = "http_test_common"}, @@ -117,7 +117,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -307,7 +307,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -317,7 +317,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -339,7 +339,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-resiliency-tests/Ballerina.toml b/ballerina-tests/http-resiliency-tests/Ballerina.toml index 8941d5510f..54e4a7a482 100644 --- a/ballerina-tests/http-resiliency-tests/Ballerina.toml +++ b/ballerina-tests/http-resiliency-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_resiliency_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-resiliency-tests/Dependencies.toml b/ballerina-tests/http-resiliency-tests/Dependencies.toml index 617ad69689..8e809dbdd1 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -98,7 +98,7 @@ modules = [ [[package]] org = "ballerina" name = "http_resiliency_tests" -version = "2.8.0" +version = "2.8.1" 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -302,7 +302,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -312,7 +312,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -334,7 +334,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-security-tests/Ballerina.toml b/ballerina-tests/http-security-tests/Ballerina.toml index 5ead72f61f..f8f6db7f91 100644 --- a/ballerina-tests/http-security-tests/Ballerina.toml +++ b/ballerina-tests/http-security-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_security_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-security-tests/Dependencies.toml b/ballerina-tests/http-security-tests/Dependencies.toml index a6df3e3f95..9c6a11012f 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -101,7 +101,7 @@ modules = [ [[package]] org = "ballerina" name = "http_security_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "auth"}, {org = "ballerina", name = "http"}, @@ -119,7 +119,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -303,7 +303,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -313,7 +313,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -335,7 +335,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-security-tests/tests/http2_mutual_ssl_test.bal b/ballerina-tests/http-security-tests/tests/http2_mutual_ssl_test.bal index 3fd1fd647c..7511b0f5e7 100644 --- a/ballerina-tests/http-security-tests/tests/http2_mutual_ssl_test.bal +++ b/ballerina-tests/http-security-tests/tests/http2_mutual_ssl_test.bal @@ -159,7 +159,8 @@ public function testHttp2MutualSsl4() returns error? { // Without keys - negative test http:Client httpClient = check new ("https://localhost:9204", http2MutualSslClientConf4); http:Response|error resp = httpClient->get("/http2Service/"); - string expectedErrMsg = "SSL connection failed:javax.net.ssl.SSLHandshakeException: error:10000410:SSL routines:OPENSSL_internal:SSLV3_ALERT_HANDSHAKE_FAILURE localhost/127.0.0.1:9204"; + string expectedErrMsg = "SSL connection failed:io.netty.handler.ssl.ReferenceCountedOpenSslEngine$OpenSslHandshakeException" + + ": error:10000410:SSL routines:OPENSSL_internal:SSLV3_ALERT_HANDSHAKE_FAILURE localhost/127.0.0.1:9204"; if resp is error { test:assertEquals(resp.message(), expectedErrMsg); } else { diff --git a/ballerina-tests/http-service-tests/Ballerina.toml b/ballerina-tests/http-service-tests/Ballerina.toml index dfab002360..6227920e3e 100644 --- a/ballerina-tests/http-service-tests/Ballerina.toml +++ b/ballerina-tests/http-service-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http_service_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http-service-tests/Dependencies.toml b/ballerina-tests/http-service-tests/Dependencies.toml index 93be49cc1e..f039c352fd 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -101,7 +101,7 @@ modules = [ [[package]] org = "ballerina" name = "http_service_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "file"}, {org = "ballerina", name = "http"}, @@ -120,7 +120,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -307,7 +307,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -317,7 +317,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -339,7 +339,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina-tests/http-test-common/Ballerina.toml b/ballerina-tests/http-test-common/Ballerina.toml index 2d6da8b84b..d2f4a12b7e 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.8.0" +version = "2.8.1" diff --git a/ballerina-tests/http-test-common/Dependencies.toml b/ballerina-tests/http-test-common/Dependencies.toml index a8b0a6393c..e35fa67bf0 100644 --- a/ballerina-tests/http-test-common/Dependencies.toml +++ b/ballerina-tests/http-test-common/Dependencies.toml @@ -10,7 +10,7 @@ distribution-version = "2201.5.0" [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" 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 b8f367eba2..23fce5d3f2 100644 --- a/ballerina-tests/http2-tests/Ballerina.toml +++ b/ballerina-tests/http2-tests/Ballerina.toml @@ -1,14 +1,14 @@ [package] org = "ballerina" name = "http2_tests" -version = "2.8.0" +version = "2.8.1" [[dependency]] org = "ballerina" name = "http_test_common" repository = "local" -version = "2.8.0" +version = "2.8.1" [[platform.java11.dependency]] scope = "testOnly" -path = "../../test-utils/build/libs/http-test-utils-2.8.0.jar" +path = "../../test-utils/build/libs/http-test-utils-2.8.1-SNAPSHOT.jar" diff --git a/ballerina-tests/http2-tests/Dependencies.toml b/ballerina-tests/http2-tests/Dependencies.toml index 165b339fb5..f3fd0c7e04 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.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "auth"}, @@ -101,7 +101,7 @@ modules = [ [[package]] org = "ballerina" name = "http2_tests" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "file"}, {org = "ballerina", name = "http"}, @@ -120,7 +120,7 @@ modules = [ [[package]] org = "ballerina" name = "http_test_common" -version = "2.8.0" +version = "2.8.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "lang.string"}, @@ -307,7 +307,7 @@ dependencies = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" scope = "testOnly" dependencies = [ {org = "ballerina", name = "io"}, @@ -317,7 +317,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"}, @@ -339,7 +339,7 @@ modules = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" scope = "testOnly" dependencies = [ {org = "ballerina", name = "jballerina.java"} diff --git a/ballerina/Ballerina.toml b/ballerina/Ballerina.toml index 2bd835179f..4f7903cedb 100644 --- a/ballerina/Ballerina.toml +++ b/ballerina/Ballerina.toml @@ -1,7 +1,7 @@ [package] org = "ballerina" name = "http" -version = "2.8.0" +version = "2.8.1" authors = ["Ballerina"] keywords = ["http", "network", "service", "listener", "client"] repository = "https://github.com/ballerina-platform/module-ballerina-http" @@ -12,8 +12,8 @@ distribution = "2201.5.0" [[platform.java11.dependency]] groupId = "io.ballerina.stdlib" artifactId = "http-native" -version = "2.8.0" -path = "../native/build/libs/http-native-2.8.0.jar" +version = "2.8.1" +path = "../native/build/libs/http-native-2.8.1-SNAPSHOT.jar" [[platform.java11.dependency]] groupId = "io.ballerina.stdlib" @@ -30,56 +30,56 @@ path = "./lib/constraint-native-1.2.0.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-common" -version = "4.1.86.Final" -path = "./lib/netty-common-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-common-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-buffer" -version = "4.1.86.Final" -path = "./lib/netty-buffer-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-buffer-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-transport" -version = "4.1.86.Final" -path = "./lib/netty-transport-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-transport-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-resolver" -version = "4.1.86.Final" -path = "./lib/netty-resolver-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-resolver-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-handler" -version = "4.1.86.Final" -path = "./lib/netty-handler-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-handler-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-codec-http" -version = "4.1.86.Final" -path = "./lib/netty-codec-http-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-codec-http-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-codec" -version = "4.1.86.Final" -path = "./lib/netty-codec-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-codec-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-handler-proxy" -version = "4.1.86.Final" -path = "./lib/netty-handler-proxy-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-handler-proxy-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-codec-http2" -version = "4.1.86.Final" -path = "./lib/netty-codec-http2-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-codec-http2-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "commons-pool.wso2" @@ -90,8 +90,8 @@ path = "./lib/commons-pool-1.5.6.wso2v1.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-transport-native-unix-common" -version = "4.1.86.Final" -path = "./lib/netty-transport-native-unix-common-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-transport-native-unix-common-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "org.bouncycastle" @@ -108,29 +108,29 @@ path = "./lib/bcpkix-jdk15on-1.69.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-tcnative-boringssl-static" -version = "2.0.54.Final" -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final.jar" +version = "2.0.61.Final" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final.jar" [[platform.java11.dependency]] -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final-windows-x86_64.jar" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final-windows-x86_64.jar" [[platform.java11.dependency]] -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final-linux-aarch_64.jar" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final-linux-aarch_64.jar" [[platform.java11.dependency]] -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final-linux-x86_64.jar" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final-linux-x86_64.jar" [[platform.java11.dependency]] -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final-osx-aarch_64.jar" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final-osx-aarch_64.jar" [[platform.java11.dependency]] -path = "./lib/netty-tcnative-boringssl-static-2.0.54.Final-osx-x86_64.jar" +path = "./lib/netty-tcnative-boringssl-static-2.0.61.Final-osx-x86_64.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-tcnative-classes" -version = "2.0.54.Final" -path = "./lib/netty-tcnative-classes-2.0.54.Final.jar" +version = "2.0.61.Final" +path = "./lib/netty-tcnative-classes-2.0.61.Final.jar" [[platform.java11.dependency]] groupId = "org.jvnet.mimepull" @@ -141,8 +141,8 @@ path = "./lib/mimepull-1.9.11.jar" [[platform.java11.dependency]] groupId = "io.netty" artifactId = "netty-codec-socks" -version = "4.1.86.Final" -path = "./lib/netty-codec-socks-4.1.86.Final.jar" +version = "4.1.94.Final" +path = "./lib/netty-codec-socks-4.1.94.Final.jar" [[platform.java11.dependency]] groupId = "org.jboss.marshalling" diff --git a/ballerina/CompilerPlugin.toml b/ballerina/CompilerPlugin.toml index 1b64b5b017..e3c875d63b 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.8.0.jar" +path = "../compiler-plugin/build/libs/http-compiler-plugin-2.8.1-SNAPSHOT.jar" diff --git a/ballerina/Dependencies.toml b/ballerina/Dependencies.toml index 609ad360eb..3a18d92da0 100644 --- a/ballerina/Dependencies.toml +++ b/ballerina/Dependencies.toml @@ -76,7 +76,7 @@ modules = [ [[package]] org = "ballerina" name = "http" -version = "2.8.0" +version = "2.8.1" dependencies = [ {org = "ballerina", name = "auth"}, {org = "ballerina", name = "cache"}, @@ -294,7 +294,7 @@ modules = [ [[package]] org = "ballerina" name = "os" -version = "1.6.0" +version = "1.6.1" dependencies = [ {org = "ballerina", name = "io"}, {org = "ballerina", name = "jballerina.java"} @@ -303,7 +303,7 @@ dependencies = [ [[package]] org = "ballerina" name = "task" -version = "2.3.2" +version = "2.3.3" dependencies = [ {org = "ballerina", name = "jballerina.java"}, {org = "ballerina", name = "time"} @@ -312,7 +312,7 @@ dependencies = [ [[package]] org = "ballerina" name = "time" -version = "2.2.4" +version = "2.2.5" dependencies = [ {org = "ballerina", name = "jballerina.java"} ] @@ -323,7 +323,7 @@ modules = [ [[package]] org = "ballerina" name = "url" -version = "2.2.3" +version = "2.2.4" dependencies = [ {org = "ballerina", name = "jballerina.java"} ] diff --git a/changelog.md b/changelog.md index ad17d62ddd..08f09dd999 100644 --- a/changelog.md +++ b/changelog.md @@ -5,7 +5,19 @@ 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.8.0] - 2023-06-01 + +### Added + +- [Add query,header and path parameter runtime support for Ballerina builtin types](https://github.com/ballerina-platform/ballerina-standard-library/issues/4526) + +## [2.8.0] - 2023-06-01 + +### Fixed + +- [Address CVE-2023-34462 netty Vulnerability](https://github.com/ballerina-platform/ballerina-standard-library/issues/4599) + +## [2.8.0] - 2023-06-01 ### Added diff --git a/gradle.properties b/gradle.properties index 8079657e43..fc0648b703 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,11 +1,11 @@ org.gradle.caching=true group=io.ballerina.stdlib -version=2.8.0 +version=2.8.1-SNAPSHOT ballerinaLangVersion=2201.5.0 ballerinaTomlParserVersion=1.2.2 commonsLang3Version=3.8.1 -nettyVersion=4.1.86.Final -nettyTcnativeVersion=2.0.54.Final +nettyVersion=4.1.94.Final +nettyTcnativeVersion=2.0.61.Final bouncycastleVersion=1.69 slf4jVersion=1.7.30 jakartaXmlBindVersion=2.3.3 diff --git a/load-tests/h1_h1_passthrough/results/summary.csv b/load-tests/h1_h1_passthrough/results/summary.csv index cb5422e4f8..6922f78f0a 100644 --- a/load-tests/h1_h1_passthrough/results/summary.csv +++ b/load-tests/h1_h1_passthrough/results/summary.csv @@ -325,3 +325,5 @@ HTTP Request,9586725,19,13,42,57,99,0,744,0.00%,2754.8,661.8,20.51,1685297679,50 HTTP Request,9348074,20,14,43,59,101,0,818,0.00%,2686.3,645.3,20.83,1685384091,50,60 HTTP Request,9507549,19,13,42,57,99,0,718,0.00%,2732.1,656.3,20.33,1685470479,50,60 HTTP Request,9924731,18,13,41,55,96,0,726,0.00%,2852.0,685.1,19.84,1685556867,50,60 +HTTP Request,9470373,19,13,43,58,100,0,740,0.00%,2721.4,653.8,20.62,1685643309,50,60 +HTTP Request,9520610,19,13,42,57,100,0,867,0.00%,2735.9,657.2,20.50,1685729722,50,60 diff --git a/load-tests/h1_transformation/results/summary.csv b/load-tests/h1_transformation/results/summary.csv index 18ee7e3f84..3728e9d72a 100644 --- a/load-tests/h1_transformation/results/summary.csv +++ b/load-tests/h1_transformation/results/summary.csv @@ -328,3 +328,5 @@ HTTP Request,7557457,26,23,48,58,87,1,569,0.00%,2171.7,593.8,17.26,1685301648,50 HTTP Request,7717333,26,23,46,56,83,1,418,0.00%,2217.7,606.4,16.37,1685388074,50,60 HTTP Request,7826624,25,22,46,56,83,1,446,0.00%,2249.1,615.0,16.44,1685474432,50,60 HTTP Request,8283128,24,21,43,53,78,1,527,0.00%,2380.2,650.8,15.49,1685560824,50,60 +HTTP Request,8064653,24,22,44,54,80,1,425,0.00%,2317.5,633.7,15.94,1685647272,50,60 +HTTP Request,8278433,24,21,43,53,78,1,442,0.00%,2378.9,650.5,15.49,1685733707,50,60 diff --git a/load-tests/h1c_h1c_passthrough/results/summary.csv b/load-tests/h1c_h1c_passthrough/results/summary.csv index 6d5c7f9bd1..46f3631181 100644 --- a/load-tests/h1c_h1c_passthrough/results/summary.csv +++ b/load-tests/h1c_h1c_passthrough/results/summary.csv @@ -328,3 +328,5 @@ HTTP Request,11185587,16,12,35,47,76,0,350,0.00%,3214.3,571.3,15.40,1685305607,5 HTTP Request,10999720,17,12,36,47,77,0,594,0.00%,3160.9,561.8,15.72,1685392076,50,60 HTTP Request,9858732,18,14,40,52,86,0,537,0.00%,2833.0,503.5,17.66,1685478401,50,60 HTTP Request,11379278,16,12,35,46,75,0,428,0.00%,3269.9,581.2,15.22,1685564821,50,60 +HTTP Request,11330698,16,12,35,46,75,0,347,0.00%,3256.0,578.7,15.36,1685651266,50,60 +HTTP Request,11344755,16,12,35,46,75,0,450,0.00%,3260.1,579.4,15.33,1685737678,50,60 diff --git a/load-tests/h1c_transformation/results/summary.csv b/load-tests/h1c_transformation/results/summary.csv index 6c6a7616ec..06ca84f59b 100644 --- a/load-tests/h1c_transformation/results/summary.csv +++ b/load-tests/h1c_transformation/results/summary.csv @@ -324,3 +324,5 @@ HTTP Request,8778498,22,20,40,48,68,1,285,0.00%,2522.6,532.1,13.48,1685309609,50 HTTP Request,8799393,22,20,40,48,68,0,283,0.00%,2528.6,533.4,13.44,1685396085,50,60 HTTP Request,8044813,24,22,43,52,74,1,292,0.00%,2311.8,487.6,14.66,1685482374,50,60 HTTP Request,9112240,22,19,39,46,66,0,409,0.00%,2618.5,552.3,13.02,1685568777,50,60 +HTTP Request,8840501,22,20,40,48,68,0,264,0.00%,2540.4,535.9,13.47,1685655252,50,60 +HTTP Request,8791114,22,20,40,48,70,0,375,0.00%,2526.2,532.9,14.10,1685741629,50,60 diff --git a/load-tests/h2_h1c_passthrough/results/summary.csv b/load-tests/h2_h1c_passthrough/results/summary.csv index a20ff41591..caf2a2a2dd 100644 --- a/load-tests/h2_h1c_passthrough/results/summary.csv +++ b/load-tests/h2_h1c_passthrough/results/summary.csv @@ -280,3 +280,5 @@ H2-H1C Passthrough,5857,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685310515,0,1 H2-H1C Passthrough,5831,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685396992,0,1 H2-H1C Passthrough,5848,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685483314,0,1 H2-H1C Passthrough,5861,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685569803,0,1 +H2-H1C Passthrough,5849,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685656204,0,1 +H2-H1C Passthrough,5858,0.0,0,0,0,0,0,0,1.0,0.0,0,0,1685742547,0,1 diff --git a/load-tests/interceptors_passthrough/results/summary.csv b/load-tests/interceptors_passthrough/results/summary.csv index ece69e0e6e..73c7026a24 100644 --- a/load-tests/interceptors_passthrough/results/summary.csv +++ b/load-tests/interceptors_passthrough/results/summary.csv @@ -31,3 +31,5 @@ Test Request,4595281,45,27,105,152,279,0,6214,1.82%,1320.5,140.6,56.21,168531444 Test Request,4628826,44,27,104,151,277,0,6959,1.87%,1330.2,141.8,55.65,1685400960,50,60 Test Request,4240938,48,29,112,163,298,0,1377,2.08%,1218.7,130.4,59.77,1685487251,50,60 Test Request,4748132,43,25,102,148,274,0,5815,1.68%,1364.4,144.9,55.10,1685573748,50,60 +Test Request,4797149,43,26,100,145,267,0,1277,1.89%,1378.5,147.0,53.72,1685660148,50,60 +Test Request,4646600,44,27,103,149,272,0,6660,1.71%,1335.3,141.8,54.94,1685746538,50,60 diff --git a/load-tests/observability_enabled/results/summary.csv b/load-tests/observability_enabled/results/summary.csv index cd3b526489..22ade3ee48 100644 --- a/load-tests/observability_enabled/results/summary.csv +++ b/load-tests/observability_enabled/results/summary.csv @@ -311,3 +311,5 @@ HTTP Request,13621321,14,5,38,61,125,0,685,0.00%,3914.2,584.8,25.32,1685318405,5 HTTP Request,14025510,14,5,37,59,123,0,730,0.00%,4030.4,602.2,25.01,1685404962,50,60 HTTP Request,12851823,15,6,39,63,128,0,698,0.00%,3693.1,551.8,26.00,1685491249,50,60 HTTP Request,14254814,13,5,36,59,125,0,1054,0.00%,4096.3,612.0,25.25,1685577733,50,60 +HTTP Request,14088546,14,5,37,60,126,0,813,0.00%,4048.5,604.9,25.50,1685664126,50,60 +HTTP Request,13861009,14,5,37,61,126,0,645,0.00%,3983.1,595.1,25.50,1685750537,50,60 diff --git a/load-tests/snowpeak_passthrough/results/summary.csv b/load-tests/snowpeak_passthrough/results/summary.csv index b30ad9f1d6..93ce9fc917 100644 --- a/load-tests/snowpeak_passthrough/results/summary.csv +++ b/load-tests/snowpeak_passthrough/results/summary.csv @@ -162,3 +162,5 @@ Retrieve Available Locations,5528607,36,20,82,92,118,0,779,0.00%,1588.6,153.6,33 Retrieve Available Locations,5569175,36,19,82,93,120,0,509,0.00%,1600.4,154.7,33.68,1685408944,50,60 Retrieve Available Locations,5280123,38,22,83,94,120,1,496,0.00%,1517.3,146.7,33.57,1685495206,50,60 Retrieve Available Locations,5719924,35,19,81,90,113,0,624,0.00%,1643.6,158.9,32.74,1685581682,50,60 +Retrieve Available Locations,5677009,36,19,82,92,125,0,529,0.00%,1631.3,157.7,33.85,1685668110,50,60 +Retrieve Available Locations,5870926,34,18,80,91,117,0,465,0.00%,1687.1,163.1,33.02,1685754476,50,60 diff --git a/native/src/main/java/io/ballerina/stdlib/http/api/HttpUtil.java b/native/src/main/java/io/ballerina/stdlib/http/api/HttpUtil.java index 4277c277b6..e4452d9610 100644 --- a/native/src/main/java/io/ballerina/stdlib/http/api/HttpUtil.java +++ b/native/src/main/java/io/ballerina/stdlib/http/api/HttpUtil.java @@ -578,7 +578,10 @@ public static BError createHttpError(Throwable throwable) { IOUtils.getIOPackage()); return createHttpError("Something wrong with the connection", HttpErrorType.GENERIC_CLIENT_ERROR, cause); } else if (throwable instanceof ClientConnectorException) { - return HttpUtil.createHttpStatusCodeError(CLIENT_CONNECTOR_ERROR, "Something wrong with the connection"); + cause = createErrorCause(throwable.getMessage(), IOConstants.ErrorCode.GenericError.errorCode(), + IOUtils.getIOPackage()); + return HttpUtil.createHttpStatusCodeError(CLIENT_CONNECTOR_ERROR, "Something wrong with the connection", + null, cause); } else if (throwable instanceof NullPointerException) { return createHttpError("Exception occurred: null", HttpErrorType.GENERIC_CLIENT_ERROR, createHttpError(throwable.toString())); diff --git a/native/src/main/java/io/ballerina/stdlib/http/api/service/signature/ParamUtils.java b/native/src/main/java/io/ballerina/stdlib/http/api/service/signature/ParamUtils.java index 78e0aabb18..6ad7bf9acc 100644 --- a/native/src/main/java/io/ballerina/stdlib/http/api/service/signature/ParamUtils.java +++ b/native/src/main/java/io/ballerina/stdlib/http/api/service/signature/ParamUtils.java @@ -19,6 +19,7 @@ package io.ballerina.stdlib.http.api.service.signature; import io.ballerina.runtime.api.PredefinedTypes; +import io.ballerina.runtime.api.TypeTags; import io.ballerina.runtime.api.creators.TypeCreator; import io.ballerina.runtime.api.creators.ValueCreator; import io.ballerina.runtime.api.types.ArrayType; @@ -214,9 +215,12 @@ public static boolean isFiniteType(Type type) { public static int getEffectiveTypeTag(Type type, Type originalType, String paramType) { Type referredType = TypeUtils.getReferredType(type); int referredTypeTag = referredType.getTag(); + if (TypeTags.isIntegerTypeTag(referredTypeTag)) { + return INT_TAG; + } else if (TypeTags.isStringTypeTag(referredTypeTag)) { + return STRING_TAG; + } switch (referredTypeTag) { - case STRING_TAG: - case INT_TAG: case FLOAT_TAG: case BOOLEAN_TAG: case DECIMAL_TAG: