Skip to content

Commit 2dacf33

Browse files
authored
Merge branch 'master' into java_17_migration
2 parents 81d3cd4 + c8c831d commit 2dacf33

File tree

11 files changed

+49
-33
lines changed

11 files changed

+49
-33
lines changed

.github/workflows/fossa_scan.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Fossa Scan
2+
on:
3+
workflow_dispatch:
4+
schedule:
5+
- cron: '30 18 * * *' # 00:00 in LK time (GMT+5:30)
6+
jobs:
7+
fossa-scan:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v3
11+
- uses: fossas/fossa-action@main
12+
env:
13+
packageUser: ${{ secrets.BALLERINA_BOT_USERNAME }}
14+
packagePAT: ${{ secrets.BALLERINA_BOT_TOKEN }}
15+
with:
16+
api-key: ${{secrets.FOSSA_APIKEY}}

ballerina/Ballerina.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
org = "ballerina"
33
name = "cloud"
4-
version = "2.9.1"
4+
version = "2.9.0"
55
repository = "https://github.com/ballerina-platform/module-ballerina-c2c"
66
license = ["Apache-2.0"]
77
keywords = ["cloud", "kubernetes", "docker", "k8s", "c2c"]

ballerina/CompilerPlugin.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ id = "code2cloud"
33
class = "io.ballerina.c2c.C2CCompilerPlugin"
44

55
[[dependency]]
6-
path = "../compiler-plugin/build/libs/cloud-compiler-plugin-2.9.1-SNAPSHOT.jar"
6+
path = "../compiler-plugin/build/libs/cloud-compiler-plugin-2.9.0.jar"

ballerina/Dependencies.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@
55

66
[ballerina]
77
dependencies-toml-version = "2"
8-
distribution-version = "2201.8.0-SNAPSHOT"
8+
distribution-version = "2201.7.0"
99

1010
[[package]]
1111
org = "ballerina"
1212
name = "cloud"
13-
version = "2.9.1"
13+
version = "2.9.0"
1414
modules = [
1515
{org = "ballerina", packageName = "cloud", moduleName = "cloud"}
1616
]

