release: prepare v0.6.0-preview
This commit is contained in:
@@ -25,7 +25,7 @@ def free_address():
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--go", default="go")
|
||||
parser.add_argument("--version", default="v0.5.0", help="Target framework release")
|
||||
parser.add_argument("--version", default="v0.6.0-preview", help="Target framework release")
|
||||
parser.add_argument("--from-version", default="v0.2.0", help="Version used before upgrade")
|
||||
args = parser.parse_args()
|
||||
|
||||
|
||||
@@ -145,7 +145,7 @@ class Server:
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--go", default="go")
|
||||
parser.add_argument("--version", default="v0.5.0")
|
||||
parser.add_argument("--version", default="v0.6.0-preview")
|
||||
parser.add_argument("--cli", help="Use a locally built CLI")
|
||||
parser.add_argument("--framework-dir", help="Local framework source for pre-release checks")
|
||||
parser.add_argument("--image", default="mysql:8.4")
|
||||
|
||||
84
scripts/verifyLinux.py
Executable file
84
scripts/verifyLinux.py
Executable file
@@ -0,0 +1,84 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Run GoOmni's repeatable Linux checks inside a pinned Go Docker image."""
|
||||
|
||||
import argparse
|
||||
from pathlib import Path
|
||||
import shutil
|
||||
import shlex
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
|
||||
def workspace_output(root: Path, value: str) -> tuple[Path, str]:
|
||||
requested = Path(value)
|
||||
host_path = requested if requested.is_absolute() else root / requested
|
||||
host_path = host_path.resolve()
|
||||
try:
|
||||
relative = host_path.relative_to(root)
|
||||
except ValueError as exc:
|
||||
raise SystemExit("--output must be inside the repository") from exc
|
||||
host_path.parent.mkdir(parents=True, exist_ok=True)
|
||||
return host_path, "/workspace/" + relative.as_posix()
|
||||
|
||||
|
||||
def main() -> None:
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--image", default="golang:1.25", help="Docker image (default: golang:1.25)")
|
||||
parser.add_argument("--gomaxprocs", type=int, default=4)
|
||||
parser.add_argument("--load", action="store_true", help="also run the isolated server matrix")
|
||||
parser.add_argument("--tls", action="store_true", help="run the load matrix over TLS")
|
||||
parser.add_argument("--duration", default="2s", help="duration per traffic case (up to 30m)")
|
||||
parser.add_argument("--count", type=int, default=3)
|
||||
parser.add_argument("--concurrency", default="1,32,128")
|
||||
parser.add_argument("--idle", default="128,1024")
|
||||
parser.add_argument("--output", help="JSON report path inside the repository")
|
||||
args = parser.parse_args()
|
||||
if args.gomaxprocs < 1 or args.count < 1:
|
||||
parser.error("--gomaxprocs and --count must be positive")
|
||||
if args.tls and not args.load:
|
||||
parser.error("--tls requires --load")
|
||||
|
||||
root = Path(__file__).resolve().parent.parent
|
||||
docker = shutil.which("docker")
|
||||
if docker is None:
|
||||
raise SystemExit("docker is required for Linux verification")
|
||||
|
||||
commands = [
|
||||
"go test -race ./...",
|
||||
"go vet ./...",
|
||||
"go build ./...",
|
||||
]
|
||||
if args.load:
|
||||
load = [
|
||||
"go", "run", "./internal/perfcheck",
|
||||
"--duration", args.duration,
|
||||
"--count", str(args.count),
|
||||
"--concurrency", args.concurrency,
|
||||
"--idle", args.idle,
|
||||
]
|
||||
if args.tls:
|
||||
load.append("--tls")
|
||||
if args.output:
|
||||
_, container_path = workspace_output(root, args.output)
|
||||
load += ["--output", container_path]
|
||||
commands.append(" ".join(shlex.quote(part) for part in load))
|
||||
|
||||
command = " && ".join(commands)
|
||||
docker_args = [
|
||||
docker, "run", "--rm", "--pull=missing",
|
||||
"-v", f"{root}:/workspace",
|
||||
"-w", "/workspace",
|
||||
"-e", "GOWORK=off",
|
||||
"-e", f"GOMAXPROCS={args.gomaxprocs}",
|
||||
args.image, "sh", "-c", command,
|
||||
]
|
||||
print(f"Linux verification image: {args.image}", flush=True)
|
||||
print(f"Linux verification command: {command}", flush=True)
|
||||
result = subprocess.run(docker_args, cwd=root)
|
||||
if result.returncode != 0:
|
||||
raise SystemExit(f"Linux verification failed with exit code {result.returncode}")
|
||||
print("PASS Linux verification", flush=True)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
@@ -14,6 +14,8 @@ def main():
|
||||
parser.add_argument("--load", action="store_true", help="Also compare isolated servers and idle connection memory")
|
||||
parser.add_argument("--tls", action="store_true", help="Run the isolated load matrix over TLS")
|
||||
parser.add_argument("--duration", default="2s", help="Duration per load scenario")
|
||||
parser.add_argument("--concurrency", default="1,32,128")
|
||||
parser.add_argument("--idle", default="128,1024")
|
||||
parser.add_argument("--output", help="JSON output path for --load")
|
||||
args = parser.parse_args()
|
||||
if args.count < 1:
|
||||
@@ -32,7 +34,8 @@ def main():
|
||||
]
|
||||
if args.load:
|
||||
command = [args.go, "run", "./internal/perfcheck", "--duration", args.duration,
|
||||
"--count", str(args.count)]
|
||||
"--count", str(args.count), "--concurrency", args.concurrency,
|
||||
"--idle", args.idle]
|
||||
if args.tls:
|
||||
command.append("--tls")
|
||||
if args.output:
|
||||
|
||||
@@ -91,7 +91,7 @@ def exerciseServer(binary, directory, env, stopSignal, cleanupMarker=None):
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--go", default="go", help="Go executable")
|
||||
parser.add_argument("--version", default="v0.5.0", help="Released CLI version to install")
|
||||
parser.add_argument("--version", default="v0.6.0-preview", help="Released CLI version to install")
|
||||
parser.add_argument("--cli", help="Use a locally built CLI instead of installing")
|
||||
parser.add_argument("--framework-version", help="Explicit version passed to the CLI")
|
||||
parser.add_argument("--framework-dir", help="Local checkout for pre-release verification")
|
||||
|
||||
@@ -13,7 +13,7 @@ from verifyScaffold import MODULE, run
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument("--go", default="go")
|
||||
parser.add_argument("--version", default="v0.5.0")
|
||||
parser.add_argument("--version", default="v0.6.0-preview")
|
||||
parser.add_argument("--framework-dir", help="Use a local checkout before release")
|
||||
args = parser.parse_args()
|
||||
env = dict(os.environ, GOWORK="off")
|
||||
|
||||
Reference in New Issue
Block a user