housekeep DSC-0054
JaCoCo Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 61.49% (17397/28294)
* Branch Coverage: 52.32% (6724/12852)
* Lines of Code: 28294
* Cyclomatic Complexity: 11339
#### Quality Gates Summary
Output truncated.
Test / Build skipped: 15, passed: 608
Intrepid/Prometeu/Studio/pipeline/pr-master This commit looks good
JaCoCo Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 61.49% (17397/28294)
* Branch Coverage: 52.32% (6724/12852)
* Lines of Code: 28294
* Cyclomatic Complexity: 11339
#### Quality Gates Summary
Output truncated.
Test / Build skipped: 15, passed: 608
Intrepid/Prometeu/Studio/pipeline/pr-master This commit looks good
This commit is contained in:
@@ -1,94 +0,0 @@
|
||||
---
|
||||
id: AGD-0057
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: Introduzir provider completo de frontend
|
||||
status: accepted
|
||||
created: 2026-07-15
|
||||
resolved:
|
||||
decision:
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
# Agenda - Introduzir provider completo de frontend
|
||||
|
||||
## Objetivo
|
||||
|
||||
Domain owner: `compiler/general`, com impacto em `studio`.
|
||||
|
||||
Discutir como consolidar um contrato de `FrontendProvider` que agrupe especificacao, compilador e servicos editoriais opcionais sem transformar o Studio em uma plataforma de plugins.
|
||||
|
||||
## Contexto atual
|
||||
|
||||
O repositorio ja possui `prometeu-compiler/prometeu-frontend-registry/src/main/java/p/studio/compiler/FrontendRegistryService.java` e superficies relacionadas a `FrontendSpec`, `FrontendPhaseService` e `languageId`. Ainda ha sinais de registro ou uso direto do PBS em composition roots e chamadas comuns.
|
||||
|
||||
## Escopo
|
||||
|
||||
- Inspecionar o registry atual e seus consumidores.
|
||||
- Definir se `FrontendProvider` deve ser novo contrato ou evolucao de contrato existente.
|
||||
- Planejar `PBSFrontendProvider` como unico provider inicial.
|
||||
- Preservar selecao atual por `languageId`.
|
||||
|
||||
## Fora de escopo
|
||||
|
||||
- Descoberta dinamica de plugins.
|
||||
- Reflection, classpath scanning ou carregamento externo de JARs.
|
||||
- Implementar qualquer frontend real alem do PBS.
|
||||
|
||||
## Arquivos e componentes a inspecionar
|
||||
|
||||
- `prometeu-compiler/prometeu-frontend-registry/src/main/java/p/studio/compiler/FrontendRegistryService.java`
|
||||
- `prometeu-compiler/frontends/prometeu-frontend-pbs/...`
|
||||
- `prometeu-compiler/prometeu-build-pipeline/...`
|
||||
- `prometeu-studio/src/main/java/p/studio/projects/ProjectLanguageCatalogService.java`
|
||||
- `prometeu-app/src/main/java/p/studio/AppContainer.java`
|
||||
|
||||
## Alteracoes propostas
|
||||
|
||||
Opcao A: criar `FrontendProvider` explicito com `specification()`, `compiler()` e `languageService()` opcional.
|
||||
|
||||
Opcao B: evoluir o registry para devolver um objeto existente que ja represente provider, adicionando apenas os campos faltantes.
|
||||
|
||||
Recomendacao inicial: preferir a menor mudanca que faca o codigo comum resolver `provider = registry.require(languageId)` e pare de conhecer classes PBS fora do composition root.
|
||||
|
||||
## Estrategia de implementacao
|
||||
|
||||
Comecar por uma auditoria de chamadas atuais ao registry e de instanciacoes diretas do PBS. Introduzir o contrato sem remover APIs antigas no mesmo passo, migrar PBS para o contrato e so entao substituir consumidores comuns.
|
||||
|
||||
## Testes necessarios
|
||||
|
||||
- Teste do registry exigindo resolucao por `languageId`.
|
||||
- Teste de registro unico do PBS como provider inicial.
|
||||
- Teste de erro claro para `languageId` desconhecido.
|
||||
|
||||
## Criterios de aceitacao
|
||||
|
||||
- O codigo comum consulta o provider, nao instancia `PBSFrontendPhaseService`.
|
||||
- PBS permanece funcional.
|
||||
- Nenhum frontend real novo e criado.
|
||||
|
||||
## Riscos
|
||||
|
||||
- Criar uma abstracao grande demais antes de mapear os consumidores reais.
|
||||
- Misturar contrato de build com contrato editorial.
|
||||
|
||||
## Decisoes que devem ser registradas
|
||||
|
||||
- Nome final do contrato.
|
||||
- Responsabilidades minimas do provider.
|
||||
- Onde fica o composition root autorizado a registrar PBS.
|
||||
|
||||
## Resolucao aceita
|
||||
|
||||
O contrato deve ser introduzido como `FrontendProvider`.
|
||||
|
||||
Responsabilidades minimas:
|
||||
|
||||
- expor a especificacao do frontend por `specification()`;
|
||||
- expor o compilador ou fase de compilacao equivalente por `compiler()`;
|
||||
- expor servicos editoriais por `languageService()` somente como capacidade opcional, quando necessaria para o Studio.
|
||||
|
||||
O contrato nao deve incluir descoberta dinamica de plugins, reflection, classpath scanning ou carregamento externo de JARs.
|
||||
|
||||
O registro inicial deve continuar explicito no composition root da aplicacao, com `prometeu-app/src/main/java/p/studio/AppContainer.java` como ponto preferencial de composicao. Codigo comum deve consumir o provider via `registry.require(languageId)` e nao deve instanciar diretamente classes PBS, incluindo `PBSFrontendPhaseService`.
|
||||
|
||||
PBS permanece o unico provider inicial. Nenhum frontend real novo deve ser criado por esta frente.
|
||||
-92
@@ -1,92 +0,0 @@
|
||||
---
|
||||
id: DEC-0040
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: FrontendProvider explicito como contrato de frontend
|
||||
status: accepted
|
||||
created: 2026-07-15
|
||||
ref_agenda: AGD-0057
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
## Context
|
||||
|
||||
This decision belongs to domain owner `compiler/general`, with impact on `studio`.
|
||||
|
||||
The repository already has `FrontendRegistryService`, `FrontendSpec`, `FrontendPhaseService`, and `languageId` based selection. Those surfaces are enough to keep PBS working, but common compiler and Studio code still has places where PBS-specific classes or assumptions can leak into composition and consumption paths.
|
||||
|
||||
The multi-frontend direction requires a stable provider boundary before removing PBS-specific branches from common code. The boundary must make frontend registration explicit without turning the Studio or compiler into a dynamic plugin platform.
|
||||
|
||||
This decision resolves `AGD-0057`.
|
||||
|
||||
## Decision
|
||||
|
||||
The repository MUST introduce an explicit `FrontendProvider` contract as the common frontend registration unit.
|
||||
|
||||
`FrontendProvider` MUST expose the following minimum responsibilities:
|
||||
|
||||
- `specification()`: returns the frontend specification, including its stable `languageId`;
|
||||
- `compiler()`: returns the compiler-facing frontend service or phase equivalent used by the build pipeline;
|
||||
- `languageService()`: returns an optional editor-facing language service capability for Studio consumers.
|
||||
|
||||
`languageService()` MUST be optional. A frontend that can compile but does not provide editor services MUST remain a valid provider.
|
||||
|
||||
`FrontendRegistryService` MUST resolve providers by `languageId`. The common consumption shape SHOULD become `provider = registry.require(languageId)` or an equivalent explicit lookup that fails clearly for unknown languages.
|
||||
|
||||
PBS MUST be registered as the only initial real provider through a `PBSFrontendProvider` or equivalent concrete provider object. This work MUST NOT introduce another real frontend.
|
||||
|
||||
Provider registration MUST remain explicit in the application composition root. `prometeu-app/src/main/java/p/studio/AppContainer.java` is the preferred initial composition point for registering the PBS provider.
|
||||
|
||||
Common compiler, build pipeline, and Studio code MUST NOT instantiate PBS-specific frontend services directly. In particular, common code MUST NOT directly instantiate `PBSFrontendPhaseService`; it MUST obtain the relevant service through the provider resolved from the registry.
|
||||
|
||||
This decision MUST NOT introduce dynamic plugin discovery, reflection-based discovery, classpath scanning, external JAR loading, or runtime plugin installation.
|
||||
|
||||
## Rationale
|
||||
|
||||
An explicit provider object gives the project one stable unit for frontend identity, compilation, and optional editorial capability. It keeps `languageId` as the selection key while avoiding scattered direct knowledge of PBS in common code.
|
||||
|
||||
Keeping the provider small prevents a premature plugin architecture. The immediate goal is static multi-frontend readiness inside the repository, not external extensibility.
|
||||
|
||||
Making language services optional separates build correctness from Studio editor assistance. A frontend should be able to participate in compilation without being forced to implement editor features in the same wave.
|
||||
|
||||
Using the application composition root for registration keeps ownership clear: composition may know that PBS exists, but shared compiler and Studio consumers should only know the provider contract.
|
||||
|
||||
## Implications
|
||||
|
||||
- `FrontendRegistryService` will need to evolve from spec/phase lookups into provider lookup, while preserving compatibility during migration where necessary.
|
||||
- Existing PBS registration must be wrapped behind a provider object.
|
||||
- Common consumers that currently request `FrontendSpec` or `FrontendPhaseService` directly may be migrated incrementally to provider lookup.
|
||||
- Studio catalog code may continue listing specifications, but its source should become provider-derived rather than PBS-specific.
|
||||
- Build pipeline code should obtain compiler-facing frontend behavior from the resolved provider.
|
||||
- Error handling for unknown `languageId` must remain explicit and diagnostic-friendly.
|
||||
- No product or runtime behavior should change for PBS as the only registered provider.
|
||||
|
||||
## Propagation Targets
|
||||
|
||||
- specs:
|
||||
- Add or update a `compiler/general` specification for the frontend provider and registry contract.
|
||||
- Reference Studio-facing optional language service capability where relevant.
|
||||
- plans:
|
||||
- Create an implementation plan for provider contract introduction, PBS provider registration, consumer migration, and tests.
|
||||
- code:
|
||||
- `prometeu-compiler/prometeu-frontend-registry/src/main/java/p/studio/compiler/FrontendRegistryService.java`
|
||||
- PBS frontend module provider implementation.
|
||||
- `prometeu-compiler/prometeu-build-pipeline/...` consumers that resolve frontend services.
|
||||
- `prometeu-studio/src/main/java/p/studio/projects/ProjectLanguageCatalogService.java`
|
||||
- `prometeu-app/src/main/java/p/studio/AppContainer.java`
|
||||
- tests:
|
||||
- Registry resolves a provider by `languageId`.
|
||||
- PBS is registered as the only initial real provider.
|
||||
- Unknown `languageId` fails with a clear error.
|
||||
- Common code can obtain compiler-facing frontend behavior without directly instantiating `PBSFrontendPhaseService`.
|
||||
- docs:
|
||||
- Decision-derived implementation plan.
|
||||
- Lessons after implementation and housekeeping, if the completed work produces reusable guidance.
|
||||
|
||||
## References
|
||||
|
||||
- Agenda: AGD-0057
|
||||
- Source discussion: DSC-0054
|
||||
|
||||
## Revision Log
|
||||
|
||||
- 2026-07-15: Initial decision drafted from accepted `AGD-0057`.
|
||||
@@ -1,71 +0,0 @@
|
||||
---
|
||||
id: PLN-0103
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: Specify frontend provider and registry contract
|
||||
status: done
|
||||
created: 2026-07-15
|
||||
ref_decisions: [DEC-0040]
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
## Briefing
|
||||
|
||||
DEC-0040 locks an explicit `FrontendProvider` contract as the common frontend registration unit. The first implementation step is to make that contract normative in the compiler/general specs before changing code.
|
||||
|
||||
Domain owner: `compiler/general`, with impact on `studio`.
|
||||
|
||||
## Objective
|
||||
|
||||
Specify the frontend provider and registry contract so implementation can introduce the API without relying on implicit behavior or PBS-specific assumptions.
|
||||
|
||||
## Dependencies
|
||||
|
||||
- Accepted decision: `DEC-0040`.
|
||||
- Existing compiler specs under `docs/specs/compiler/`.
|
||||
- Existing Studio/editor references may be linked but must not become the owner of the contract.
|
||||
|
||||
## Scope
|
||||
|
||||
- Add or update a compiler/general spec section defining `FrontendProvider`.
|
||||
- Define required provider responsibilities:
|
||||
- `specification()`;
|
||||
- `compiler()`;
|
||||
- optional `languageService()`.
|
||||
- Define `languageId` as the registry lookup key.
|
||||
- Define explicit provider registration as the only supported v1 registration model.
|
||||
- Define PBS as the only initial real provider.
|
||||
- Define unknown-language failure behavior as explicit and diagnostic-friendly.
|
||||
- Define that common code must obtain compiler-facing frontend behavior through provider lookup.
|
||||
|
||||
## Non-Goals
|
||||
|
||||
- Do not specify dynamic plugin discovery.
|
||||
- Do not specify reflection, classpath scanning, external JAR loading, or runtime plugin installation.
|
||||
- Do not introduce a second real frontend.
|
||||
- Do not define the full Studio language-service API beyond optional provider capability.
|
||||
|
||||
## Execution Method
|
||||
|
||||
1. Inspect existing compiler/general spec organization and choose the nearest owner document for registry and frontend composition.
|
||||
2. Add a `FrontendProvider` section with normative `MUST` language for required and optional responsibilities.
|
||||
3. Add a registry section stating that providers are resolved by `languageId` and that unknown languages fail clearly.
|
||||
4. Add a registration section stating that provider registration is explicit and composition-root-owned.
|
||||
5. Add a PBS v1 section stating that PBS is the only initial real provider and no new frontend is introduced by this work.
|
||||
6. Cross-reference Studio only as an optional language-service consumer, not as the owner of the provider contract.
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- A compiler/general spec defines `FrontendProvider`, registry lookup, explicit registration, and PBS-only initial provider status.
|
||||
- The spec prohibits plugin discovery, reflection discovery, scanning, external JAR loading, and runtime plugin installation for this decision.
|
||||
- The spec makes `languageService()` optional and does not require editor support for a compilable frontend.
|
||||
- The spec is written in English.
|
||||
|
||||
## Tests
|
||||
|
||||
- Documentation validation through review against `DEC-0040`.
|
||||
- No code tests are required in this plan.
|
||||
|
||||
## Affected Artifacts
|
||||
|
||||
- `docs/specs/compiler/...`
|
||||
- `discussion/workflow/decisions/DEC-0040-frontendprovider-explicito-como-contrato-de-frontend.md`
|
||||
@@ -1,69 +0,0 @@
|
||||
---
|
||||
id: PLN-0104
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: Introduce FrontendProvider registry API
|
||||
status: done
|
||||
created: 2026-07-15
|
||||
ref_decisions: [DEC-0040]
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
## Briefing
|
||||
|
||||
DEC-0040 requires common code to resolve frontend behavior through a provider. This plan introduces the API surface in the frontend registry without forcing all consumers to migrate in the same change.
|
||||
|
||||
Domain owner: `compiler/general`.
|
||||
|
||||
## Objective
|
||||
|
||||
Introduce `FrontendProvider` and provider-based registry lookup while preserving existing PBS behavior during migration.
|
||||
|
||||
## Dependencies
|
||||
|
||||
- `PLN-0103` should define the normative spec first.
|
||||
- Accepted decision: `DEC-0040`.
|
||||
- Existing registry module: `prometeu-compiler/prometeu-frontend-registry`.
|
||||
|
||||
## Scope
|
||||
|
||||
- Add the `FrontendProvider` contract in the frontend registry module.
|
||||
- Add an optional language-service return shape, using an existing interface if one already exists or a minimal neutral placeholder only if required.
|
||||
- Add provider registration and provider lookup by `languageId`.
|
||||
- Add `require(languageId)` or equivalent explicit lookup that fails clearly for unknown languages.
|
||||
- Preserve compatibility methods during migration if existing consumers still call spec or phase lookup.
|
||||
|
||||
## Non-Goals
|
||||
|
||||
- Do not register PBS in this plan unless needed for API tests with a simple fixture.
|
||||
- Do not migrate build pipeline or Studio consumers in this plan.
|
||||
- Do not add plugin discovery, reflection, scanning, external JAR loading, or runtime plugin installation.
|
||||
- Do not define a broad editor API.
|
||||
|
||||
## Execution Method
|
||||
|
||||
1. Inspect `FrontendRegistryService`, `FrontendSpec`, and `FrontendPhaseService` to confirm current method names and package ownership.
|
||||
2. Add `FrontendProvider` to the registry-facing package with `specification()`, `compiler()`, and optional `languageService()`.
|
||||
3. Update `FrontendRegistryService` so its primary storage is provider keyed by `languageId`.
|
||||
4. Add `require(languageId)` or the nearest local naming equivalent for provider lookup.
|
||||
5. Keep old spec/phase accessor methods as provider-derived compatibility wrappers if they are still used.
|
||||
6. Add registry unit tests for provider registration, provider lookup, duplicate language handling if currently supported, and unknown-language errors.
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- `FrontendProvider` exists and exposes all responsibilities required by `DEC-0040`.
|
||||
- `FrontendRegistryService` can resolve a provider by `languageId`.
|
||||
- Unknown `languageId` lookup fails with a clear exception or diagnostic message.
|
||||
- Existing callers can still compile until their migration plan runs.
|
||||
|
||||
## Tests
|
||||
|
||||
- Registry test: registered provider is returned by `languageId`.
|
||||
- Registry test: unknown `languageId` fails clearly.
|
||||
- Registry test: provider-derived spec listing remains correct if compatibility methods remain.
|
||||
- Run the relevant Gradle test task for `prometeu-frontend-registry`.
|
||||
|
||||
## Affected Artifacts
|
||||
|
||||
- `prometeu-compiler/prometeu-frontend-registry/src/main/java/p/studio/compiler/FrontendRegistryService.java`
|
||||
- New `FrontendProvider` contract in the same registry API surface.
|
||||
- Registry tests under `prometeu-compiler/prometeu-frontend-registry/src/test/...`
|
||||
@@ -1,73 +0,0 @@
|
||||
---
|
||||
id: PLN-0105
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: Wrap PBS frontend as explicit provider
|
||||
status: done
|
||||
created: 2026-07-15
|
||||
ref_decisions: [DEC-0040]
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
## Briefing
|
||||
|
||||
DEC-0040 requires PBS to become the only initial real provider behind the new `FrontendProvider` contract. This plan wraps existing PBS frontend behavior without changing PBS product behavior.
|
||||
|
||||
Domain owner: `compiler/general`, with implementation in `compiler/pbs` and composition impact in `prometeu-app`.
|
||||
|
||||
## Objective
|
||||
|
||||
Create and register an explicit PBS provider through the application composition root.
|
||||
|
||||
## Dependencies
|
||||
|
||||
- `PLN-0104` must introduce `FrontendProvider` and provider lookup first.
|
||||
- Accepted decision: `DEC-0040`.
|
||||
- Existing PBS frontend phase/service implementation.
|
||||
- Application composition root in `prometeu-app`.
|
||||
|
||||
## Scope
|
||||
|
||||
- Add `PBSFrontendProvider` or equivalent concrete provider object.
|
||||
- Make the provider return the existing PBS `FrontendSpec`.
|
||||
- Make the provider return the existing PBS compiler-facing service or phase.
|
||||
- Return no language service, or the existing PBS language-service adapter only if already present and compatible.
|
||||
- Register PBS explicitly in `prometeu-app/src/main/java/p/studio/AppContainer.java` or the nearest current application composition point.
|
||||
- Ensure PBS remains the only initial real provider.
|
||||
|
||||
## Non-Goals
|
||||
|
||||
- Do not create another real frontend.
|
||||
- Do not change PBS parsing, semantics, lowering, or runtime output.
|
||||
- Do not migrate all common consumers in this plan.
|
||||
- Do not introduce dynamic provider discovery.
|
||||
|
||||
## Execution Method
|
||||
|
||||
1. Inspect PBS frontend module boundaries and locate the current `FrontendSpec` and `FrontendPhaseService` construction.
|
||||
2. Add `PBSFrontendProvider` in the PBS frontend module or an existing integration package that can legally depend on PBS.
|
||||
3. Implement `specification()` and `compiler()` by delegating to the existing PBS objects.
|
||||
4. Implement `languageService()` as empty unless a current Studio-compatible PBS language service already exists.
|
||||
5. Update `AppContainer` or the existing composition root to register the PBS provider explicitly with `FrontendRegistryService`.
|
||||
6. Remove direct PBS registration paths that duplicate the provider registration if they become redundant.
|
||||
7. Add tests proving only PBS is registered as the real provider in the default composition path.
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- PBS is represented by a concrete provider object.
|
||||
- Default application composition registers PBS explicitly as a provider.
|
||||
- PBS remains functional through existing compile/build flows.
|
||||
- No additional real frontend is introduced.
|
||||
- No dynamic discovery mechanism is added.
|
||||
|
||||
## Tests
|
||||
|
||||
- Provider test: `PBSFrontendProvider.specification()` returns the PBS language id.
|
||||
- Provider test: `PBSFrontendProvider.compiler()` returns working compiler-facing behavior.
|
||||
- Composition test: default registry contains PBS as the only real provider.
|
||||
- Existing PBS compile/build tests continue to pass.
|
||||
|
||||
## Affected Artifacts
|
||||
|
||||
- PBS frontend module under `prometeu-compiler/frontends/prometeu-frontend-pbs/...`
|
||||
- `prometeu-app/src/main/java/p/studio/AppContainer.java`
|
||||
- Registry or application composition tests.
|
||||
@@ -1,74 +0,0 @@
|
||||
---
|
||||
id: PLN-0106
|
||||
ticket: multi-frontend-provider-contract
|
||||
title: Migrate common consumers to provider lookup
|
||||
status: done
|
||||
created: 2026-07-15
|
||||
ref_decisions: [DEC-0040]
|
||||
tags: [compiler, compiler-general, studio, frontend, registry, multi-frontend]
|
||||
---
|
||||
|
||||
## Briefing
|
||||
|
||||
DEC-0040 forbids common compiler, build pipeline, and Studio code from directly instantiating PBS-specific frontend services. After the registry API and PBS provider exist, consumers must move to provider lookup.
|
||||
|
||||
Domain owner: `compiler/general`, with impact on `studio`.
|
||||
|
||||
## Objective
|
||||
|
||||
Migrate common consumers from direct spec/phase/PBS access to provider-based lookup by `languageId`.
|
||||
|
||||
## Dependencies
|
||||
|
||||
- `PLN-0104` must provide provider lookup.
|
||||
- `PLN-0105` must register PBS as a provider.
|
||||
- Accepted decision: `DEC-0040`.
|
||||
|
||||
## Scope
|
||||
|
||||
- Audit common compiler, build pipeline, Studio, and app code for direct PBS frontend service construction.
|
||||
- Replace common code service lookup with provider lookup.
|
||||
- Make build pipeline frontend execution obtain compiler-facing behavior from `provider.compiler()`.
|
||||
- Make Studio project language catalog list specifications from providers.
|
||||
- Keep PBS-specific construction inside PBS provider or composition root only.
|
||||
- Add or update tests that prove common code does not directly instantiate `PBSFrontendPhaseService`.
|
||||
|
||||
## Non-Goals
|
||||
|
||||
- Do not remove compatibility registry APIs unless all callers have migrated and the removal is local.
|
||||
- Do not introduce new frontend behavior.
|
||||
- Do not change backend IR, validation boundaries, or lifecycle semantics beyond provider lookup.
|
||||
- Do not implement optional Studio language services that do not already exist.
|
||||
|
||||
## Execution Method
|
||||
|
||||
1. Search for `PBSFrontendPhaseService`, PBS frontend constructors, `getFrontendPhaseService`, and `getFrontendSpec` usage outside PBS and composition-owned code.
|
||||
2. Classify each usage as composition-owned, PBS-owned, or common consumer.
|
||||
3. Update common consumers to resolve `FrontendProvider` by `languageId`.
|
||||
4. Update `FrontendPhasePipelineStage` so it calls provider compiler behavior rather than direct phase lookup.
|
||||
5. Update `ProjectLanguageCatalogService` so its catalog is provider-derived.
|
||||
6. Keep compatibility wrappers only where they reduce migration risk and are provider-derived.
|
||||
7. Add architectural tests or focused unit tests that fail if common modules instantiate `PBSFrontendPhaseService` directly.
|
||||
8. Run relevant compiler, build pipeline, Studio, and app tests.
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- Common compiler/build pipeline/Studio code obtains frontend behavior through provider lookup.
|
||||
- Direct `PBSFrontendPhaseService` instantiation remains only in PBS provider or approved composition code.
|
||||
- `ProjectLanguageCatalogService` is provider-derived.
|
||||
- Unknown `languageId` failures remain clear after consumer migration.
|
||||
- PBS compile/build behavior remains unchanged.
|
||||
|
||||
## Tests
|
||||
|
||||
- Unit or integration test: build pipeline resolves PBS through provider and compiles an existing PBS fixture.
|
||||
- Unit test: Studio language catalog lists PBS from provider specs.
|
||||
- Architecture test or grep-backed test: common modules do not instantiate `PBSFrontendPhaseService`.
|
||||
- Existing PBS and build pipeline tests pass.
|
||||
|
||||
## Affected Artifacts
|
||||
|
||||
- `prometeu-compiler/prometeu-build-pipeline/src/main/java/p/studio/compiler/workspaces/stages/FrontendPhasePipelineStage.java`
|
||||
- `prometeu-studio/src/main/java/p/studio/projects/ProjectLanguageCatalogService.java`
|
||||
- Common code currently using `FrontendRegistryService.getFrontendSpec` or `getFrontendPhaseService`.
|
||||
- Tests in compiler, build pipeline, Studio, and app modules.
|
||||
Reference in New Issue
Block a user