Which is the prefered CGI technology? [closed] - java

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I want to develop a CGI application that has to run under Windows and Linux (IIS and Apache)
What is the best technology to do that?
I would prefer Java, but I am not sure if there is a problem with Java in an IIS.
Any experiences?

Completely depends on your application what
What load are you expecting
How complex will it be.
Where will you store the data
How secure does it need to be
How skilled are you or your developers.
What languages are you familiar with.
For a simple web app its hard to beat Vanilla php, using the LAMP stack with sqlite. As php will let you do almost anthing almost anywhere you need to be disciplined about how you structure your code -- but otherwise its a good solid working environment.
At the other end of the scale are the J2EE behemoths Weblogic and Websphere. These are monsters in terms of complexity and learning curve but if you are planning on 100s of transactions per second, in a secure environment with bullet proof reliability -- and you have deep pockets -- nothing will beat it.
The only sure answer form you post is IIS, ActiveScript .NET is out of the picture if you want to deploy under *nix or anything other than windows.

For plain CGI, Java's startup time is going to be a killer when the process forks. It'll be frustrating even for the low loads you're expecting.
I would, honestly, recommend you use Python for this instead as it will have the right balance of startup / execution speed and "batteries included" features for CGI development.
Here's a link if you're intersted: http://docs.python.org/library/cgi.html

java and CGI is not a good match! If I really had to do a CGI then I would go wit Perl CGI module. Perl should work with IIS too, but I cannot confirm this.

Related

RESTful API with either Tomcat or Node.js? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I am at a decision fork where i have to pick whether to use Tomcat or Node.js in my project and need advice from experts on this.
Some questions that i have here are:
Is Tomcat (Java) or Node.js with Typescript better suited to write a RESTful API which gets values form a Database and has to interact with a another java component?
Does Node.js have unit-testing support?
Is it possible to use websockets with Tomcat for another component of the API which pushes Data to the client?
Is the type system of Java better than the system of Typescript (not all dependencies are available in Typescript (or?) and therefore don’t have types?)?
Tomcat and Node.js are really totally different from each other, so there is no one to one comparison.
While Tomcat is a web server, Node.js is a server side runtime environment - and therein lies all the difference. Java - and consequently the web and application servers supporting it - give an architectural foundation to your application which arguably no other technology can offer. On the other hand, the speed, flexibility and simplicity of JavaScript (and therefore Node.js) is a winner.
So the real question you should be asking is - do you want a robust application with solid foundation or a speedy, flexible solution?
There are also a slew of other factors to consider such as memory, performance, maintainability, and the likes.
Here are some links that might help:
Performance comparison
Java vs. Node.js:
Yes Tomcat Support websocket in tomcat. If you have already some written component in java you should use java.
You can use jersey , spring boot to implement your rest webservices.
If you are working with nosql kind of databases then nodejs could be better bet

