You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "davsclaus (via GitHub)" <gi...@apache.org> on 2026/10/05 06:45:11 UTC

[PR] CAMEL-25330: camel-groovy - a property read on a body that is still text says to unmarshal it first [camel]

davsclaus opened a new pull request, #27359:
URL: https://github.com/apache/camel/pull/27359

   https://issues.apache.org/jira/browse/CAMEL-25330
   
   A Groovy expression such as `body.find { it.sku == headers.sku }` on a body that was never unmarshalled iterates the bytes (or characters) of the payload and fails with `No such property: sku for class: java.lang.Byte`. The hint used to list the script variables, which were not the problem.
   
   When the missing property was looked up on a `Byte`, `Character` or `String` and the body is a `byte[]` or `String`, the hint now says: the body is still text (a byte[]), not parsed data: unmarshal it first (unmarshal: json for JSON) to read its fields.
   
   Found in the local-model benchmark (contracts/openapi-server): 2 of 5 runs left out the unmarshal before a Groovy lookup and got the old message.
   
   Tests: `GroovyMissingPropertyHintTest` (byte[], String, and a parsed List that still works).
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   https://claude.ai/code/session_01STT6whBgK1AqsSsUKrnE8m


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25330: camel-groovy - a property read on a body that is still text says to unmarshal it first [camel]

Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus merged PR #27359:
URL: https://github.com/apache/camel/pull/27359


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25330: camel-groovy - a property read on a body that is still text says to unmarshal it first [camel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #27359:
URL: https://github.com/apache/camel/pull/27359#issuecomment-5989511970

   :star2: Thank you for your contribution to the Apache Camel project! :star2:
     :robot: CI automation will test this PR automatically.
   
     :camel: Apache Camel Committers, please review the following items:
   
     * First-time contributors **require MANUAL approval** for the GitHub Actions to run
     * You can use the command `/component-test (camel-)component-name1 (camel-)component-name2..` to request a test from the test bot although they are normally detected and executed by CI.
     * You can label PRs using `skip-tests` and `test-dependents` to fine-tune the checks executed by this PR.
     * Build and test logs are available in the summary page. **Only** [Apache Camel committers](https://camel.apache.org/community/team/#committers) have access to the summary.
     
     :warning: Be careful when sharing logs. Review their contents before sharing them publicly.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] CAMEL-25330: camel-groovy - a property read on a body that is still text says to unmarshal it first [camel]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #27359:
URL: https://github.com/apache/camel/pull/27359#issuecomment-5990069270

   <!-- ci-tested-modules -->
   :test_tube: **CI tested the following changed modules:**
   
   - `components/camel-groovy`
   
   ---
   
   <details><summary>:microscope: Scalpel shadow comparison — Scalpel: 18 of 698 tested, 27 compile-only — current: 18 all tested</summary>
   
   [Maveniverse Scalpel](https://github.com/maveniverse/scalpel) detected **18 affected modules** (current approach: 18).
   
   **Skip-tests mode would test 18 modules** (1 direct + 17 downstream), **skip tests for 27** (generated code, meta-modules)
   
   <details><summary>Modules Scalpel would test (18)</summary>
   
   - `camel-groovy` ← components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyExpression.java, components/camel-groovy/src/test/java/org/apache/camel/processor/groovy/GroovyMissingPropertyHintTest.java
   - `camel-iso8583` ← downstream of org.apache.camel:camel-groovy
   - `camel-jbang-mcp` ← downstream of org.apache.camel:camel-xml-io-dsl
   - `camel-jbang-plugin-mcp` ← downstream of org.apache.camel:camel-jbang-core
   - `camel-jbang-plugin-route-parser` ← downstream of org.apache.camel:camel-route-parser
   - `camel-jbang-plugin-tui` ← downstream of org.apache.camel:camel-catalog
   - `camel-jbang-plugin-validate` ← downstream of org.apache.camel:camel-yaml-dsl-validator
   - `camel-kamelet` ← downstream of org.apache.camel:camel-groovy
   - `camel-launcher-container` ← downstream of org.apache.camel:camel-launcher
   - `camel-once` ← downstream of org.apache.camel:camel-groovy
   - `camel-semantic` ← downstream of org.apache.camel:camel-xml-io-dsl
   - `camel-state-store` ← downstream of org.apache.camel:camel-test-main-junit5
   - `camel-test-main-junit5` ← downstream of org.apache.camel:camel-xml-io-dsl
   - `camel-test-main-junit6` ← downstream of org.apache.camel:camel-xml-io-dsl
   - `camel-typesafe-ai` ← downstream of org.apache.camel:camel-xml-io-dsl
   - `camel-xml-io-dsl` ← downstream of org.apache.camel:camel-groovy
   - `camel-yaml-dsl-validator` ← downstream of org.apache.camel:camel-catalog
   - `camel-yaml-dsl-validator-maven-plugin` ← downstream of org.apache.camel:camel-yaml-dsl-validator
   
   </details>
   
   <details><summary>Modules with tests skipped (27)</summary>
   
   - `apache-camel`
   - `camel-allcomponents`
   - `camel-catalog`
   - `camel-catalog-console`
   - `camel-catalog-maven`
   - `camel-catalog-suggest`
   - `camel-componentdsl`
   - `camel-endpointdsl`
   - `camel-endpointdsl-support`
   - `camel-itest`
   - `camel-jbang-core`
   - `camel-jbang-it`
   - `camel-jbang-main`
   - `camel-jbang-plugin-edit`
   - `camel-jbang-plugin-generate`
   - `camel-jbang-plugin-kubernetes`
   - `camel-jbang-plugin-test`
   - `camel-kamelet-main`
   - `camel-launcher`
   - `camel-report-maven-plugin`
   - `camel-route-parser`
   - `camel-yaml-dsl`
   - `camel-yaml-dsl-deserializers`
   - `camel-yaml-dsl-maven-plugin`
   - `coverage`
   - `docs`
   - `dummy-component`
   
   </details>
   
   > :information_source: Shadow mode — Scalpel observes but does not affect test execution. [Learn more](https://github.com/maveniverse/scalpel)
   
   </details>
   
   <details><summary>All tested modules (45 modules, 7m 12s total)</summary>
   
   **Total reactor time:** 7m 12s
   
   | Module | Duration | Status |
   | --- | --- | --- |
   | Camel :: Launcher | 45.7s | SUCCESS |
   | Camel :: JBang :: Plugin :: TUI | 41.5s | SUCCESS |
   | Camel :: JBang :: MCP | 38.4s | SUCCESS |
   | Camel :: Catalog :: Camel Catalog | 23.0s | SUCCESS |
   | Camel :: Groovy | 21.0s | SUCCESS |
   | Camel :: AI :: TypeSafe AI | 20.2s | SUCCESS |
   | Camel :: Component DSL | 19.6s | SUCCESS |
   | Camel :: YAML DSL :: Validator | 18.5s | SUCCESS |
   | Camel :: Kamelet | 18.1s | SUCCESS |
   | Camel :: YAML DSL | 17.8s | SUCCESS |
   | Camel :: JBang :: Plugin :: Kubernetes | 17.3s | SUCCESS |
   | Camel :: Docs | 15.2s | SUCCESS |
   | Camel :: Kamelet Main | 13.6s | SUCCESS |
   | Camel :: Test :: Main :: JUnit5 | 12.9s | SUCCESS |
   | Camel :: Test :: Main :: JUnit6 | 12.3s | SUCCESS |
   | Camel :: AI :: Semantic Evaluation | 10.2s | SUCCESS |
   | Camel :: XML DSL with camel-xml-io | 9.4s | SUCCESS |
   | Camel :: Catalog :: Camel Report Maven Plugin | 8.0s | SUCCESS |
   | Camel :: JBang :: Plugin :: Testing | 7.6s | SUCCESS |
   | Camel :: Once | 7.4s | SUCCESS |
   | Camel :: ISO-8583 | 6.8s | SUCCESS |
   | Camel :: Catalog :: Camel Route Parser | 6.6s | SUCCESS |
   | Camel :: YAML DSL :: Deserializers | 6.6s | SUCCESS |
   | Camel :: JBang :: Plugin :: Validate | 5.1s | SUCCESS |
   | Camel :: All Components Sync point | 4.1s | SUCCESS |
   | Camel :: YAML DSL :: Validator Maven Plugin | 3.8s | SUCCESS |
   | Camel :: State Store | 3.7s | SUCCESS |
   | Camel :: Catalog :: Maven | 2.4s | SUCCESS |
   | Camel :: YAML DSL :: Maven Plugins | 2.2s | SUCCESS |
   | Camel :: Catalog :: Suggest (deprecated) | 1.6s | SUCCESS |
   | Camel :: Assembly | 1.6s | SUCCESS |
   | Camel :: JBang :: Plugin :: Edit | 1.4s | SUCCESS |
   | Camel :: Coverage | 1.2s | SUCCESS |
   | Camel :: JBang :: Integration tests | 1.1s | SUCCESS |
   | Camel :: JBang :: Plugin :: Generate | 1.0s | SUCCESS |
   | Camel :: Endpoint DSL :: Support | 0.8s | SUCCESS |
   | Camel :: Launcher :: Container | 0.7s | SUCCESS |
   | Camel :: Catalog :: Dummy Component | 0.7s | SUCCESS |
   | Camel :: JBang :: Main | 0.7s | SUCCESS |
   | Camel :: JBang :: Plugin :: MCP | 0.6s | SUCCESS |
   | Camel :: Catalog :: Console | 0.5s | SUCCESS |
   | Camel :: JBang :: Plugin :: Route Parser | 0.5s | SUCCESS |
   | Camel :: Endpoint DSL | n/a |  |
   | Camel :: Integration Tests | n/a |  |
   | Camel :: JBang :: Core | n/a |  |
   
   **Top 20 slowest modules:**
   - `Camel :: Launcher` (45.7s)
   - `Camel :: JBang :: Plugin :: TUI` (41.5s)
   - `Camel :: JBang :: MCP` (38.4s)
   - `Camel :: Catalog :: Camel Catalog` (23.0s)
   - `Camel :: Groovy` (21.0s)
   - `Camel :: AI :: TypeSafe AI` (20.2s)
   - `Camel :: Component DSL` (19.6s)
   - `Camel :: YAML DSL :: Validator` (18.5s)
   - `Camel :: Kamelet` (18.1s)
   - `Camel :: YAML DSL` (17.8s)
   - `Camel :: JBang :: Plugin :: Kubernetes` (17.3s)
   - `Camel :: Docs` (15.2s)
   - `Camel :: Kamelet Main` (13.6s)
   - `Camel :: Test :: Main :: JUnit5` (12.9s)
   - `Camel :: Test :: Main :: JUnit6` (12.3s)
   - `Camel :: AI :: Semantic Evaluation` (10.2s)
   - `Camel :: XML DSL with camel-xml-io` (9.4s)
   - `Camel :: Catalog :: Camel Report Maven Plugin` (8.0s)
   - `Camel :: JBang :: Plugin :: Testing` (7.6s)
   - `Camel :: Once` (7.4s)
   
   </details>
   
   ---
   :gear: [View full build and test results](https://github.com/apache/camel/actions/runs/37275402617)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org