[kepler-dev] debuging in actor development
Dan Higgins
higgins at nceas.ucsb.edu
Fri Aug 31 11:12:26 PDT 2007
Hi All,
As a follow up to some questions about the 'Listen to Actor' menu, I
just got that menu added to Kepler. It turns out that the reason it was
not included before is probably an issue with the MenuMapping scheme in
Kepler. [For some reason the scheme described in
'uiContextMenuMappings_en_US.properties' for mapping PT menus did not
work and the method for setting an Action for a menu forgot to mention
that a certain type of constructor is required.]
Dan
---
Carlos Rueda wrote:
> > Are you using the "listen to actor" approach? If not, what else?
>
> The "listen to actor" action creates a debug listener window (see
> ptolemy.actor.gui.DebugListenerTableau), which will show any debug
> messages written by the object via the _debug call. Although the
> approach is certainly similar (observer pattern), in our case we need
> to observe other events (eg., tokens being sent/gotten, status of
> workflow execution, etc.) in a similar way as the provenance framework
> does. We are now determining a set of events (and corresponding
> listener interfaces) that will be particularly relevant for the
> monitoring icons.
>
> Carlos
>
> Bertram Ludaescher wrote:
>>
>> On 8/29/07, *Dan Higgins* <higgins at nceas.ucsb.edu
>> <mailto:higgins at nceas.ucsb.edu>> wrote:
>>
>> Hi All,
>> Actually, the 'Listen to Actor' menu has been removed from
>> Kepler.
>> (I am not at all sure why!)
>>
>>
>>
>> Uhh... who did it? Some "cvs provenance" query could find the
>> culprit ;-)
>>
>> BTW, Norbert, Carlos: since you are interested in "progress
>> monitoring / indicators" for PN (and other MoCs), this might be of
>> interest for you.
>>
>> Are you using the "listen to actor" approach? If not, what else?
>>
>> Bertram
>>
>> You can always debug with simple 'System.out.println(...)'
>> statements in the actor code. Results appear in the command prompt
>> window used to launch Kepler. Kepler uses log4j in many of its
>> actors.
>> Check the Kepler wiki and search for 'log4j' for details.
>>
>> Dan
>>
>> Edward A. Lee wrote:
>> > Sure, if you look in many of the actors, they have lines like:
>> >
>> > if (_debugging) {
>> > _debug("My debug message here.");
>> > }
>> >
>> > Then you can right click on the actor and select "Listen to
>> Actor"
>> > (at least in Ptolemy II... I assume the menu option is available
>> in Kepler).
>> >
>> > Edward
>> >
>> > At 12:00 AM 8/29/2007, [BE] Ufuk Utku Turuncoglu wrote:
>> >
>> >> Hi,
>> >>
>> >> I just wonder that is it possible to redirect the print
>> statement to an
>> >> display (such as to "Listen Director"). I mean, i need to put
>> some print
>> >> statement into my code to see the results of key variables. When
>> i run
>> >> the workflow using java interface i could not see the output
>> of the
>> >> print statement. What kind of debuging options exist in kepler?
>> >>
>> >> Best wishes
>> >>
>> >> Ufuk Utku Turuncoglu
>> >> ITU, HPC
>> >> _______________________________________________
>> >> Kepler-dev mailing list
>> >> Kepler-dev at ecoinformatics.org
>> <mailto:Kepler-dev at ecoinformatics.org>
>> >>
>>
>> http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev
>> >>
>> >
>> > ------------
>> > Edward A. Lee
>> > Chair of EECS and Robert S. Pepper Distinguished Professor
>> > 231 Cory Hall, UC Berkeley, Berkeley, CA 94720-1770
>> > phone: 510-642-0253, fax: 510-642-2845
>> > eal at eecs.Berkeley.EDU <mailto:eal at eecs.Berkeley.EDU>,
>> http://ptolemy.eecs.berkeley.edu/~eal
>> >
>> > _______________________________________________
>> > Kepler-dev mailing list
>> > Kepler-dev at ecoinformatics.org
>> <mailto:Kepler-dev at ecoinformatics.org>
>> >
>>
>> http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev
>>
>> <http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev>
>>
>> >
>> >
>>
>>
>> --
>> *******************************************************************
>> Dan Higgins higgins at nceas.ucsb.edu
>> <mailto:higgins at nceas.ucsb.edu>
>> http://www.nceas.ucsb.edu/ Ph: 805-893-5127
>> National Center for Ecological Analysis and Synthesis (NCEAS) Marine
>> Science Building - Room 3405
>> Santa Barbara, CA 93195
>> *******************************************************************
>>
>> _______________________________________________
>> Kepler-dev mailing list
>> Kepler-dev at ecoinformatics.org <mailto:Kepler-dev at ecoinformatics.org>
>>
>> http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev
>>
>>
>>
>>
>> --
>> Bertram Ludaescher, Assoc. Professor
>> Dept of Computer Science & Genome Center
>> University of California, Davis
>> One Shields Avenue, Davis, CA 95616
>> Ph: (530) 754-8576
>> ludaesch at ucdavis.edu <mailto:ludaesch at ucdavis.edu>
>
--
*******************************************************************
Dan Higgins higgins at nceas.ucsb.edu
http://www.nceas.ucsb.edu/ Ph: 805-893-5127
National Center for Ecological Analysis and Synthesis (NCEAS) Marine Science Building - Room 3405
Santa Barbara, CA 93195
*******************************************************************
More information about the Kepler-dev
mailing list