HPCCommunity.org
 
Register

Go Back   HPC Community - High Performance Computing (HPC) Community > Symphony Developer Edition (DE) > Symphony DE Articles and Helpful Tips > Development and Debugging Tips

Development and Debugging Tips Share development and debugging tips for Symphony DE.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old July 10th, 2008, 01:52 PM
lechen's Avatar
Junior Member
 
Join Date: March 12th, 2008
Location: Toronto, Ontario
Posts: 71
Blog Entries: 1
Default Re-run your Symphony DE service in a debugger

Scenario

After a service is executed, user can re-run the service under the same execution environment in a Debugger or Integrated Development Environment (IDE). This is achievable as Symphony provides a feature (Service Event Replay Debugger) to save the service instance environment settings and the input events.

Replaying the service can be helpful for:
  • Unit test of service code.
  • Debug unexpected service errors or enviornment issues.

Steps

Configuration:
1. Open the application profile (SampleApp.cpp for example) in an editor.
2. In Service section, add debugSetting="full"
3. Save and register the application using soamreg command.

Code:
<Service description="The Sample Service" name="SampleService" 
         debugSetting="full">
   <osTypes>
      <osType name="all"
       startCmd="${SOAM_DEPLOY_DIR}/SampleServiceCPP"
       workDir="${SOAM_HOME}/work">
      </osType>
   </osTypes>
</Service>
Exeucte service:
1. Run your client (AsyncClient for example).

Setup enviornment:
1. Locate your replay log file
1.1. Go to work directory (C:\SymphonyDE\DE40\work by default).
1.2. Go to directory serl\app_name\service_name (serl\SampleAppCPP\SampleService for example).

2. Run the .env.bat script to setup the enviornment.



Replay service:
1. Launch debugger or IDE (Visual Studies for example) from the same shell or command window where you have set up the enviornment.



2. Run the service (set Service as "StartUp Project" if using VS), set break points where appropriate.



Notes
  • Replay logs are generated every time a service instance is ran, frequent clean-up might be required.
  • User can configure for Symphony to only generate replay logs for certain events (such as service exit, exception, etc.) in specific methods, and do nothing if the service executes successfully. See reference document for details.

References

1. Developer's Guide -> Debugging and Troubleshooting -> Debugging a Service
Reply With Quote
  #2 (permalink)  
Old July 10th, 2008, 01:54 PM
lechen's Avatar
Junior Member
 
Join Date: March 12th, 2008
Location: Toronto, Ontario
Posts: 71
Blog Entries: 1
Default

A live Linux demonstration is now available on SymphonyDE's Youtube Channel.

Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump


All times are GMT. The time now is 10:51 PM.


Powered by vBulletin® Version 3.8.0 Release Candidate 1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.