You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "klease (via GitHub)" <gi...@apache.org> on 2023/11/17 21:12:31 UTC
[PR] CAMEL-20056: make it possible to set multiple headers at once. [camel]
klease opened a new pull request, #12067:
URL: https://github.com/apache/camel/pull/12067
Supported in Java, Yaml and Xml DSL.
# Description
<!--
- Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
-->
# Target
- [ ] I checked that the commit is targeting the correct branch (note that Camel 3 uses `camel-3.x`, whereas Camel 4 uses the `main` branch)
# Tracking
- [ ] If this is a large change, bug fix, or code improvement, I checked there is a [JIRA issue](https://issues.apache.org/jira/browse/CAMEL) filed for the change (usually before you start working on it).
<!--
# *Note*: trivial changes like, typos, minor documentation fixes and other small items do not require a JIRA issue. In this case your pull request should address just this issue, without pulling in other changes.
-->
# Apache Camel coding standards and style
- [ ] I checked that each commit in the pull request has a meaningful subject line and body.
<!--
If you're unsure, you can format the pull request title like `[CAMEL-XXX] Fixes bug in camel-file component`, where you replace `CAMEL-XXX` with the appropriate JIRA issue.
-->
- [ ] I have run `mvn clean install -DskipTests` locally and I have committed all auto-generated changes
<!--
You can run the aforementioned command in your module so that the build auto-formats your code. This will also be verified as part of the checks and your PR may be rejected if if there are uncommited changes after running `mvn clean install -DskipTests`.
You can learn more about the contribution guidelines at https://github.com/apache/camel/blob/main/CONTRIBUTING.md
-->
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "klease (via GitHub)" <gi...@apache.org>.
klease commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817488103
Failure in maven test due to org.apache.camel.support.jsse.TrustManagersParametersTest.testPropertyPlaceholders. I think this is due to parallel tests which are writing the same file in the target directory.
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1818804567
Okay maybe @zregvart can help out
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "klease (via GitHub)" <gi...@apache.org>.
klease commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1818631994
Thanks for committing Claus. It looks like the generation of the nav.adoc for the EIPs is broken. At least it's not done by running clean install in docs and it appears that that this is due to a not very recent change in gulpfile.js
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817921614
> > Much better description thanks - just noticed a little typo in "st the same time"
>
> Rats, silly me! That will change all the generated files again :-(. By the way, I can't figure out how the nav.doc for the eips is generated since building docs does the others but not that one.
You can try (if this works)
cd docs
mvn clean install
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817891264
Much better description thanks - just noticed a little typo in "st the same time"
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus merged PR #12067:
URL: https://github.com/apache/camel/pull/12067
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "zregvart (via GitHub)" <gi...@apache.org>.
zregvart commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1818947119
@klease can you file a JIRA for the issue you're facing? I can run `./mvnw -pl :docs` successfully on my end.
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817921897
Also it would be good to add a TIP in setHeader doc to link to this new one so users can more easily be aware of this variation
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817112799
: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.
* You can label PRs using `build-all`, `build-dependents`, `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-20056: make it possible to set multiple headers at once. [camel]
Posted by "klease (via GitHub)" <gi...@apache.org>.
klease commented on code in PR #12067:
URL: https://github.com/apache/camel/pull/12067#discussion_r1398423100
##########
core/camel-core-model/src/main/java/org/apache/camel/model/SetHeadersDefinition.java:
##########
@@ -0,0 +1,118 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.model;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+
+import jakarta.xml.bind.annotation.XmlAccessType;
+import jakarta.xml.bind.annotation.XmlAccessorType;
+import jakarta.xml.bind.annotation.XmlElementRef;
+import jakarta.xml.bind.annotation.XmlRootElement;
+
+import org.apache.camel.Expression;
+import org.apache.camel.builder.ExpressionBuilder;
+import org.apache.camel.spi.Metadata;
+
+/**
+ * A sequence of setHeader operations.
Review Comment:
setHeaders-eip.adoc added and description updated.
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817543266
> Failure in maven test due to org.apache.camel.support.jsse.TrustManagersParametersTest.testPropertyPlaceholders. I think this is due to parallel tests which are writing the same file in the target directory.
Yes it seems to be - we need to either isolate these tests or fix them so they have their private files
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on code in PR #12067:
URL: https://github.com/apache/camel/pull/12067#discussion_r1398259421
##########
core/camel-core-model/src/main/java/org/apache/camel/model/SetHeadersDefinition.java:
##########
@@ -0,0 +1,118 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.model;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+
+import jakarta.xml.bind.annotation.XmlAccessType;
+import jakarta.xml.bind.annotation.XmlAccessorType;
+import jakarta.xml.bind.annotation.XmlElementRef;
+import jakarta.xml.bind.annotation.XmlRootElement;
+
+import org.apache.camel.Expression;
+import org.apache.camel.builder.ExpressionBuilder;
+import org.apache.camel.spi.Metadata;
+
+/**
+ * A sequence of setHeader operations.
Review Comment:
Can we update this to better tell the user what it does, something like:
Allows to set multiple headers at once on the message.
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "klease (via GitHub)" <gi...@apache.org>.
klease commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1819185949
@zregvart CAMEL-20135
--
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-20056: make it possible to set multiple headers at once. [camel]
Posted by "klease (via GitHub)" <gi...@apache.org>.
klease commented on PR #12067:
URL: https://github.com/apache/camel/pull/12067#issuecomment-1817906102
> Much better description thanks - just noticed a little typo in "st the same time"
Rats, silly me! That will change all the generated files again :-(. By the way, I can't figure out how the nav.doc for the eips is generated since building docs does the others but not that one.
--
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