compiler-plugin-tests/src/test/java/io/ballerina/c2c/test/samples/Sample3Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public void validateDeployment() {
103103
// Assert Containers
104104
Container container = deployment.getSpec().getTemplate().getSpec().getContainers().get(0);
105105
Assert.assertEquals(container.getImage(), DOCKER_IMAGE);
106-
Assert.assertEquals(container.getResources().getLimits().get("memory").toString(), "256Mi");
106+
Assert.assertEquals(container.getResources().getLimits().get("memory").toString(), "512Mi");
107107
Assert.assertEquals(container.getResources().getLimits().get("cpu").toString(), "500m");
108108
Assert.assertEquals(container.getResources().getRequests().get("cpu").toString(), "200m");
109109
Assert.assertEquals(container.getResources().getRequests().get("memory").toString(), "100Mi");

compiler-plugin-tests/src/test/resources/command/create-cloud-toml/config/create_cloud_toml_cmd.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"character": 0
2424
}
2525
},
26-
"newText":"# This file contains most used configurations supported by Ballerina Code to Cloud\n# All the fields are optional. If these fields are not specified, default value will be taken from the compiler.\n# Full Code to Cloud specification can be accessed from https://github.com/ballerina-platform/ballerina-spec/blob/master/c2c/code-to-cloud-spec.md\n# Uncomment Any field below if you want to override the default value.\n\n# Settings related to artifacts generation\n#[settings]\n#buildImage = true # Build the Docker image while building the project\n#thinJar = true # Use the thin jars in the container\n#\n# Properties related to the container image\n#[container.image]\n#name = \"hello\" # Name of the container image\n#repository = \"ballerina\" # Container repository to host the container\n#tag = \"latest\" # Tag of the container\n#base = \"ballerina/jvm-runtime:1.0\" # Base container of the container image\n#\n# Copy the files to the container image\n#[[container.copy.files]]\n#sourceFile = \"./data/data.txt\" # Path to the external file\n#target = \"/home/ballerina/data/data.txt\" # Path of the file within the container\n#\n# External files required for the code\n#[[cloud.config.maps]]\n#file = \"resource/file.text\" # Path of the external file\n#mount_path = \"/home/ballerina/foo/file.conf\" # Path of the file in the container\n#\n# Environment variables required for the application\n#[[cloud.config.envs]]\n#key_ref = \"FOO\" # Key of the environment variable\n#name = \"foo\" # Name of the env if it is different from the key\n#config_name = \"module-foo\" # Name of the config config map\n#\n# Properties related to the deployment\n#[cloud.deployment]\n#min_memory = \"100Mi\" # Minimum memory allocated to the container\n#max_memory = \"256Mi\" # Maximum memory allocated to the container\n#min_cpu = \"200m\" # Minimum CPU allocated to the container\n#max_cpu = \"500m\" # Maximum CPU allocated to the container\n#\n# Matrices to auto-scale the container\n#[cloud.deployment.autoscaling]\n#min_replicas = 1 # Minimum number of replicas of the container alive at a given time\n#max_replicas = 2 # Maximum number of replicas of the container alive at a given time\n#cpu = 50 # CPU Utilization threshold for spawning a new instance\n#\n# Probe to indicate whether the container is ready to respond to requests. No readiness probe will be generated if not specified\n#[cloud.deployment.probes.readiness]\n#port = 9091 # Port of the readiness probe endpoint\n#path = \"/probes/readyz\" # Endpoint of the readiness probe\n#\n# Probe to indicate whether the container is running. No liveness probe will be generated if not specified\n#[cloud.deployment.probes.liveness]\n#port = 9091 # Port of the liveness probe endpoint\n#path = \"/probes/healthz\" # Endpoint of the liveness probe\n#\n# Volume definitions of the application. No default volumes will be generated if not specified\n#[[cloud.deployment.storage.volumes]]\n#name = \"volume1\" # Name of the volume\n#local_path = \"files\" # Path of the volume\n#size = \"2Gi\" # Maximum size of the volume\n#"
26+
"newText":"# This file contains most used configurations supported by Ballerina Code to Cloud\n# All the fields are optional. If these fields are not specified, default value will be taken from the compiler.\n# Full Code to Cloud specification can be accessed from https://github.com/ballerina-platform/ballerina-spec/blob/master/c2c/code-to-cloud-spec.md\n# Uncomment Any field below if you want to override the default value.\n\n# Settings related to artifacts generation\n#[settings]\n#buildImage = true # Build the Docker image while building the project\n#thinJar = true # Use the thin jars in the container\n#\n# Properties related to the container image\n#[container.image]\n#name = \"hello\" # Name of the container image\n#repository = \"ballerina\" # Container repository to host the container\n#tag = \"latest\" # Tag of the container\n#base = \"ballerina/jvm-runtime:1.0\" # Base container of the container image\n#\n# Copy the files to the container image\n#[[container.copy.files]]\n#sourceFile = \"./data/data.txt\" # Path to the external file\n#target = \"/home/ballerina/data/data.txt\" # Path of the file within the container\n#\n# External files required for the code\n#[[cloud.config.maps]]\n#file = \"resource/file.text\" # Path of the external file\n#mount_path = \"/home/ballerina/foo/file.conf\" # Path of the file in the container\n#\n# Environment variables required for the application\n#[[cloud.config.envs]]\n#key_ref = \"FOO\" # Key of the environment variable\n#name = \"foo\" # Name of the env if it is different from the key\n#config_name = \"module-foo\" # Name of the config config map\n#\n# Properties related to the deployment\n#[cloud.deployment]\n#min_memory = \"100Mi\" # Minimum memory allocated to the container\n#max_memory = \"512Mi\" # Maximum memory allocated to the container\n#min_cpu = \"200m\" # Minimum CPU allocated to the container\n#max_cpu = \"500m\" # Maximum CPU allocated to the container\n#\n# Matrices to auto-scale the container\n#[cloud.deployment.autoscaling]\n#min_replicas = 1 # Minimum number of replicas of the container alive at a given time\n#max_replicas = 2 # Maximum number of replicas of the container alive at a given time\n#cpu = 50 # CPU Utilization threshold for spawning a new instance\n#\n# Probe to indicate whether the container is ready to respond to requests. No readiness probe will be generated if not specified\n#[cloud.deployment.probes.readiness]\n#port = 9091 # Port of the readiness probe endpoint\n#path = \"/probes/readyz\" # Endpoint of the readiness probe\n#\n# Probe to indicate whether the container is running. No liveness probe will be generated if not specified\n#[cloud.deployment.probes.liveness]\n#port = 9091 # Port of the liveness probe endpoint\n#path = \"/probes/healthz\" # Endpoint of the liveness probe\n#\n# Volume definitions of the application. No default volumes will be generated if not specified\n#[[cloud.deployment.storage.volumes]]\n#name = \"volume1\" # Name of the volume\n#local_path = \"files\" # Path of the volume\n#size = \"2Gi\" # Maximum size of the volume\n#"
2727
}
2828
]
2929
}

