Judge0 API v1.6.0
hermanzdosilovic
released this
01 May 18:09
·
246 commits
to master
since this release
v1.6.0 (2020-05-01)
New Features
- Added support for automatically redirecting stderr to stdout of the running program with the configuration flag
redirect_stderr_to_stdout
. Added configuration variableREDIRECT_STDERR_TO_STDOUT
that can be used for setting default behaviour for every submission.- Commits: @8e6617aa
- Added configuration variable
DISALLOW_ORIGIN
that can be used for disabling CORS only for specific origins. - Added configuration variables
ALLOW_IP
andDISALLOW_IP
that can be used for allowing/disallowing only specific IP addresses that can use instance of Judge0 API.- Commits: @4fd0f34b
- Added support for built in maintenance mode that can be enabled with configuration variables
MAINTENANCE_MODE
andMAINTENANCE_MESSAGE
. In maintenance mode clients cannot create or delete submissions i.e. they cannot create new database changes.- Commits: @201221e2
- Added support for universal field
*
which returns all attributes of a submission.- Commits: @521cc2e2
- Added route
GET /statistics
which returns some basic and useful information about Judge0 API instance. Statistic report is cached for 10 minutes. - Added basic support for callbacks which are called with HTTP verb
PUT
. - Added support for presetting custom additional files in a sandbox.
- Added routes
GET /submissions/batch
andPOST /submissions/batch
batch create and show or
submissions.
Improvements
- Use Redis queue with name that corresponds with the current Judge0 API version. This allows multiple instances of different versions of Judge0 API to use the same Redis instance.
- Commits: @dd6b62d7
- Refactored submission field checking.
- Commits: @9acefdbc
- Refactored setting up of default values.
- Commits: @a14ae5d5
Bug Fixes
- Fixed a bug that ignored custom setting of configuration variables
enable_per_process_and_thread_time_limit
andenable_per_process_and_thread_memory_limit
.- Commits: @a6f693a0
- Fixed a bug where cgroups flags for isolate were chosen in the wrong conditions.
- Commits: @4116b9cb
- Fixed a bug that caused
Internal Error
because sandbox cleanup failed. - Fixed a bug where low
memory_limit
would causeInternal Error
. Minimum required value formemory_limit
is now 2048.- Commits: @655ccf27
Security Fixes
- Fixed a bug that allowed creation of an arbitrary size of the compile output.
- Commits: @5fc7b823
Other Changes
- Do not implicitly force wide open CORS settings when in development mode. I.e. variable
ALLOW_ORIGIN
can now also be used in development mode.- Commits: @a3a24c5c
- Removed output of configuration settings when server or worker starts.
- Commits: @7061de7a
- Updated all the gems except Rails to the latest versions.
- Changed default value of
enable_per_process_and_thread_memory_limit
tofalse
.- Commits: @4116b9cb
- Don't show total number of workers in
/workers
that is determined with configuration variableCOUNT
because that number is not relevant.- Commits: @99939b89
- Changed the default port to
80
in Docker Compose file.- Commits: @6ab67d6b
- Limited the log size to 100 MB in Docker Compose file.
- Commits: @435c7d79
- Added logging to
run-workers
script.- Commits: @381265a2
- Updated dummy client default values.
- Added Docker Compose file for HTTPS support.
- Refactored all development and production scripts from
scripts
directory. - Refactored
judge0-api.conf
file.
Deployment Procedure
With HTTPS (SSL/TLS)
- Install Docker and Docker Compose.
- Download and extract release archive:
wget https://github.com/judge0/api/releases/download/v1.6.0/judge0-api-v1.6.0-https.zip
unzip judge0-api-v1.6.0-https.zip
- Change directory to
judge0-api-v1.6.0-https
:
cd judge0-api-v1.6.0-https
- Edit
docker-compose.yml
and change variablesVIRTUAL_HOST
,LETSENCRYPT_HOST
andLETSENCRYPT_EMAIL
. - Run all services and wait few seconds until everything is initialized:
docker-compose up -d db redis nginx letsencrypt
sleep 10s
docker-compose up -d
sleep 5s
- Your instance of Judge0 API v1.6.0 is now available at
https://<YOUR DOMAIN>
.
With HTTP
- Install Docker and Docker Compose.
- Download and extract release archive:
wget https://github.com/judge0/api/releases/download/v1.6.0/judge0-api-v1.6.0.zip
unzip judge0-api-v1.6.0.zip
- Run all services and wait few seconds until everything is initialized:
cd judge0-api-v1.6.0
docker-compose up -d db redis
sleep 10s
docker-compose up -d
sleep 5s
- Your instance of Judge0 API v1.6.0 is now available at
http://<IP ADDRESS OF YOUR SERVER>
.