Creating a server side for android application [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I'm currently making an android application that will be used by a certain number of clients. Each client will have an account and will access information from the server. This information is stored in a DB.
My question is what is the best way to create a server side that will, later on, be compatible with other platforms (iOS, Windows, etc.)?
Can I use sockets on different platforms? Or should I create a Web Service?
I found a certain tutorial that I think is explaining a similar thing, but I think it demands a certain amount of knowledge, and I'm totally new to this, and haven't learned this at faculty (I'm good with sockets but I never had much confidence in them, and the idea of sending HTTP requests to the server looks much better).
Can someone divert me to a tutorial or lectures of how this is supposed to be done?
Connection between Android and a server would most easily be done with http requests.
There are several libraries available who make this easy like Retrofit.
For server-side applications you can take a look at Jersey in combination with a tomcat server.
There are of course many applications who can do these... so it comes down to a matter of preference.
There are many web development frameworks that works on many platforms such as spring, vertx, play and many others to name. You can you create rest like api for this purpose. Give all the low level works to the framework. You should not worry about low level details as most off them are handled by frameworks today.

Alternatives to Java applets [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
I'm planning to write a simple program that displays course prerequisites for students at my university in graph form (ie as a network of vertices and edges). I'd like to embed the program in a webpage to save people the hassle of downloading an executable.
Currently I'm looking at making my program a Java applet (Java also would give me access to the handy Swing library), but I don't like the fact that applets can't be viewed on most mobile devices.
What alternatives to applets exist for a project like this? I'd like to make it compatible with as many devices as possible, and also not have to build the graphics stuff from scratch.
One final consideration is I'm doing this mostly as a learning exercise. Ideally the tools I'd be working with would be helpful to know in the future.
Please don't use applets. They have been sufficiently deprecated.
The best way to do this is by using html/js/css. A lot of useful libraries exist that can help you with this task. jQuery seems obvious, but there's also d3.js or vis.js for displaying visual representations of data, and bootstrap for responsiveness (mobile friendliness).
You may use Angularjs with angular-chart for Showing graph in Web Browser.
If your graph data is dynamic you might use Nodejs and mongoDB for backend.
angular-chart is responsive and its easy to show dynamic graph. But as it uses HTML5 canvas some mobile browsers might not show its transitions smoothly depending on the device.
I personally do not prefer using applet in web browser when the same functionality can be achieved using great frameworks like Angularjs.
why dont you try to build your project through Servlet framework
by the way cgi were removed by servlet because of the handling of the request
applet uses the same concept

Profiler for java-based web application? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
There are a number of questions related to profiling a java application, but I'm wondering if these recommendations also apply to profiling a web-based (tomcat) java application?
Are there specific tools that a better than others? Or is the assumption that most java applications these days are web-based, and the existing questions/recommendations apply to web based applications?
You can start with jvisualvm in the Sun 6 JDK which allows you to attach to a running JVM and gather basic memory and cpu profiling data. This allows you to get a rough idea of what is going on, and if better profiilng tools are necessary.
I have used JProfiler, JProbe, and DynaTrace. DynaTrace is the most expensive choice but I found it as the most useful one so far. They also have a DynaTrace Ajax Client that's free and lets you profile on the front end side (java script execution, ajax calls, rendering time, etc). You can also use Fiddler to capture execution times.
I've tried JAMon, App Dynamics Lite, and JavaMelody and found JavaMelody to be the best and most compatible of each of them. It is easy to install and provides all the data you need to find the slow web requests, jsp pages, errors, and sql queries. It provides great summary data and charts. It also has very little overhead so it could be used in production instances. It will show you your cpu, ram, and thread utilization. You can't drill down to the nitty gritty per-line profiling like other tools, but it can point you in the right direction to find bottlenecks.

Why do most web hosting services support only PHP as the server-side language? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I have been working with Java and Python, so I found a nice web host which has support for these.
But my question is, why is it so hard to find such hosts?
I understand that PHP is easy, and I also understand that Oracle host is hard to find ($$$ of course), but what do they have against some good open-source, completely free Java Spring, JSP, Django, Python, Ruby on Rails, Perl, etc.?
It is so rare to find hosts ... not to mention freelancer bids.
With Java, hosting is more complicated. You can't just load mod_java and go, you need Tomcat or JBoss, or some other Servlet/JSP hosting environment, and they're non-trivial to configure and maintain.
With Python, I think it's just that it's not as commonly used for web services. I use much more Python than PHP, but I don't tend to use it for web stuff, aside from the occasional Django site. (Mind you, the company I host my personal stuff with charges for Java, but offers Python for "free", the same as PHP).
Perhaps because of the popularity of PHP, compared to other tools?
https://stackoverflow.com/tags
In addition, Java is mostly used for enterprise applications.
I think it's more likely to have PHP because the PHP module and Apache come together on Linux more often. However, I still hosted Python web applications by installing Python on my hosted service and working around all the environment related issues. It's not ideal, but that was the only way to do it.
You can check out some of these if they work for you:
http://wiki.python.org/moin/FreeHosts
Java and Ruby on Rails are expensive in resources (CPU and RAM).
Perl is supported pretty much everywhere...but not published. Probably not so requested
Python...I don't know. Probably not so requested. But there are several free Python hosting options, like http://code.google.com/appengine/, and many others (of course, PHP is still the king by far).
I haven't seen Python support missing from any webhosts ... I'm not sure where you're looking. Checkout out Webfaction - they really are the best for smaller stuff bar none.

Categories