compiler-plugin/src/main/java/io/ballerina/c2c/models/DeploymentModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public DeploymentModel() {
8383
this.registry = "";
8484
Map<String, Quantity> limit = new HashMap<>();
8585
limit.put("cpu", new Quantity("500m"));
86-
limit.put("memory", new Quantity("256Mi"));
86+
limit.put("memory", new Quantity("512Mi"));
8787
Map<String, Quantity> resource = new HashMap<>();
8888
resource.put("cpu", new Quantity("200m"));
8989
resource.put("memory", new Quantity("100Mi"));

compiler-plugin/src/main/resources/c2c-schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@
290290
"description": "Maximum memory allocated to the container",
291291
"type": "string",
292292
"pattern": "^([+-]?[0-9.]+)([eEinumkKMGTP]*[-+]?[0-9]*)$",
293-
"default": "256Mi"
293+
"default": "512Mi"
294294
},
295295
"min_cpu": {
296296
"description": "Minimum CPU allocated to the container",

examples/kubernetes-resources-autoscaling/Cloud.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ tag="sample3" # Tag of the container
55

66
[cloud.deployment]
77
min_memory="100Mi" # Minimum memory allocated to the container
8-
max_memory="256Mi" # Maximum memory allocated to the container
8+
max_memory="512Mi" # Maximum memory allocated to the container
99
min_cpu="200m" # Minimum CPU allocated to the container
1010
max_cpu="500m" # Maximum CPU allocated to the container
1111

examples/kubernetes-resources-autoscaling/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ spec:
3434
```toml
3535
[[cloud.deployment]]
3636
min_memory="100Mi" # Minimum memory allocated to the container
37-
max_memory="256Mi" # Maximum memory allocated to the container
37+
max_memory="512Mi" # Maximum memory allocated to the container
3838
min_cpu="200m" # Minimum CPU allocated to the container
3939
max_cpu="500m" # Maximum CPU allocated to the container
4040
```
@@ -59,7 +59,7 @@ template:
5959
.
6060
resources:
6161
limits:
62-
memory: "256Mi"
62+
memory: "512Mi"
6363
cpu: "500m"
6464
requests:
6565
memory: "100Mi"

gradle.properties

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,28 @@ org.gradle.jvmargs='-Dfile.encoding=UTF-8'
33
group=io.ballerina
44
version=2.9.1-SNAPSHOT
55
systemProp.org.gradle.internal.publish.checksums.insecure=true
6-
ballerinaLangVersion=2201.7.0-20230619-175900-bb4e4544
7-
stdlibConstraintVersion=1.3.0-20230620-195700-ca941bc
8-
stdlibIoVersion=1.5.0-20230620-192100-29cf327
6+
ballerinaLangVersion=2201.8.0-20230726-145300-b2bdf796
7+
stdlibConstraintVersion=1.3.0
8+
stdlibIoVersion=1.5.0
99
stdlibLogVersion=2.8.1-20230718-085900-36c385c
10-
stdlibHttpVersion=2.9.0-20230621-211000-3a0a7fa
11-
stdlibAuthVersion=2.9.0-20230620-221100-6b88179
12-
stdlibFileVersion=1.8.0-20230620-210800-e8f8123
10+
stdlibHttpVersion=2.9.1-20230712-161400-d16a019
11+
stdlibAuthVersion=2.9.0
12+
stdlibFileVersion=1.8.0
1313
stdlibRegexVersion=1.4.3
14-
stdlibCacheVersion=3.6.0-20230620-211300-8e2e2da
15-
stdlibCryptoVersion=2.4.0-20230620-202300-53ac3fb
16-
stdlibTimeVersion=2.3.0-20230620-192500-12d3432
17-
stdlibMimeVersion=2.8.0-20230620-205000-a1e0453
18-
stdlibOsVersion=1.7.0-20230620-202800-f75dd63
19-
stdlibTaskVersion=2.4.0-20230620-204200-bd8329a
20-
stdlibJwtVersion=2.9.0-20230620-221100-adcdde4
21-
stdlibGrpcVersion=1.9.0-20230622-103300-e35bf3c
22-
stdlibOAuth2Version=2.9.0-20230620-214300-9df2b5a
23-
stdlibUuidVersion=1.6.0-20230620-211300-6fdbff8
24-
stdlibGraphqlVersion=1.9.0-20230622-112800-0ade7bc
25-
stdlibUrlVersion=2.3.0-20230620-193100-90b6489
26-
stdlibWebsubVersion=2.9.0-20230622-084100-c86e0c6
27-
stdlibWebsubhubVersion=1.9.0-20230622-083000-02e28c8
28-
observeVersion=1.1.0-20230620-193900-57e0c73
29-
observeInternalVersion=1.1.0-20230620-201800-18bbd1b
14+
stdlibCacheVersion=3.6.0
15+
stdlibCryptoVersion=2.4.0
16+
stdlibTimeVersion=2.3.0
17+
stdlibMimeVersion=2.8.0
18+
stdlibOsVersion=1.7.0
19+
stdlibTaskVersion=2.4.0
20+
stdlibJwtVersion=2.9.0
21+
stdlibGrpcVersion=1.9.1-20230713-123300-63ff34b
22+
stdlibOAuth2Version=2.9.0
23+
stdlibUuidVersion=1.6.0
24+
stdlibGraphqlVersion=1.9.1-20230718-143100-61e0270
25+
stdlibUrlVersion=2.3.0
26+
stdlibWebsubVersion=2.9.1-20230718-131800-20e8839
27+
stdlibWebsubhubVersion=1.9.1-20230718-131300-fd1b2f7
28+
observeVersion=1.1.0
29+
observeInternalVersion=1.1.0
3030
ballerinaGradlePluginVersion=2.0.0

0 commit comments

Comments
 (0)