[Yanel-dev] Debugging
Mehmet Birgi
mehmet.birgi at wyona.com
Mon Mar 22 11:47:47 CET 2010
I am not sure how and where to add this to Bugzilla, but I have
attached the diffs to this mail as an alternative. Please let me know
if there is anything else I need to do.
This approach seems to work, at least on my machine (of course, there
is no windows version for now, I could try to add it if this is
needed, or maybe someone using a windows box should do this?).
On Mon, Mar 22, 2010 at 11:18 AM, Michael Wechner
<michael.wechner at wyona.com> wrote:
> Mehmet Birgi wrote:
>>
>> On Mon, Mar 22, 2010 at 10:20 AM, Michael Wechner
>> <michael.wechner at wyona.com> wrote:
>>
>>>
>>> Mehmet Birgi wrote:
>>>
>>>>
>>>> On Mon, Mar 22, 2010 at 9:46 AM, Michael Wechner
>>>> <michael.wechner at wyona.com> wrote:
>>>>
>>>>
>>>>>
>>>>> Mehmet Birgi wrote:
>>>>>
>>>>>
>>>>>>
>>>>>> I would like to add a parameter "debug" to the script yanel.sh that
>>>>>> will start yanel in debug mode (by executing
>>>>>> "local/apache-tomcat-5.5.20/bin/catalina.sh jpda start"). Any
>>>>>> objections/ideas?
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>> default should be off
>>>>>
>>>>>
>>>>
>>>> the way i thought of doing it (see below) would only do this if you
>>>> entered ".../yanel.sh debug" (instead of e.g. ".../yanel.sh start")
>>>>
>>>>
>>>
>>> I would rather prefer something like
>>>
>>> ./yanel.sh --debug start
>>>
>>> or
>>>
>>> ./yanel.sh -d start
>>>
>>
>> afaics, this could be done either by modifying the target
>> "startup-tomcat-unix" in
>> ".../src/build/targets/cruise-control/continuous-integration.xml", or
>> adding an additional target in "src/build/build.xml", while i would
>> prefer the second option. wdyt?
>>
>
> I am not sure I understand. Maybe it's best if you make a patch of what y=
ou
> would like to do and add it to bugzilla for review.
>
> Thanks
>
> Michi
>
> --
> Yanel-development mailing list Yanel-development at wyona.com
> http://lists.wyona.org/cgi-bin/mailman/listinfo/yanel-development
>
-- =
Mehmet Birgi
www.wyona.com
-------------- next part --------------
Index: src/build/build.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- src/build/build.xml (revision 48179)
+++ src/build/build.xml (working copy)
@@ -278,4 +278,12 @@
<antcall target=3D"deploy-to-tomcat"/>
</target>
=
+ <target name=3D"start-tomcat-debug" description=3D"Start Yanel in debug =
mode" depends=3D"init">
+ <echo>Starting Yanel in debug mode ...</echo>
+ <chmod dir=3D"${default.tomcat.home.dir}/bin" perm=3D"755" includes=3D=
"*"/>
+ <exec dir=3D"${default.tomcat.home.dir}/bin" resolveexecutable=3D"true=
" executable=3D"catalina.sh" spawn=3D"false">
+ <arg line=3D"jpda start"/>
+ </exec>
+ </target>
+
</project>
Index: yanel.sh
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- yanel.sh (revision 48179)
+++ yanel.sh (working copy)
@@ -58,6 +58,9 @@
elif [ "$1" =3D "stop" ]; then
echo "INFO: Stopping Yanel..."
$OUR_ANT stop-tomcat
+elif [ "$1" =3D "debug" ]; then
+ echo "INFO: Starting Yanel in debug mode..."
+ $OUR_ANT start-tomcat-debug
elif [ "$1" =3D "start-jetty" ]; then
echo "INFO: Starting Yanel on Jetty..."
MAVEN=3D`which mvn`
@@ -105,6 +108,7 @@
echo "start - Startup yanel webapp"
echo "stop - Shutdown yanel webapp"
echo "cmdl - Use yanel on the command line"
+ echo "debug - Start yanel in debug mode"
echo "start-jetty - TODO"
echo "configure - TODO"
echo "build - TODO"
More information about the Yanel-development
mailing list