Running java inside Catalyst

View: New views
9 Messages — Rating Filter:   Alert me  

Running java inside Catalyst

by sindharta_tanuwijaya :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

Just curious, yesterday I was playing with Java inside Catalyst, and I put a code like:

system("java");

in one of my controllers, and when I accessed the URL, the whole computer: Fedora Core 8, froze and I had to restart. I am not sure whether it is an OS problem, since I later tried the same program on Windows XP with colinux(FC 7)/cygwin and the java ran as expected.

Anyone had a similar experience before ?

Sindharta

 


GANBARE! NIPPON! Chance to win 50,000 Yahoo! Points!

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Lorn :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

system function it's a bad idea, if you really need to run Java inside Perl, i did not try that inside Catalyst,  you can check Inline::Java http://search.cpan.org/~patl/Inline-Java-0.52/Java.pod
I think that will not a problem to use Inline::* inside Catalyst.

Good Luck, and tell us your results.

On Sat, Jun 21, 2008 at 10:36 PM, <sindharta_tanuwijaya@...> wrote:
Hi,

Just curious, yesterday I was playing with Java inside Catalyst, and I put a code like:

system("java");

in one of my controllers, and when I accessed the URL, the whole computer: Fedora Core 8, froze and I had to restart. I am not sure whether it is an OS problem, since I later tried the same program on Windows XP with colinux(FC 7)/cygwin and the java ran as expected.

Anyone had a similar experience before ?

Sindharta

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/




--
--Lindolfo "Lorn" Rodrigues
www.slackwarezine.com.br
http://lornlab.org
http://sao-paulo.pm.org
use Catalyst;
_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Jonathan Rockway :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

* On Sun, Jun 22 2008, Lindolfo \"Lorn\" Rodrigues wrote:
> system function it's a bad idea, if you really need to run Java inside Perl, i
> did not try that inside Catalyst,  you can check Inline::Java http://
> search.cpan.org/~patl/Inline-Java-0.52/Java.pod
> I think that will not a problem to use Inline::* inside Catalyst.

You do know that Inline::Java uses system() to call java, right?

Regards,
Jonathan Rockway

--
print just => another => perl => hacker => if $,=$"

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Lorn :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

