• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

existed code in perl and need to enhance in jsp

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

I have software that is a web based and is made in Perl and it is running through
CGI. I have assigned the work of doing some enhancement in the software. As I don�t know Perl and I have been working through in JSP and servlets only. Is this possible that remaining code runs in Perl and I make the enhancement in jsp, servlets or I have to code the whole project in JSP code. Please advise me any solution.


Thanks
Shaveta
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It is possible to integrate some containers like Tomcat with the Apache Web Server, allowing both server side Java and CGI or other popular scripting languages such as PHP to be run at the same time from the same domain.

After that, all someone here can say is that it depends on the code.
CGI is fundamentally different from servlets and JSP.
Things like logins, sessions, concurrency issues, etc would need to be worked out. Without digging through what's already there, nobody on a forum or user list will be able to tell you with any degree of certainty how easy or difficult this will be.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Also, by the way.
Much of JavaRanch is running in a servlet container but the core of the bulletin board is still a CGI application.
So... yes, they can be integrated.
 
Ranch Hand
Posts: 1609
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Even I dont know perl and I am replying on whatever knowledge I have.

Perl scripts/programs run on CGI server. Just like java needs JVM, perl needs perl-software to be installed. Mostly they use Apache Web Server, install perl there and configure webserver to handle perl-requests.

You must be knowing what servlets are they run on servlet-containers/servers like Tomcat.

Now, the question is to have these both CGI-perl part and servlet part together or handle them separately? I dont know if there is any server which can do this both, that is handle perl requests and also handle servlets together, I think tomcat can be configured to handle CGI requests (by tuning some configuration file server.xml/web.xml?)but I doubt if that would suppress handling of servlets. Else you may need separate servers one for CGI and one for servlets, plus a common webserver that takes cares of requests. The webserver would find if request is CGi pass it to CGI server and if it is servlet pass it to servlet-container.

Overall, as Ben said, it would more be an analysis part than a direct solution available. What goes on client side? and what goes on server side? how much is CGI stuff, how much has to be coded in JSP? what server is currently in use, does it have the possibility to act as servlet container? if not then will it be required to transfer data to future-written servlets running on different server? how much will this delegation be... any session-management issues between CGI scripts and servlets??
 
Shaveta Chawla
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you so much. But i am still confused how would i do it. because i have to run both the parts at the same time. i have to run both perl and jsp code and infer something from the data which is the backend.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My point was that we can't really give you a lot of direction for something like this.
 
reply
    Bookmark Topic Watch Topic
  • New Topic