Looks like I'm getting confused and dismayed with my attempts to run the
profiler. Any help from any NetBeans user would be appreciated.

Thanks,

  Owen.

---------- Forwarded message ---------
From: Owen Thomas <owen.paul.tho...@gmail.com>
Date: Sat, 24 Nov 2018 at 20:11
Subject: Re: Novice Profiling Question.
To: <v...@ricker.us>


This is strange...

When I start my application from the profiler with the profile view set to
Objects, I see the objects that make up my application. I can switch the
view to Telemetry, and the telemetry view appears. But when I switch the
view back to Objects, nothing appears.

Instead, I get the following in my application console output:

Profiler Agent Error: Exception when handling command from client:
java.io.IOException: JFluid wire protocol error: code does not correspond
to command or response. Value -1
Profiler Agent: Connection with agent closed

I ensured the application was completely compiled by selecting Clean and
Build from the projects menu before I ran it. I'm finding this perhaps a
little confusing...


On Sat, 24 Nov 2018 at 17:40, Vic Ricker <v...@ricker.us> wrote:

> Did you check the objects being created?  Do they interact with anything
> else? (passing references to themselves, or their methods, maybe lambdas?
> to other things that can't be garbage collected?)  Doesn't the profiler
> tell what's holding the references?
> On 11/24/18 12:34 AM, Owen Thomas wrote:
>
> Thanks for the tip. I have just tried it. Unfortunately (a bit
> surprisingly too) it hasn't worked. I call gc every 10 seconds. The number
> of objects I see still seems to grow without limit.
>
> On Sat, 24 Nov 2018 at 15:47, Vic Ricker <v...@ricker.us> wrote:
>
>> Did you try forcing garbage collection with System.gc()?  Those
>> allocations may not be leaked.  It may be that the GC hasn't got to them
>> yet.
>>
>>
>> On 11/23/18 11:19 PM, Owen Thomas wrote:
>> > Hello NetBeans Users.
>> >
>> > An application that I am developing seems to be slowly leaking memory,
>> > and I have been given some advice that makes me think that the best
>> > way to get to the bottom of this problem is by running an instance of
>> > my application in the profile.
>> >
>> > I can do that, and as just as I thought, I am seeing particular type
>> > types of objects being created but not being destroyed by the garbage
>> > collector. I've walked though my code many times, and as far as I can
>> > see, never do I assign the object to a variable that has any scope
>> > other than method scope. I can't see why they wouldn't be gc'd, but
>> > indeed this is not happening, and I am wondering if this is because I
>> > am setting these objects to a variable that persists beyond method
>> scope.
>> >
>> > My question (I suppose it's very simple), is this: how do I get the
>> > references to objects I see in my profiler?
>>
>

Reply via email to