No, i didn't know, i looked at the source and it's true :(
at least Inline::Java it's better than a simple system("java ... ") ?


On Sun, Jun 22, 2008 at 5:58 PM, Jonathan Rockway <jon@...> wrote:
* On Sun, Jun 22 2008, Lindolfo \"Lorn\" Rodrigues wrote:
> system function it's a bad idea, if you really need to run Java inside Perl, i
> did not try that inside Catalyst,  you can check Inline::Java http://
> search.cpan.org/~patl/Inline-Java-0.52/Java.pod
> I think that will not a problem to use Inline::* inside Catalyst.

You do know that Inline::Java uses system() to call java, right?

Regards,
Jonathan Rockway

--
print just => another => perl => hacker => if $,=$"

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/



--
--Lindolfo "Lorn" Rodrigues
www.slackwarezine.com.br
http://lornlab.org
http://sao-paulo.pm.org
use Catalyst;
_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Mark Trostler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You can use Java.pm & there are no system calls...
        Mark

Lindolfo "Lorn" Rodrigues wrote:

> No, i didn't know, i looked at the source and it's true :(
> at least Inline::Java it's better than a simple system("java ... ") ?
>
>
> On Sun, Jun 22, 2008 at 5:58 PM, Jonathan Rockway <jon@...
> <mailto:jon@...>> wrote:
>
>     * On Sun, Jun 22 2008, Lindolfo \"Lorn\" Rodrigues wrote:
>      > system function it's a bad idea, if you really need to run Java
>     inside Perl, i
>      > did not try that inside Catalyst,  you can check Inline::Java http://
>      > search.cpan.org/~patl/Inline-Java-0.52/Java.pod
>     <http://search.cpan.org/%7Epatl/Inline-Java-0.52/Java.pod>
>      > I think that will not a problem to use Inline::* inside Catalyst.
>
>     You do know that Inline::Java uses system() to call java, right?
>
>     Regards,
>     Jonathan Rockway
>
>     --
>     print just => another => perl => hacker => if $,=$"
>
>     _______________________________________________
>     List: Catalyst@... <mailto:Catalyst@...>
>     Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
>     Searchable archive:
>     http://www.mail-archive.com/catalyst@.../
>     Dev site: http://dev.catalyst.perl.org/
>
>
>
>
> --
> --Lindolfo "Lorn" Rodrigues
> www.slackwarezine.com.br <http://www.slackwarezine.com.br>
> http://lornlab.org
> http://sao-paulo.pm.org
> use Catalyst;
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> List: Catalyst@...
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive: http://www.mail-archive.com/catalyst@.../
> Dev site: http://dev.catalyst.perl.org/

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Robert Krimen :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Sat, Jun 21, 2008 at 6:36 PM,  <sindharta_tanuwijaya@...> wrote:

> Hi,
>
> Just curious, yesterday I was playing with Java inside Catalyst, and I put a
> code like:
>
> system("java");
>
> in one of my controllers, and when I accessed the URL, the whole computer:
> Fedora Core 8, froze and I had to restart. I am not sure whether it is an OS
> problem, since I later tried the same program on Windows XP with colinux(FC
> 7)/cygwin and the java ran as expected.
>
> Anyone had a similar experience before ?

What engine were you running when this happened?

Rob

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by sindharta_tanuwijaya :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

Not sure which specific engine you asked, but I'll just put all of them.

---
java version "1.6.0_06"
Java(TM) SE Runtime Environment (build 1.6.0_06-b02)
Java HotSpot(TM) Server VM (build 10.0-b22, mixed mode)

Linux version 2.6.25.4-10.fc8 (mockbuild@...) (gcc version 4.1.2 20070925 (Red Hat 4.1.2-33)) #1 SMP Thu May 22 23:34:09 EDT 2008

This is perl, v5.8.8 built for i386-linux-thread-multi

Catalyst 5.7014
---

Sindharta

Robert Krimen <robertkrimen@...> wrote:
On Sat, Jun 21, 2008 at 6:36 PM, wrote:
> Hi,
>
> Just curious, yesterday I was playing with Java inside Catalyst, and I put a
> code like:
>
> system("java");
>
> in one of my controllers, and when I accessed the URL, the whole computer:
> Fedora Core 8, froze and I had to restart. I am not sure whether it is an OS
> problem, since I later tried the same program on Windows XP with colinux(FC
> 7)/cygwin and the java ran as expected.
>
> Anyone had a similar experience before ?

What engine were you running when this happened?

Rob

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

 


GANBARE! NIPPON! Chance to win 50,000 Yahoo! Points!

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by Carl Johnstone-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> Not sure which specific engine you asked, but I'll just put all of them.

He meant Catalyst engine...   Catalyst::Engine::?????

Were you using the server script that comes with Catalyst? FastCGI?
mod_perl?

Carl


_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

Re: Running java inside Catalyst

by sindharta_tanuwijaya :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I suppose that would be Catalyst 5.7014 ? I checked Engine.pm and there is no "VERSION" there.

I was using the server script that comes with Catalyst. Actually, I wanted to set up my app with Apache(FastCGI), but at that time I just would like to test if my app can call Java apps.

Sindharta

Carl Johnstone <catalyst@...> wrote:
> Not sure which specific engine you asked, but I'll just put all of them.

He meant Catalyst engine... Catalyst::Engine::?????

Were you using the server script that comes with Catalyst? FastCGI?
mod_perl?

Carl


_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

 


Power up the Internet with Yahoo! Toolbar.

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/
LightInTheBox - Buy quality products at wholesale price