feat: implement XMPP bridge configuration and logger setup

- Add comprehensive XMPP settings schema to plugin.json
- Implement configuration struct with validation and helper methods
- Add configurable username prefix for XMPP users
- Set up logger in Plugin struct following Matrix bridge pattern
- Update KV store constants to use XMPP terminology
- Replace Matrix references with XMPP equivalents in test helpers

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Felipe M 2025-07-31 12:46:45 +02:00
parent 202622f2c4
commit f1a6cb138f
No known key found for this signature in database
GPG key ID: 52E5D65FCF99808A
5 changed files with 135 additions and 451 deletions

View file

@ -27,6 +27,9 @@ type Plugin struct {
// commandClient is the client used to register and execute slash commands.
commandClient command.Command
// logger is the main plugin logger
logger Logger
backgroundJob *cluster.Job
// configurationLock synchronizes access to the configuration.
@ -41,6 +44,9 @@ type Plugin struct {
func (p *Plugin) OnActivate() error {
p.client = pluginapi.NewClient(p.API, p.Driver)
// Initialize the logger using Mattermost Plugin API
p.logger = NewPluginAPILogger(p.API)
p.kvstore = kvstore.NewKVStore(p.client)
p.commandClient = command.NewCommandHandler(p.client)