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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T04:32:49+00:00 2026-05-31T04:32:49+00:00

Every second time when i’m creating HttpsURLConnection and than calling getInputStream() method I’m getting

  • 0

Every second time when i’m creating HttpsURLConnection and than calling getInputStream() method I’m getting an instance of LocalCloseInputStream instead of ChunkedInputStream, which immediately returns end when I try to read from this stream. There are not exceptions, just an empty stream.

I’ve already tried to set keep.alive to false and connection to close. This doesn’t work.

There two issues look pretty similar, but unfortunately I haven’t found any solution:

http://groups.google.com/group/android-developers/browse_thread/thread/d42c95992ae4dbda

http://groups.google.com/group/twitter4j/browse_thread/thread/105342823f7e3c67

  • 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-05-31T04:32:50+00:00Added an answer on May 31, 2026 at 4:32 am

    For earlier versions of Android you should be using the Apache HTTP client. It works a lot better.

    What you are seeing could be caused by calling #getInputStream() more than once – have you checked what the default state for caching is in your app (for cupcake the cache is on by default for HTTP URL connections, i.e. the second time the response may be served from the cache, which is not likely to return a ChunkedInputStream).

    You can turn caching off by calling #setUseCaches(false) on your connection before using it (or disable it for all future connections by calling #setDefaultUseCaches(false)

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

Sidebar

Related Questions

I have the following method that is executing twice every time it is called:
I choose the method to update my data every second with a javascript PageMethod
Hi i need to show a button after every 120 second for a time
I want to execute a JavaScript function every second, or whenever the time position
I am trying to use a time that updates a label every second (so
i am calling ajax every second in page.. Here the server page returns randomly
Literally every second time I run a big ugly web site project, I get
I want to have a clock showing current time and refreshes every second. The
I want some code to be triggered every second. Usually, I'd create a Timer
I have two processes: Writes to two tables every second (ish) Reads from said

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.