Skip to content

#105 Design plugin architecture#257

Open
kkazmierczyk wants to merge 4 commits intomainfrom
issue-105-plugin-architecture
Open

#105 Design plugin architecture#257
kkazmierczyk wants to merge 4 commits intomainfrom
issue-105-plugin-architecture

Conversation

@kkazmierczyk
Copy link
Copy Markdown
Collaborator

Fixes #105

Summary

  • add plugin architecture design document
  • add plugin interface and manager
  • add example plugin and tests

Signed-off-by: Krzysztof Kaźmierczyk <[email protected]>
Signed-off-by: Krzysztof Kaźmierczyk <[email protected]>
Signed-off-by: Krzysztof Kaźmierczyk <[email protected]>
This commit introduces a comprehensive plugin architecture for the javacore-analyser tool:

- Added PluginInterface abstract base class defining the plugin contract
- Implemented PluginManager for plugin discovery, loading, and lifecycle management
- Created detailed design documentation in docs/PLUGIN_ARCHITECTURE_DESIGN.md
- Added example plugin implementation in docs/example_plugin/
- Integrated plugin system into JavacoreSet for extensibility
- Added comprehensive unit tests for plugin system
- Updated README.md with plugin architecture information
- Updated config.ini with plugin configuration options
- Modified report.xsl to support plugin-generated content
- Added trace.log test data file

The plugin architecture enables users to extend the tool's functionality
without modifying core code, supporting custom analysis, reporting,
and data processing capabilities.

Signed-off-by: Krzysztof Kazmierczyk <[email protected]>
Signed-off-by: Krzysztof Kaźmierczyk <[email protected]>
@kkazmierczyk kkazmierczyk force-pushed the issue-105-plugin-architecture branch from 9f421fc to 961658b Compare April 24, 2026 16:06
@kkazmierczyk kkazmierczyk self-assigned this Apr 24, 2026
self.assertEqual(plugin.get_plugin_name(), "mock_test_plugin")
self.assertEqual(plugin.get_display_name(), "Mock Test Plugin")
self.assertIsInstance(plugin.get_file_patterns(), list)
self.assertTrue(len(plugin.get_file_patterns()) > 0)
"""Test that plugin directory is created if it doesn't exist."""
mock_home.return_value = Path(self.temp_dir)

manager = PluginManager()
import logging
import os
import re
from typing import Any, Dict, List, Optional
import fnmatch
import importlib.util
import logging
import os
import unittest
from pathlib import Path
from typing import Any, Dict, List, Optional
from unittest.mock import MagicMock, patch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Design plugin architecture

1 participant