out-of-memory

How to hit java.lang.OutOfMemoryError by spawning threads?

微笑、不失礼 提交于 2019-12-13 05:24:58
问题 I came across this blog site where the author is testing against the maximum number of threads before the machine throws a java.lang.OutOfMemoryError. However, in my below test codes, i am unable to hit the error despite the arbitrary large threads spawned. for (int i = 0; i < 1000000; i++) { Thread thread = new Thread(new Car()); thread.setName(Integer.toString(i)); thread.start(); } 回答1: Try sleeping inside the thread, otherwise it might end up too quickly and get garbage collected, as

NodeJs Stream - Out of Memory

旧时模样 提交于 2019-12-13 05:21:14
问题 I'm trying to process a stream of 300 million rows of data. Once I get to around 5 million rows I am getting a FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory . (The number varies by machine but is consistent happening). You can run the code below to see this happening - I can't tell if the issue in the code of inherent to streams. I tried to dumb the process but I couldn't do that. Is there a memory limit? I removed all other code and 'dumbed' the example down to

Concatenating Duplicated Large Dataframes: MemoryError

强颜欢笑 提交于 2019-12-13 05:12:41
问题 Follow up to: How can I reference the key in the Pandas dataframes within that dictionary? The goal is still to forecast the revenue by fiscal year where I will break revenue into a new column according to how much will be garnered in each year. I have code (put together with some help) that pulls several dataframes into a single dataframe using a dictionary in which I've put them, duplicated except for the Fiscal Year column. These dataframes were then concatenated into one. I've simplified

Out of Memory using after 5 times of change orientation

泪湿孤枕 提交于 2019-12-13 05:09:21
问题 I am handling larges images with 900 x 900 dimension. The images are displayed by a gridview implementation. There are 5 gridviews inside ViewPager's pages. The problem after 4 times of screen orientation change, I am getting out of memory error and the images starts not displaying. The grow heap increases up to 43 mb. I posted the log cat errors. I am using Universal-image-loader . File cacheDir = new File(getActivity().getExternalCacheDir(), "CachedImages"); if (!cacheDir.exists()) cacheDir

.NET Convert.To/FromBase64String cause OutOfMemory Exception in SOAP message

喜你入骨 提交于 2019-12-13 04:13:43
问题 I'm using SOAP Extensions to encrypt/decrypt SOAP messages between server and client consume WebService. General flow is, before sending soap message, 1.Extract message's body, 2.Encrypt it, 3.Append client info to it, 4.Put it back to message, and finally send modified soap message to server. It work perfectly with small request. But when sending large request, an OutOfMemory Exception is thrown when I tried to transform encrypted byte array to human readable string (Base64String) before put

OOM in tez/hive

天涯浪子 提交于 2019-12-13 03:39:23
问题 [After a few answers and comments I asked a new question based on the knowledge gained here: Out of memory in Hive/tez with LATERAL VIEW json_tuple ] One of my query consistently fails with the error: ERROR : Status: Failed ERROR : Vertex failed, vertexName=Map 1, vertexId=vertex_1516602562532_3606_2_03, diagnostics=[Task failed, taskId=task_1516602562532_3606_2_03_000001, diagnostics=[TaskAttempt 0 failed, info=[Container container_e113_1516602562532_3606_01_000008 finished with diagnostics

Possible bug in dalvik of Android 2.x during Bitmap allocation?

假装没事ソ 提交于 2019-12-13 03:00:03
问题 The phenomenon : First do allocation some big memory blocks in the Java side until we catche OutOfMemoryError, then free them all . Now, weird things happen: load even a small picture(e.g. width:200, height:200) by BitmapFactory.decodeXXX(decodeResource, decodeFile, ...) will throw an OutOfMemoryError! But its OK to alloc any pure Java big Object(e.g. new byte[2*1024*1024]) now! Verifying : I wrote some simple codes to verify the problem that can download here, press "Alloc" button many times

Solr indexing issue (out of memory) - looking for a solution

旧街凉风 提交于 2019-12-13 01:48:45
问题 I have a large index of 50 Million docs. all running on the same machine (no sharding). I don't have an ID that will allow me to update the wanted docs, so for each update I must delete the whole index and to index everything from scratch and commit only at the end when I'm done indexing. My problem is that every few index runs, My Solr crashes with out of memory exception, I am running with 12.5 GB memory. From what I understand, until the commit everything is being saved in the memory, so I

Jgraphx out of memory - Java

你说的曾经没有我的故事 提交于 2019-12-13 00:45:02
问题 I am trying to create an mxgraph and a image from the created mxgraph in JAVA. Below is the code to create the image from mxgraph. BufferedImage image = mxCellRenderer.createBufferedImage(graph, null, 1, Color.WHITE, graphComponent.isAntiAlias(), null, graphComponent.getCanvas()); // Creates the URL-encoded XML data mxCodec codec = new mxCodec(); String xml = URLEncoder.encode(mxXmlUtils.getXml(codec.encode(graph.getModel())), "UTF-8"); mxPngEncodeParam param = mxPngEncodeParam

Simple Android App - Out of Memory error when running on smartphone

旧时模样 提交于 2019-12-12 22:33:54
问题 I am fairly new to Android Studio and I try to make a simple app. Random Images should appear after a button is clicked. The next cannot be one that was already showed. I have two classes. The MainActivity and RandomCardDraw. When I run the app in the AVD Emulator, it does not crash. But sometimes I get the information "Skipped frames". When I run it on my Samsung S6 the app crashes everytime when I try to get the second image. In Android I can see a Out of Memory Error. The images are