Re: [PR] Allow JDK23 compatibility for Subject#getSubject [cxf]
reta commented on PR #1972: URL: https://github.com/apache/cxf/pull/1972#issuecomment-2474459778 > @reta are there any plans to increase the Java baseline to 18 or newer? For 4.1.0, we are settled on JDK-17 at the moment, I think we could go with at least with JDK-21 for 4.2.0, but it is largely dictated by our dependencies (Spring, etc) and the projects that depend on us (fe Microprofile Rest client, etc), thank @ppalaga -- 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: dev-unsubscr...@cxf.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] Allow JDK23 compatibility for Subject#getSubject [cxf]
ppalaga commented on PR #1972: URL: https://github.com/apache/cxf/pull/1972#issuecomment-2474433622 @reta are there any plans to increase the Java baseline to 18 or newer? If so, we could start using `Subject.current()` instead of `Subject.getSubject(AccessController.getContext())` and catching `UnsupportedOperationException` which may harm the performance. Even before upgrading the baseline, we could perhaps avoid calling `Subject.getSubject(AccessController.getContext())` if the current Java Runtime is 18+ and `System.getSecurityManager()` returns null. That might be faster. WDYT? -- 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: dev-unsubscr...@cxf.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: CXF JAX-RS: working with multipart form-data
Hi Jean, JPU> When looking at the classes MultipartProvider and JAXRSUtils (cxf v3.5.9) JPU> then it shows that only object for which a 'Content-Disposition' header will JPU> be written is a File Object. The problem is that my application is JPU> generating the file content on the fly, so I have it either as a byte[] or JPU> InputStream. I believe the 'Content-Disposition' will be written for File and Attachment. Respectively, it is going to be read for these multipart content parts as well. This is why the @Multipart annotation has no 'Content-Disposition' or alike (I think). > JPU> Even passing a List doesn't work as the MultiPartProvider > will JPU> loop through the list and try to create a DataHandler for an Attachment JPU> object which is also not supported (throws an exception). This is surprising, I will take a look shortly why it does not work. What kind of exception are you getting? Thank you. Best Regards, Andriy Redko JPU> Hi Andriy, JPU> When looking at the classes MultipartProvider and JAXRSUtils (cxf v3.5.9) JPU> then it shows that only object for which a 'Content-Disposition' header will JPU> be written is a File Object. The problem is that my application is JPU> generating the file content on the fly, so I have it either as a byte[] or JPU> InputStream. JPU> This surprises me as according to JPU> https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Disposition: JPU> "a multipart/form-data body requires a Content-Disposition header to provide JPU> information about each subpart of the form (e.g., for every form field and JPU> any files that are part of field data)". JPU> Also the Multipart annotation class only allows to specify Content-Type, JPU> Content-ID so there is no way for me to provide 'Content-Disposition' JPU> information on objects like byte[] or InputStream. JPU> Even passing a List doesn't work as the MultiPartProvider will JPU> loop through the list and try to create a DataHandler for an Attachment JPU> object which is also not supported (throws an exception). JPU> The only way I see to pass it is to construct Attachment objects for each JPU> multipart part, with 'Content-Disposition' set, and add them all to a JPU> MultipartBody object and pass this as input parameter to my method JPU> signature. But then I loose all swager information for input objects that JPU> are not byte[] or InputStream. JPU> Am I missing something? JPU> Regards, JPU> J.P. JPU> -Oorspronkelijk bericht- JPU> Van: Andriy Redko JPU> Verzonden: vrijdag 4 oktober 2024 2:52 JPU> Aan: Jean Pierre URKENS ; JPU> dev@cxf.apache.org JPU> Onderwerp: Re: CXF JAX-RS: working with multipart form-data JPU> Hi Jean, JPU> Yeah, I think the @Multipart + Attachment may not work, but you could accept JPU> the List instead, right? (since you send many). JPU> The logging configuration does not seem right: you use interceptors AND JPU> feature (as per snippet below). JPU> factory.getOutInterceptors().add(new JPU> LoggingOutInterceptor()); JPU> factory.getInInterceptors().add(new JPU> LoggingInInterceptor()); JPU> LoggingFeature feature = new LoggingFeature(); JPU> feature.setLogMultipart(true); JPU> feature.setLogBinary(true); JPU> ... JPU> You only need one of those, either interceptors (please configure JPU> setLogBinary & setLogMultipart for them): JPU> factory.getOutInterceptors().add(new JPU> LoggingOutInterceptor()); JPU> factory.getInInterceptors().add(new JPU> LoggingInInterceptor()); JPU> Or feature: JPU> LoggingFeature feature = new LoggingFeature(); JPU> feature.setLogMultipart(true); JPU> feature.setLogBinary(true); JPU> ... JPU> Hope it helps, thanks! JPU> Best Regards, JPU> Andriy Redko JPU>> Hi Andriy, JPU>> Thanks for the swift response, but I could still use some JPU> clarifications on: JPU>> 1) You mention that passing an Attachment object as service method JPU>> parameter should work. JPU>> My initial test setup did pass an Attachment object as input JPU>> parameter as shown in ">>> 1)API interface declaration" in my mail. However when the JPU>> client (see code below) tries to send a request with this JPU>> signature, the JPU>> JAXRSUtils.writeMessageBody(...) method that is called by the CXF JPU>> stack throws an exception on the Attachment parameter saying: JPU>> okt 03, 2024 9:46:54 AM JPU>> org.apache.cxf.jaxrs.provider.MultipartProvider JPU>> getHandlerForObject SEVERE: No message body writer found for class JPU>> : class org.apache.cxf.jaxrs.ext.multipart.Attachment. JPU>> okt 03, 2024 9:47:05 AM JPU>> org.apache.cxf.jaxrs.utils.JAXRSUtils JPU>> logMessageHandlerProblem SEVERE: Problem with writing the data, JPU>> class java.util.ArrayList, ContentType: multipart/form-data JPU>> okt 03, 2024 9:47:14 AM JPU>
[PR] Bump org.apache.maven.plugins:maven-dependency-plugin from 3.8.0 to 3.8.1 [cxf-xjc-utils]
dependabot[bot] opened a new pull request, #196: URL: https://github.com/apache/cxf-xjc-utils/pull/196 Bumps [org.apache.maven.plugins:maven-dependency-plugin](https://github.com/apache/maven-dependency-plugin) from 3.8.0 to 3.8.1. Release notes Sourced from https://github.com/apache/maven-dependency-plugin/releases";>org.apache.maven.plugins:maven-dependency-plugin's releases. 3.8.1 What's Changed Bump org.apache.maven.doxia:doxia-sink-api from 2.0.0-M12 to 2.0.0 by https://github.com/dependabot";>@dependabot in https://redirect.github.com/apache/maven-dependency-plugin/pull/432";>apache/maven-dependency-plugin#432 [MDEP-956][MDEP-932] Silence artifact copying by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/436";>apache/maven-dependency-plugin#436 Minor copy editing by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/437";>apache/maven-dependency-plugin#437 [MDEP-958] Bump org.apache.maven.shared:maven-dependency-analyzer from 1.14.1 to 1.15.0 by https://github.com/dependabot";>@dependabot in https://redirect.github.com/apache/maven-dependency-plugin/pull/434";>apache/maven-dependency-plugin#434 Bump org.apache.maven.reporting:maven-reporting-api from 4.0.0-M12 to 4.0.0 by https://github.com/dependabot";>@dependabot in https://redirect.github.com/apache/maven-dependency-plugin/pull/435";>apache/maven-dependency-plugin#435 [MNGSITE-393] Cleanup and correct usage docs by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/440";>apache/maven-dependency-plugin#440 Replace old workaround for Maven 3.2.5 bug by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/438";>apache/maven-dependency-plugin#438 Delete obsolete commented code by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/446";>apache/maven-dependency-plugin#446 [MDEP-930] Make test robust against platform default character sets by https://github.com/elharo";>@elharo in https://redirect.github.com/apache/maven-dependency-plugin/pull/448";>apache/maven-dependency-plugin#448 ... (truncated) Commits https://github.com/apache/maven-dependency-plugin/commit/954e44a6f6bdb9f827cef95cff8a9509f86a7ed2";>954e44a [maven-release-plugin] prepare release maven-dependency-plugin-3.8.1 https://github.com/apache/maven-dependency-plugin/commit/842075d72d371459450db3a854b013a0a946c23d";>842075d Bump org.apache.maven.reporting:maven-reporting-impl https://github.com/apache/maven-dependency-plugin/commit/7e1aadcd74bc9b48b96d3c3f9e450d69f7552894";>7e1aadc Bump org.apache.commons:commons-lang3 from 3.14.0 to 3.17.0 https://github.com/apache/maven-dependency-plugin/commit/188531ca74cbb80225d4d470c99039ee2dbc8911";>188531c Fix SCM tag https://github.com/apache/maven-dependency-plugin/commit/361058e3c235f0524d91efa006b1b2f2d59efbe8";>361058e Bump jettyVersion from 9.4.55.v20240627 to 9.4.56.v20240826 https://github.com/apache/maven-dependency-plugin/commit/38ab10076724a01ed7e51d1a665019b1e0b67fff";>38ab100 Bump org.codehaus.plexus:plexus-io from 3.5.0 to 3.5.1 https://github.com/apache/maven-dependency-plugin/commit/cbac4a785843953cb8408b0eb75b16ad38d5574d";>cbac4a7 Bump commons-io:commons-io from 2.16.1 to 2.17.0 https://github.com/apache/maven-dependency-plugin/commit/b19b7e027085fb215f8f510d7bef8033ecbd4d48";>b19b7e0 [MDEP-930] Make test robust against platform default character sets (https://redirect.github.com/apache/maven-dependency-plugin/issues/448";>#448) https://github.com/apache/maven-dependency-plugin/commit/e347ef7298c9064be7f0774a4e00f94d7d407fcc";>e347ef7 Delete obsolete commented code for issue that was won't fixed 10 years ago (#... https://github.com/apache/maven-dependency-plugin/commit/7b137a17cc71b001e79992b755471a3fbb9702c8";>7b137a1 [MDEP-946] Add analyze exclusions to list of goals Additional commits viewable in https://github.com/apache/maven-dependency-plugin/compare/maven-dependency-plugin-3.8.0...maven-dependency-plugin-3.8.1";>compare view [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- Dependabot commands and opt
Re: [PR] Bump org.apache.maven.plugins:maven-dependency-plugin from 3.8.0 to 3.8.1 [cxf-xjc-utils]
reta merged PR #196: URL: https://github.com/apache/cxf-xjc-utils/pull/196 -- 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: dev-unsubscr...@cxf.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org