appmap.yml packages path matching zero classes yields a healthy-looking recording with no warning
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 3/5
- Tempo estimado
- 1-2 dias
- Facilidade para iniciantes
- 45/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- java
- Domínio
- observability
Direção de pesquisa
Start with the packages: handling in appmap.yml config loading and the bytecode instrumentation of application classes; the issue does not name the source files. Reproduce by running PetClinicIntegrationTests#testOwnerDetails with a misspelled package path and check the recording size and stderr. Done when a path matching zero classes prints a warning naming that entry, and an all-zero config fails with an error.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Summary
An appmap.yml whose packages: paths match zero classes produces a recording that looks healthy (HTTP route, status, SQL all present) with no warning. Not one line of application code is captured. With no appmap.yml the agent auto-detects the package and the recording is complete, so a wrong config is strictly worse than no config.
Agent 1.30.1, CLI 3.203.0, spring-petclinic @ b26f235, Java 17.
Repro
# appmap.yml (real package is ...petclinic.owner; one-character typo)
packages:
- path: org.springframework.samples.petclinic.owners
mvn -Dtest=PetClinicIntegrationTests#testOwnerDetails test
appmap query endpoints --appmap-dir tmp/appmap
appmap query find queries --appmap-dir tmp/appmap --limit 3
Observed
No warning from agent or CLI. endpoints shows GET /owners/{ownerId} 200, find queries shows the eight expected SQL statements. The only tell is the file size (3.2 KB vs 8.6 KB with the right config) and an empty appmap query hotspots.
Cause
packages: governs only bytecode instrumentation of application classes; HTTP and JDBC events come from framework hooks that do not consult it. "Zero classes matched" is not treated as an error or warning, and the configured path is never validated against the classpath.
Expected
At the end of a recording the agent knows how many classes each path: entry instrumented. A path: matching zero classes should warn on stderr naming the entry; a config where every entry matched zero classes should be a hard error, not a silent 3 KB recording.
- Linguagem predominante
- Java
- Estrelas
- 88
- Forks
- 17
- Merge médio
- 2d 2h
- PRs com merge (30d)
- 1
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de getappmap/appmap-java
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 28/100
getappmap/appmap-java#333 ·
-
Git metadata dropped in a git worktree (.git file with gitdir: pointer not followed)Talvez já em andamento @dividedmind assumiu há 1 dia. Aberta
getappmap/appmap-java#331 · 1 comentário · 1 responsável ·
-
Labeled methods should always be recorded, even if they match trivial-method filtersTalvez já em andamento @kgilpin assumiu há 191 dias. Aberta
getappmap/appmap-java#323 · 1 reação · 2 responsáveis ·
-
Warning with Java 25Aberta
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 35/100
getappmap/appmap-java#322 ·
-
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 35/100
getappmap/appmap-java#308 ·
Todas as issues de getappmap/appmap-java
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
sqlcipher/sqlcipher-android#97 · 1 comentário ·
-
bug IIIF interoperability
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
Netcracker/qubership-integration-platform#1046 ·
Mantenedores costumam responder em até 2 dias
-
`check_java_version()` fails when Java path contains spaces (Windows / Git Bash, `C:\Program Files`)Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100