Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8175205
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T22:41:47+00:00 2026-06-06T22:41:47+00:00

I am testing a web application using Java Remote Method Invocation (RMI). When I

  • 0

I am testing a web application using Java Remote Method Invocation (RMI). When I am connected to internet through dongle, broadband; it takes very long time for the RMI to respond to the request. It takes around 10 seconds in completing the method call. I can also see the data transfer rate rising in the internet connection as soon as I make a method call. So definitely it seems to be making an RMI connection between two internal processes through the external network.

While disconnected from internet it responds vary fast, like in few milliseconds. My /etc/hosts file have entry for 127.0.0.1 localhost. I always use 127.0.0.1 in the method invocation url for naming.lookup. But can’t figure out how to make machine respond quickly to RMI calls while I am connected to the internet. Any suggestions?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T22:41:48+00:00Added an answer on June 6, 2026 at 10:41 pm

    You problem is not the the address that you use for the lookup call to the RMI Registry, but rather it’s the address in the URL that is the result of the call to lookup. This defaults to the IP address of the first interface on the system so my guess is that when you’re connected to the Internet it’s your external connection.

    What I think is happening is that you make a call to the RMI Registry on 127.0.0.1 and this returns your Internet address the location of the service you want, and so your RMI call gets routed out over the dongle interface.

    You need to set the java.rmi.server.hostname property to tell the RMI Registry which hostname or IP Adress to return in its RMI URLs.

    So you’ll need something like:

    String ipAddress = "10.1.2.3"; //Local IP address 
    System.setProperty("java.rmi.server.hostname",ipAddress);
    

    or

    String hostname = "myserver"; //hostname that resolves for a local address
    System.setProperty("java.rmi.server.hostname",hostname);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using WatiN for web application testing. There is a field called enter choices
It's a Java (using JUnit) enterprise Web application with no mock objects pre-built, and
I am using Selenium for web application testing. After having finished all the testing,
Given a Java web application using CometD, how can I publish a message to
i am using IE 8 for testing the javascript i write for my web-application.
I'm developing a web application using Logback as logging framework, and am testing it
We're about to deploy a Java web application built using JBoss Seam as the
I'm currently developing a Java-based web application on my MacBook. Most of my testing
we're using SugarCRM as the back-end for a web application. We automatically generate Java
Currently I am doing acceptance testing of my web applications using Cucumber and webrat.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.