pyvider 2024-12-02
Created provider initializer system with full plugin protocol v6 method implementations
34 files · 6,135+ · 586-

Created provider initializer handling full startup sequence

1 file changed
  • initializer.py ProviderInitializer class handling configuration loading, component discovery, schema registration, and gRPC server setup (264 lines)
  • Created ProviderInitializer class handling the full provider startup sequence including configuration loading, component discovery, schema registration, and gRPC server setup instantiate behavioral
    1 file
    • initializer.py

Added decorator-based component registration system

3 files changed
  • core_decorators.py Decorators for resource, data source, and function registration (45 lines)
  • validation.py Input validation decorators (16 lines)
  • decorators.py Decorator-specific errors (10 lines)
  • Added decorators for resource, data source, and function registration with input validation and error handling instantiate behavioral
    3 files
    • core_decorators.py
    • validation.py
    • decorators.py

Expanded provider service with all Terraform plugin protocol v6 methods

1 file changed
  • provider_service.py Full Terraform plugin protocol v6 implementation with GetProviderSchema, ValidateProviderConfig, ConfigureProvider, ReadResource, PlanResourceChange, ApplyResourceChange, ImportResourceState, ReadDataSource, and more (794+ lines)
  • Massively expanded provider service implementing full Terraform plugin protocol v6 methods including GetProviderSchema, ValidateProviderConfig, ConfigureProvider, ReadResource, PlanResourceChange, ApplyResourceChange, and more instantiate behavioral
    1 file
    • provider_service.py

Streamlined main entry point and expanded registry

5 files changed
  • main.py Simplified by delegating to new initializer system (185 lines net reduction)
  • registry.py Expanded with component type tracking and discovery (97+ lines)
  • grpc_server.py Improved server lifecycle management (127 lines changed)
  • validation.py Additional input validators (36+ lines)
  • resources.py Resource type exports and convenience imports (17 lines)
  • Simplified main.py by delegating to the new initializer system instead of inline setup code streamline internal
    1 file
    • main.py
  • Expanded registry with component type tracking and improved gRPC server lifecycle management streamline internal
    2 files
    • registry.py
    • grpc_server.py
  • Removed standalone handler files replaced by inline methods in provider_service deprecate internal
    3 files
    • get_provider_schema_handler.py
    • apply_resource_change_handler.py
    • plan_resource_change_handler.py

Added decorator registration tests

2 files changed
  • test_decorators.py Registration decorator tests (175 lines)
  • test_terraform_handshake.py Terraform handshake tests
  • Added tests for registration decorators and terraform handshake qualify internal
    2 files
    • test_decorators.py
    • test_terraform_handshake.py