Troubleshooting and Tips
Generally Beebox extensions are easy to develop and easy to install. Nevertheless problems may occur and this chapter explains a few pitfalls to avoid.
Checklist
- Check out the sample extension classes and the code comments.
- Assign a unique ID to each extension (property ExtensionId). Prefix with your company acronym to avoid conflicts with other extensions.Â
- Make sure your dll name ends with .BeeboxPackage.dll, such as MyCompanyExtensions.BeeboxPackage.dll
- Include dependencies with your package. But always exclude standard assemblies from Microsoft or those in the GAC. When a dependency is missing you will see an error message saying that your dll or its dependencies could not be loaded.
- When installing a new Beebox it may come with a version of the Wordbee.Beebox.Extensibility assembly having breaking changes. Make sure to recompile your package with the target Beebox's assembly version. Also read the release notes to see if there are any breaking changes.
How does the Beebox use your code?
- The Beebox creates a single instance of your extension classes.
- The Beebox may dispose and recreate the instance at any time, for example when the Beebox service is restarted or you interact with the extension manager user interface.
- The Beebox loads your assembly (dll) into a distinct .Net application domain.Â
- You likely do not have access to all system resources, you may even not have access to the Internet. This highly depends on the Windows user account configured for the Beebox service (see the "Wordbee Beebox" service in the Windows Services Manager).
Technical tips and constraints:
- Your code must be thread-safe. Generally this is automatically the case if you do not use static variables or unmanaged resources.
- If your code uses unmanaged resources, implement the IDisposable interface.
- Keep in mind that your extension class instance may be alive for days, weeks or months. Make sure that you do not allocate memory with each call without releasing it.
Â
Exceptions
- If your code raises exceptions, these will be written to the Windows event log (in almost all cases).
- Do not implement your own custom exceptions. The extension framework does not allow for this.
Â
Â
If you need help do not hesitate to ask your questions at wordbee.zendesk.com
Â
Copyright Wordbee - Buzzin' Outside the Box since 2008