Book Image

Learning Alfresco Web Scripts

By : Ramesh Chauhan
Book Image

Learning Alfresco Web Scripts

By: Ramesh Chauhan

Overview of this book

Table of Contents (18 chapters)
Learning Alfresco Web Scripts
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Troubleshooting pointers


Having understood the different ways to debug web scripts in Alfresco, let's take a look at some of the troubleshooting pointers for some common issues you might come across while working with Alfresco web scripts.

A valid SecureContext error

You might have sometimes faced the error A valid SecureContext was not provided in the RequestContext. There can be many reasons for getting this error. Some of them are listed as follows:

  • When you have set authentication to none in the web script description document, and in the controller you are trying to invoke some public services of Alfresco that require authentication, for example, calling the toDisplayPath() method, it will give you the mentioned exception.

  • If you have a JavaScript-backed controller for your web script and you have deployed it using the repository option and authentication is set to none, you will get the mentioned exception when you try to hit your web script.

Tip

If you are deploying a JavaScript-backed...