From c906cd868445357d63ba3040a8e9fc2683e047a4 Mon Sep 17 00:00:00 2001 From: Arnab-Afk Date: Sun, 23 Mar 2025 00:25:22 +0530 Subject: [PATCH] eclipse termurin update --- backend/service/execution.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/backend/service/execution.go b/backend/service/execution.go index eed14e9..0b1acc3 100644 --- a/backend/service/execution.go +++ b/backend/service/execution.go @@ -181,11 +181,11 @@ func (s *ExecutionService) executeJava(submission *model.CodeSubmission) { // Run Java code in container with performance optimizations cmd := exec.Command("docker", "run", "--rm", "--network=none", // No network access - "--memory=400m", // Further increased memory limit + "--memory=400m", // Memory limit "--cpu-period=100000", // CPU quota period - "--cpu-quota=50000", // 50% CPU (increased from 25%) + "--cpu-quota=50000", // 50% CPU "-v", tempDir+":/code", // Mount code directory - "adoptopenjdk/openjdk11:alpine-jre", // Smaller, faster image + "eclipse-temurin:11-jdk-alpine", // JDK image with Alpine base (smaller and faster) "sh", "-c", "cd /code && javac Main.java && java -XX:+TieredCompilation -XX:TieredStopAtLevel=1 -Xverify:none -Xms64m -Xmx256m Main") log.Printf("[JAVA-%s] Executing Java code with optimized settings", submission.ID)