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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T01:00:48+00:00 2026-06-01T01:00:48+00:00

I need to do an HTTP post of information including String byte representations of

  • 0

I need to do an HTTP post of information including String byte representations of multiple files in a single HTTP Post. I’m getting quite a lot of byte allocation errors and was wondering if there was a better way of storing this information for later post to server?

I’ve basically taken quite a few picture files, and I’m packaging them up into a single HTTP Post string of the format:

name="string byte representation of picture file"&timestamp="time"&gps="latitude""longitude",etc.

Logcat:

03-09 22:26:41.329: E/dalvikvm-heap(8716): Out of memory on a 5932438-byte allocation.
03-09 22:26:41.329: I/dalvikvm(8716): "main" prio=5 tid=1 RUNNABLE
03-09 22:26:41.329: I/dalvikvm(8716):   | group="main" sCount=0 dsCount=0 s=N obj=0x40020ba0 self=0xddd0
03-09 22:26:41.329: I/dalvikvm(8716):   | sysTid=8716 nice=0 sched=0/0 cgrp=unknown handle=-1345025972
03-09 22:26:41.329: I/dalvikvm(8716):   at java.lang.AbstractStringBuilder.enlargeBuffer(AbstractStringBuilder.java:~97)
03-09 22:26:41.329: I/dalvikvm(8716):   at java.lang.AbstractStringBuilder.append0(AbstractStringBuilder.java:157)
03-09 22:26:41.329: I/dalvikvm(8716):   at java.lang.StringBuilder.append(StringBuilder.java:217)
03-09 22:26:41.329: I/dalvikvm(8716):   at mfc.generalguixapi8.SaveData2.saveData(SaveData2.java:169)
03-09 22:26:41.329: I/dalvikvm(8716):   at mfc.generalguixapi8.SaveData2.onCreate(SaveData2.java:34)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.ActivityThread.access$2300(ActivityThread.java:125)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.os.Handler.dispatchMessage(Handler.java:99)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.os.Looper.loop(Looper.java:123)
03-09 22:26:41.329: I/dalvikvm(8716):   at android.app.ActivityThread.main(ActivityThread.java:4627)
03-09 22:26:41.339: I/dalvikvm(8716):   at java.lang.reflect.Method.invokeNative(Native Method)
03-09 22:26:41.339: I/dalvikvm(8716):   at java.lang.reflect.Method.invoke(Method.java:521)
03-09 22:26:41.339: I/dalvikvm(8716):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
03-09 22:26:41.339: I/dalvikvm(8716):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-09 22:26:41.339: I/dalvikvm(8716):   at dalvik.system.NativeStart.main(Native Method)
03-09 22:26:41.339: W/dalvikvm(8716): threadid=1: thread exiting with uncaught exception (group=0x40020ac0)
03-09 22:26:41.339: E/AndroidRuntime(8716): FATAL EXCEPTION: main
03-09 22:26:41.339: E/AndroidRuntime(8716): java.lang.OutOfMemoryError
03-09 22:26:41.339: E/AndroidRuntime(8716):     at java.lang.AbstractStringBuilder.enlargeBuffer(AbstractStringBuilder.java:97)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at java.lang.AbstractStringBuilder.append0(AbstractStringBuilder.java:157)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at java.lang.StringBuilder.append(StringBuilder.java:217)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at mfc.generalguixapi8.SaveData2.saveData(SaveData2.java:169)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at mfc.generalguixapi8.SaveData2.onCreate(SaveData2.java:34)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2627)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2679)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.ActivityThread.access$2300(ActivityThread.java:125)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.os.Handler.dispatchMessage(Handler.java:99)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.os.Looper.loop(Looper.java:123)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at android.app.ActivityThread.main(ActivityThread.java:4627)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at java.lang.reflect.Method.invokeNative(Native Method)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at java.lang.reflect.Method.invoke(Method.java:521)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-09 22:26:41.339: E/AndroidRuntime(8716):     at dalvik.system.NativeStart.main(Native Method)
  • 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-01T01:00:49+00:00Added an answer on June 1, 2026 at 1:00 am

    The problem can be solved using Sending file > 1MB using HTTP POST

    I was getting an OutofMemory issue in the above link, and solved it by saving the data to a FileOutputStream and sending the information to the server in chunks.

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

Sidebar

Related Questions

Possible Duplicate: How secure is a HTTP POST? I need to send sensitive information
I need to post some text to a remote server over HTTP, this server
Is it possible to get information about post field order in ASP.NET? I need
I need to make an HTTP POST request from outside the browser, but the
I really need to work with information contained in WordPerfect 12 files without using WordPerfect's
In my application I need to call an API Using Http Post to send
I need to monitor HTTP traffic in my dev env which is PHP/Apache/Windows. But
I need to have : http://www.example.com/v1/my-project/ redirected to http://example.com/my-project/ so : (1) remove the
I need loging all HTTP request (from any application). I have Delphi 7.0. Anybody
I need to set http header for disabling ie (7-8) caching (it disturbs my

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.