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 8040211
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T03:49:23+00:00 2026-06-05T03:49:23+00:00

I am getting below warning frequently while running my HttpClient example 06-05 17:43:40.568: W/ResponseProcessCookies(725):

  • 0

I am getting below warning frequently while running my HttpClient example

 06-05 17:43:40.568: W/ResponseProcessCookies(725): Cookie rejected:   "BasicClientCookie[version=1,name=visit,domain=.127.0.0.1,path=/,expiry=Tue Jun 05 17:53:40 IST 2012]". Domain attribute ".127.0.0.1" violates RFC 2965: effective host name does not domain-match domain attribute.

I am trying to send data to gsoap server. I have gone through this link1 link2 link3 but din’t get much help.
here is my code for HttpClient post code

public class newA extends Activity implements OnClickListener {

private static final String TAG = "MyPost";

private boolean post_is_running = false;

private doSomethingDelayed doSth;

/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    setContentView(R.layout.main);

    Button pushButton = (Button) findViewById(R.id.push_button);
    pushButton.setOnClickListener(this);

}

@Override
protected void onPause() {
    super.onPause();
    if (post_is_running) { // stop async task if it's running if app gets
                            // paused
        Log.v(TAG, "Stopping Async Task onPause");
        doSth.cancel(true);
    }
}

@Override
protected void onResume() {
    super.onResume();
     if (post_is_running) { // start async task if it was running previously
                            // and was stopped by   onPause()
        Log.v(TAG, "Starting Async Task onResume");
        doSth = (doSomethingDelayed) new doSomethingDelayed().execute();
        ((Button) findViewById(R.id.push_button)).setText("Resuming..");
    }
}

public void onClick(View v) {
    if (post_is_running == false) {
        post_is_running = true;
        Log.v(TAG, "Starting Async Task onClick");
        doSth = (doSomethingDelayed) new doSomethingDelayed().execute();

        ((Button) findViewById(R.id.push_button)).setText("Starting..");
    } else {
        Log.v(TAG, "Stopping Async Task onClick");
        post_is_running = false;
        doSth.cancel(true);
        ((Button) findViewById(R.id.push_button)).setText("Stopping..");
    }
}

private class doSomethingDelayed extends AsyncTask<Void, Integer, Void> {

    private int num_runs = 0;

    @Override
    protected Void doInBackground(Void... gurk) {

        while (!this.isCancelled()) {
            Log.v(TAG, "going into postData");

            long ms_before = SystemClock.uptimeMillis();
            Log.v(TAG, "Time Now is " + ms_before);

            postData();

            long ms_after = SystemClock.uptimeMillis();

            long time_passed = ms_after - ms_before;

            Log.v(TAG, "coming out of postData");
            Log.i(TAG, "RTT: " + time_passed + " ms");

            num_runs++;

            // publish to UI
            if (!this.isCancelled()) {
                publishProgress(num_runs, (int) time_passed);
            }
        }
        return null;
    }

    @Override
    protected void onCancelled() {
        Context context = getApplicationContext();
        CharSequence text = "Cancelled BG-Thread";
        int duration = Toast.LENGTH_LONG;

        Toast.makeText(context, text, duration).show();

        ((Button) findViewById(R.id.push_button))
                .setText("Stopped. Tap to Start!");
    }

    @Override
    protected void onProgressUpdate(Integer... num_runs) {
        Context context = getApplicationContext();
        CharSequence text = "Looped " + num_runs[0].toString() + " Times";
        int duration = Toast.LENGTH_SHORT;

        Toast.makeText(context,
                text + "\nRTT: " + num_runs[1].toString() + " ms", duration)
                .show();

        ((Button) findViewById(R.id.push_button)).setText(text
                + "\nTap to Stop");

    }
}

/**
 * stupid function that posts hardcoded data to hardcoded address
 */

public void postData() {
    // Create a new HttpClient and Post Header
    HttpClient httpclient = new DefaultHttpClient();
    // HttpPost httppost = new HttpPost("http://129.132.131.73:8880/form");
    HttpPost httppost = new HttpPost("http://192.168.1.37");
    // HttpPost httppost = new HttpPost("http://disney.com/");
    // HttpGet httppost = new HttpGet("http://192.168.1.137:8880/form");

    String resp = null;
    long time_passed = 0;
    try {
        // create data to POST
        List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>(2);
        nameValuePairs.add(new BasicNameValuePair("id", "12345"));
        nameValuePairs.add(new BasicNameValuePair("stringdata",
                "XXXXX Pvt Ltd!"));
        httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));

        long ms_before = SystemClock.uptimeMillis();

        // Execute HTTP Post Request
        HttpResponse response = httpclient.execute(httppost);

        long ms_after = SystemClock.uptimeMillis();
        time_passed = ms_after - ms_before;

        resp = response.toString();

    } catch (ClientProtocolException e) {
        Log.e(TAG, e.toString());
    } catch (IOException e) {
        Log.e(TAG, e.toString());
    }

    Log.i(TAG, "RTT inside post-data: " + time_passed);

    Log.i(TAG, resp.toString());
}

}

please let me know where is the problem .. thanks..

  • 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-05T03:49:25+00:00Added an answer on June 5, 2026 at 3:49 am

    I think your HTTPClient/Android code is fine. It looks like the HTTP server is trying to send cookies for the domain “.127.0.0.1”, but that’s based on an IP address instead of a domain name.

    You probably need to configure your HTTP/SOAP server to believe it has a real name, one accessible from your network, instead of 127.0.0.1 or another IP address. This might also work: 37.1.168.192.in-addr.arpa

    After configuring the server, you might need to change your Java code to use that domain name (eg. new HttpPost("http://server-name.local/");).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

While running my application i am getting the below given warning and application went
I am getting warning::Incompatible pointer types assigning to 'NSMutableData' from 'NSData' in below code
I am getting waring Warning: Window creation failed: GetLastError returns 0x00000579 when using below
When running IIS, I'm getting the below error on all ASPX pages. ASP.NET is
Basically I tried evaluating the function below but keep getting the following error: WARNING
I am getting a warning for the below code. //someother class #define EVENT_ID_DESCRIPTION_LEN 64
I'm building the below example boost-consuming user-mode app with the WDK, but I'm getting
Thanks in advance. Getting this warning when using below code: Warning: file_get_contents(test.php) [function.file-get-contents]: failed
I'm getting the error below... Warning: implode() [function.implode]: Invalid arguments passed in \wp-content/themes/mytheme/functions.php on
I am getting a warning for the below code if i declare this anonymous

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.