3 Replies Latest reply on Mar 3, 2007 3:06 PM by ksmith

    running java server

    michaelmuller Level 1
      I'm trying out this Babylon Chat applet and have hit a block. I've never run a java server application on my server before. The docs give the following:

      In order to run a server, however, there isn't much you really
      need to do. It's mostly a non-interactive activity. Just start it up,
      and let it do the work. You don't need to unpack all of the .class files
      from the babylon.jar archive. Just make sure that the babylon.jar files
      is in your classpath. To start the server, invoke the Java interpreter
      with the name 'babylonServer', plus any of the options shown:

      java babylonServer [-portnumber number] [-usepasswords] [-newusers] [-nographics] [-chatlogs] [-help]

      I know there's java running somewhere on my server, but it's not in the c:\java folder. CF installs it somewhere, somehow.

      Do I need to install the JDK? Can't I run this thing using the Java under CF? Where is it?

      I've never done this before and I'm completely spacing out.

        • 1. Re: running java server
          It looks like babylon is packaged with its own server. You shouldn't need a JDK -unless your compiling from the source - just the JRE which you should already have. On windows open the command prompt and set the classpath to the babylon jar file (set CLASSPATH=c:<bablon-directory>\babylon.jar;%CLASSPATH%) and then type in the command they provided you. It appears all the arguments are optional.
          • 2. Re: running java server
            michaelmuller Level 1
            I did that and I'm still getting the error " 'java' is not recognized as an internal or external command, operable program or batch file."

            Then I remembered my old DOS days (sigh) and used WHERE /R c:\ java.* and found that indeed there's a java runtime in c:\CFusionMX7\runtime\jre\bin\ so I ran the PATH command and prepended that dir and ran the "java babylonserver" command again and got this:

            Exception in thread "main" java.lang.NoClassDefFoundError: babylonserver

            Could this be related to CF's java or it's strictly the developer's code?
            • 3. Re: running java server
              ksmith Level 1
              You need to set the classpath. Simplest thing may be to add -cp .;app.jar;... Babylonserver docs should tell you what it expects for a classpath. Like Unix and unlike DOS, java does not even look in the current directory for things. So you specify the current dir with ".".