You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2021/09/02 07:29:52 UTC

[GitHub] [netbeans] JaroslavTulach opened a new pull request #3148: Library to process Heap dumps without accessing java.io.File

JaroslavTulach opened a new pull request #3148:
URL: https://github.com/apache/netbeans/pull/3148


   Certain environments are special and do not provide direct access to the filesystem. As such I cannot use `java.io.File`, `java.io.FileInputStream` & co. Yet processing `.hprof` files may be needed even in such environments. Let's provide an API to load an `.hprof` file content from a `ByteBuffer`. The other issue is `CachedDirectory` - it cannot be used either, as it is directly accessing the filesystem. As far as I can say the current code seems to be ready to work without `CachedDirectory`, this PR just provides a way to request cache-less mode via a new API method.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] matthiasblaesing commented on a change in pull request #3148: Library to process Heap dumps without accessing java.io.File

Posted by GitBox <gi...@apache.org>.
matthiasblaesing commented on a change in pull request #3148:
URL: https://github.com/apache/netbeans/pull/3148#discussion_r702310457



##########
File path: profiler/lib.profiler/test/unit/src/org/netbeans/lib/profiler/heap/HeapFromBufferTest.java
##########
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2010, 2021, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */

Review comment:
       This should be the ALv2 header




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] sdedic commented on a change in pull request #3148: Library to process Heap dumps without accessing java.io.File

Posted by GitBox <gi...@apache.org>.
sdedic commented on a change in pull request #3148:
URL: https://github.com/apache/netbeans/pull/3148#discussion_r700841514



##########
File path: profiler/lib.profiler/src/org/netbeans/lib/profiler/heap/HprofHeap.java
##########
@@ -146,6 +147,23 @@
         heapDumpFile = dumpFile;
     }
 
+    HprofHeap(ByteBuffer bb, int seg, CacheDirectory cacheDir) throws IOException {

Review comment:
       Is it possible to mak a common private constructor with a ByteBuffer  and an optional File ?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] JaroslavTulach merged pull request #3148: Library to process Heap dumps without accessing java.io.File

Posted by GitBox <gi...@apache.org>.
JaroslavTulach merged pull request #3148:
URL: https://github.com/apache/netbeans/pull/3148


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists