Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

8
LINES

< > TinyBrain | #1008038 - restartWith1GBHeap - restart program with -Xmx1g if necessary

JavaX fragment (include)

static void restartWith1GBHeap() {
  S preferredVMArguments = "-Xmx1g " + smallHeapArgs();
  if (empty(programArgs()) && !vmArguments().contains("-Xmx1g")) {
    print("Restarting with more memory");
    nohupJavax(programID() + " bla", preferredVMArguments);
    cleanKill();
  }
}

download  show line numbers  debug dex   

Travelled to 1 computer(s): tvejysmllsmz

No comments. add comment

Snippet ID: #1008038
Snippet name: restartWith1GBHeap - restart program with -Xmx1g if necessary
Eternal ID of this version: #1008038/3
Text MD5: bf7c44bef61bc4513c0973fd74e7cbe2
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-04-21 15:29:30
Source code size: 289 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 10 / 3
Version history: 2 change(s)
Referenced in: [show]