How to debug the javascript snippets in subscription
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
How to debug the javascript snippets in subscription
Hello experts,
Can anyone please let me know if it is possible to debug the javascript snippets one writes to handle subscriptions?
If it is possible, a short explanation would be appreciated.
Please let me know.
Thanks and Regards,
Amit Teli
Solved! Go to Solution.
- Labels:
-
Troubleshooting
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You need to write in on your Subscription code itself, just logging messages you decide, you can't plug to the subscription execution to debug it live.
What you can do it's something like:
Subscription code:
logger.info("A message to the logger");
... your code...
logger.info("Another message to the logger");
... more code...
Best Regards,
Carles.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You need to use logger.info / debug / error / warn functions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks for the quick response.
I think it is available only in java. Is it also possible in javascript?
Could you kindly post sample code for the same if possible?
Thanks again!
Amit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You need to write in on your Subscription code itself, just logging messages you decide, you can't plug to the subscription execution to debug it live.
What you can do it's something like:
Subscription code:
logger.info("A message to the logger");
... your code...
logger.info("Another message to the logger");
... more code...
Best Regards,
Carles.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks a ton Carles
After I added that I could see the messages printed through Monitoring->Script menu.
Best Regards,
Amit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Yup, you can change the level for logging verbose on the "Settings" tab.