aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Monkhouse error - running the client Application in Networked mode Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "Monkhouse error - running the client Application in Networked mode" Watch "Monkhouse error - running the client Application in Networked mode" New topic
Author

Monkhouse error - running the client Application in Networked mode

Simon Cockayne
Ranch Hand

Joined: Dec 09, 2000
Posts: 214
Hi,

Page 309 of the (super) Monkhouse book states:

"To start the networked client..."

"javaw -jar sampleproject.jar server"

Surely that would start the server?

It should state:

"javaw -jar sampleproject.jar"

Right?

Cheers,

Simon


SCJP 1.4 (93%)<br />SCJD (In progress. It can run, but it can't hide...)
Edwin Dalorzo
Ranch Hand

Joined: Dec 31, 2004
Posts: 961
In my URLyBird spec the options are:

java -jar <path to jar> <mode>

Where

<path to jar> is the path and file name of the jar file. This file must be name runme.jar according to instructions.html file.

<mode> can be either "server" or "standalone".

The possible scenarios in my implementation are:

1. java -jar runme.jar

In this scenario, the system will start the client application. This application must connect to the remote RMI server, previously started.

2. java -jar runme.jar server

In this scenario, the system will start the server application, that is to say, it will initialize the RMI server.

3. java -jar runme.jar standalone

In this scenario the system starts the client application, but instead of
using remote objects it uses local objects to manipulate the database.

4. java -jar runme.jar xyz

In this case the system receives an invalid input parameter, therefore it prints a help screen to tell the user what is the right input.

I hope this help!
Simon Cockayne
Ranch Hand

Joined: Dec 09, 2000
Posts: 214
Hi,

Thanks for the reply, but the book is wrong.

Regardless of the assignment instructions...

Page 307 states that the SERVER is started by

javaw -jar sampleproject.jar server


Page 309 states the the NETWORKED CLIENT is started by

javaw -jar sampleproject.jar server


Both statements cannot be correct (unless the command starts the SERVER and the NETWORKED CLIENT...which it does not)

Cheers

Simon
Barry Gaunt
Ranch Hand

Joined: Aug 03, 2002
Posts: 7729
I suggest that you add it to the errata by reporting it to the Book's Apress site. Probably it's just a typo glitch missed by the review team.


Ask a Meaningful Question and HowToAskQuestionsOnJavaRanch
Getting someone to think and try something out is much more useful than just telling them the answer.
Simon Cockayne
Ranch Hand

Joined: Dec 09, 2000
Posts: 214
Barry,

Good advice.

Actually I did do this earlier on...

...but wanted to alert folks here too.

Cheers,

Simon.
Anu Bhagat
Ranch Hand

Joined: Jun 20, 2008
Posts: 64
The book still has the same error on Page 309. I was able to run the client in the networked mode only after I found this post.

Thanks for the post.

Anu Bhagat


SCJP5.0, SCJA
Andrew Monkhouse
author and jackaroo
Marshal Commander

Joined: Mar 28, 2003
Posts: 11509
    
  95

Durn - I wasn't moderating this forum back in 2006, so I missed this then, and I didn't get an errata notice from my publisher. I will see if I can add it now.

(Although, to be honest, having seen the title "Monkhouse error" - I was very confused: I thought I was the only one who got Monkhouse errors! )


The Sun Certified Java Developer Exam with J2SE 5: paper version from Amazon, PDF from Apress, Online reference: Books 24x7 Personal blog
Anu Bhagat
Ranch Hand

Joined: Jun 20, 2008
Posts: 64
Andrew,

Actually I tried to send you an email regarding the error today at
scjd@apress.com (To contact the authors this is the address mentioned in the book ), and my email did not make it. i got delivery failed due to incorrect address.

I was going to contact you through this forum about this error, but then I found this post on the forum, which helped me to solve the issue.


 
jQuery in Action, 2nd edition
 
subject: Monkhouse error - running the client Application in Networked mode