Win a copy of TensorFlow 2.0 in Action this week in the Artificial Intelligence and Machine Learning forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

using LocateRegistry.getRegistry(), Exception

 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yesterday, after reading a lot of posts here at JavaRanch, I got rmi with suncertify.db classes to work. Found posts here that were discussing getRegistry(). Seemed like the thing to do. But no, I get thrown a RemoteException: "Connection refused to host: localhost; nested exception is: java.net.ConnectException: Connection refused: connect". Tried with -Djava.rmi.server.hostname=127.0.0.1, same thing. I'm using sdk 1.4.1 and 2 machines, both running Win 2000. Please help me sort this out.
Thanks in advance
Cheers
Torgny
 
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi torgny,
i have this line in my server class to create the registry
LocateRegistry.createRegistry(this.port_no);
i am binding this server object to the registry without having implemented the security manager and with security manager both.

harcharan
 
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi torgny,
it seems you have got security problem not rmi registry problem ..
if you are instatiating a security manager inside your code comment it out.
hope this helps,
cheers,
parthi.
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thx for the quick response.
I thought that after 2 hours with this it was time to ask. Looking thru the replies and... well sometimes I wonder, it was my stupid mistake
. If I use createRegistry instead of getRegistry it works like a charm.
Cheers
Torgny
 
parthiban subramaniam
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hahaha
welcome to the head crackers club
right now am cracking my head goin hmmm now how do i make that dialog appear on the center of the screen no matter what the resolution is .. any idea
cheers
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That one's on me
About the dialog, seems to much for FBN, I would position it inside the parent frame and then remember where the user moved and resized it.
/T
 
harcharan kanwal
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi prathiban
this should work for you
dialog.setLocationRelativeTo(frame);
harcharan
 
parthiban subramaniam
Ranch Hand
Posts: 116
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thnx harcharan... that sure does the trick

cheers
reply
    Bookmark Topic Watch Topic
  • New Topic