Online-Code-Checker-and-Compiler-Java

Online Code Checker and Compiler in Java : CodeOj ( codeoj.com )

Online Code Checker and Compiler system ( formally CodeOj / Code Online Judge ) is java based automated testing system to check the Algorithmic skills of the user providing a platform to compete with large no of software developers.

It develop “Fast & Furious” attitude to the coders to be Accurate and Efficient in coding. It will enhance the speed of hiring procedure. Recruiters can assign hiring coding task and schedule the event as per their suitability. Moreover the project can be used for educational purpose for students around the world learning competitive programming.

Quality Attributes of the Software :

CodeOj follows the concept of “Data independence” which is the type of data transparency that matters for a centralized DBMS. It refers to the immunity of user applications to changes made in the definition and organization of data. Physical data independence deals with hiding the details of the storage structure from user applications.

CodeOj allows you to use whichever database you want to use or at any stage of development process you can change the DB.

Version

1.0.0

Tech Stack

CodeOj uses a number of open source tools and technology to work properly:

And of course CodeOj itself is open source with a public repository on GitHub.

Installation

CodeOj requires java v7+ to run.

You need Gulp installed Open source IDE Netbeans v7.x+ with Tomcat server.Download here and follow installation instruction.

A. Install MySQL Server : ( You can go with any other relational databases like DB2 etc. )

For Linux users:

$ sudo apt-get install mysql-server                     
$ sudo service mysql start                  # start  mysql server 
$ mysql -u root -p                          # login with username and password
$ create database codeoj                    # create a database
In the mysql shell :
mysql> CREATE USER 'admin'@'localhost' IDENTIFIED BY 'some_pass';
mysql> GRANT ALL PRIVILEGES ON codeoj.* TO 'admin'@'localhost'
    ->     WITH GRANT OPTION;
C. Set up repository :

Install git and perform following commands for set up the CodeOj repo:

$ git clone  https://github.com/Online-Code-Checker-Java
$ cd codeoj
$ chmod -R 777 codeoj
$ sudo apt-get install python-psutil
$ sudo apt-get install python-mysqldb

Then specify the path of “web” folder to the path variable in src/java/connection/Path.java file.

     static String path = "path/to/codeoj/web";

and set the database configurations in in src/java/connection/Config.java file

    String url = "jdbc:mysql://localhost:3306/codeoj"; //Set up Database server location URL , Port No , Database Name
    String user = "USERNAME";      // Set MySQL(or your DB User)
    String pass = "PASSWORD";      // DB password

also set the database configurations in web/judge.py file

    db = MySQLdb.connect("localhost","USERNAME","PASSWORD","codeoj")

D. Supported Languages:

CodeOj is currently extended with the following languages, so you have to install their respective compilers in your run environment.

E. Configuring CHRoot (Sand-boxing in Linux environment ) :

Sand-boxing provides security by creating a restricted environment for the execution of user’s source code for various languages.

Please follow the following resource for documentation and installation of CHRoot

CodeOj in Action : Administrative Functions

<property name="hibernate.hbm2ddl.import_files" value="/file1.sql,/file2.sql"/>
<property name="hibernate.hbm2ddl.auto" value="create"/>

That’s all for creating a new live contest . To participate in a contest , user’s should register for contest in contest page or contest register link at home page .

Admin can make solution public after the contest by clicking make public button. CodeOj uses ACM style rank list with Elo rating system .

Development

Want to contribute? Great!

We wish to complete following to-dos ASAP by moving Spring Framework 4.2.6

To-dos

For further queries write me to developer.jaswant@gmail.com .

License

MIT

Free Software under MIT