7

I want to create a web based java tutorials kind of project which involves jquery, css, jsp, springs etc ., so I actually want to practice these technologies resulting a good product. The content of this tutorial can be edited by any user and rated by clients according to the chapter etc., I have few such ideas.

One primary idea being have a web based compiler and executor . Similar to w3schools. I know its difficult for a compiler of server side technology on a browser.

My questions are:

  1. Are there any such open source java compiler/executor services available which can be used?

  2. Is anyone interested to work on such project (in case there isnt any)?

EDIT: I am planning to use Compiler in java and Beanshell. Any better solutions ?

5
  • I think you should be encouraging people to download and install a real JDK and a real IDE ... Commented Jun 13, 2011 at 8:20
  • having web based compiler also helps for iPad and chrome OS , It will be there anyway in the future right ? Commented Jun 13, 2011 at 17:26
  • @Stephen C, I once saw such a web site. It ran the submitted code to validate it - one of the steps was deducing if it was O(n) or not (mine was simpler and O(n^2)). Commented Jun 14, 2011 at 12:25
  • Hello there, I am on the same track.Can you guide a bit or were you able to achieve the compilation process? Commented Feb 20, 2015 at 17:04
  • I can help you if I can , or work together if its open source Commented Feb 22, 2015 at 8:51

6 Answers 6

4

Google App Engine is the one, which one can you help to set up Free online Java Compiler, But for that you need to have an account to proceed.

Few other places you can defnitely Check http://compilr.com/

If you have Applets, http://www.innovation.ch/java/java_compile.html

EDIT : As Stephen Suggests, Download JRE and JDE and use it from oracle website http://www.oracle.com/technetwork/java/javase/downloads/index.html

Sign up to request clarification or add additional context in comments.

1 Comment

Can you elaborate on google app engine, are you saying that it can be used to host porject or does it have a way to get web based compiler ? also other websites are good, but they dont provide a service .. do they ??
3

With http://www.browxy.com you can compile and run java console application and applets

Comments

0

You would need a script on your server that accepts the sourcecode, compiles it and runs it, however I'm pretty sure, you don't want to run arbitrary code.

If you still want to do it, take a look at Google's AppEngine, they do allow users to upload their (compiled) java programs and don't seem to have had any problems with it.

3 Comments

I am planning to host the service on googleapp engine, hope it wont be unbearably expensive.
In that case you'd still have to make sure the users won't be able to do something with their code they shouldn't.
that appears scary/difficult. Let me start the basics and see what can I do for security
0

This question is interesting. In fact, Tomcat JSP server is an online compiler for Java Servlet. May help you a little in your case. (Not for traditional Java, though).

Imagine that you gave user an input form for Java codes ( preferably a WYSIWYG editor ), the codes will be written in a temp JSP file, and then your code compile and run the JSP.

But be careful , JSP is too powerful ( as it can touch file system, etc. ). Make sure your security measure is set.

1 Comment

I created one such for C (excluding file management and pointer functionality) . but java is little more complex, and I was very confident something exists already.
0

I've used ideone.com before when discussing Java code with someone in a remote location. It is a web based IDE that handles Java as well as a lot of other languages, and is very useful.

If you are trying to do it yourself, you should be aware java6 and above have compilation built into the language in the javax.tools package.

1 Comment

I wish to create one similar to IDE but open source web service so that anyone can use in their websites. With the compiler we can compile the code, but execution is not possible. We can use beanshell but am not sure how good it is for bigger concepts.
0

You may want to check out Fixoncloud compiler. It's a web-based collaborative online compiler. Anyone can make changes to the code and you can also track history of your code. The compiler supports C, C++ and Java.

Depending on the permissions set to the code, the owner can also make his code completely private and permit only specific users to view/modify the code.

Here's the link to the compiler: http://www.fixoncloud.com/Home/compiler/index.php?id=254

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.