Re: [jackson-user] Nested Polymorphic Deserialization using @JsonTypeInfo?

2024-05-21 Thread Tatu Saloranta
On Tue, May 21, 2024 at 9:23 PM Chuanwise Rafter wrote: > > I need to deserialize incoming packet encoded in JSON. For example, there are > two kind of packet: Son and Daughter. The rules are: > > If field "type" is not "sub", error occurred. > If field "type" is "sub", checking field

Re: [jackson-user] CVE-2023-5072 jackson-core-2.16.0

2024-05-03 Thread Tatu Saloranta
As per my note on the Github issue that you also filed, no, this does not related to Jackson. Case of false positive (bad metadata). -+ Tatu +- On Fri, May 3, 2024 at 10:46 AM leducquan wrote: > > Recently, when running the OWASP Dependency-Check tool on my project, > jackson-core-2.16.0.jar

Re: [jackson-user] jackson-core shading of ch.randelshofer:fastdoubleparser

2024-04-15 Thread Tatu Saloranta
numbers legal package path pieces? Would you mind filing a Github issue for `jackson-core` for this? I am not 100% sure how to split the version number in pom.xml, but I suspect there are ways to do that. -+ Tatu +- > > > On Mon, Apr 15, 2024 at 3:39 PM Tatu Saloranta wrote: >> >>

Re: [jackson-user] jackson-core shading of ch.randelshofer:fastdoubleparser

2024-04-15 Thread Tatu Saloranta
rser was shaded, it was a dot release - so the likelihood of > changes was higher. However, now there is a 1.0 release, so theoretically it > will be more stable. Be that as it may; at this point I prefer keeping FDP shaded. I am +0 on changing shaded package name prefix, but could be convinced to d

Re: [jackson-user] jackson-core shading of ch.randelshofer:fastdoubleparser

2024-04-12 Thread Tatu Saloranta
On Fri, Apr 12, 2024 at 2:09 PM Josh Curry wrote: > > It was recently discovered another library is using one of the fastdouble > shaded classes from jackson-core. > > https://github.com/aws/event-ruler/blob/main/src/main/software/amazon/event/ruler/ByteMachine.java#L3 > > Since the relocated

[jackson-user] Jackson project joining CommonHaus Foundation

2024-04-09 Thread Tatu Saloranta
Ok, so quick note: as part of general announcement about new CommonHaus Foundation: https://github.com/commonhaus/foundation/discussions/123 I also wrote about Jackson project joining this new foundation over next couple of months (if all goes well):

Re: [jackson-user] Suppress an empty xml tag

2023-12-02 Thread Tatu Saloranta
On Fri, Dec 1, 2023 at 11:21 PM thom...@gmail.com wrote: > > I have an optional tag in my schema. If it is null, I want to not place the > tag in the doc. Currently, I get > > > > Which is not terrible, but not necessary. The quickest way is probably to use annotation `@JsonInclude` on POJO or

Re: [jackson-user] Wrong tag names on xml serialize

2023-11-29 Thread Tatu Saloranta
On Wed, Nov 29, 2023 at 11:48 AM Tatu Saloranta wrote: > > On Wed, Nov 29, 2023 at 5:08 AM thom...@gmail.com wrote: > > > > I have a gradle project. I tried gradlew clean jar and it made no changes > > to the behavior. > > > > You can pull from here: h

Re: [jackson-user] Wrong tag names on xml serialize

2023-11-29 Thread Tatu Saloranta
least repo the issue. -+ Tatu +- > > On Saturday, November 25, 2023 at 9:54:58 PM UTC-5 Tatu Saloranta wrote: >> >> On Sat, Nov 25, 2023 at 6:01 PM Tatu Saloranta wrote: >> > >> > On Sat, Nov 25, 2023 at 10:42 AM thom...@gmail.com >> > wrote: >> > > &

Re: [jackson-user] Wrong tag names on xml serialize

2023-11-25 Thread Tatu Saloranta
On Sat, Nov 25, 2023 at 6:01 PM Tatu Saloranta wrote: > > On Sat, Nov 25, 2023 at 10:42 AM thom...@gmail.com wrote: > > > > Hello, again. > > > > I am trying to pull in OSIS documents and then create an OSIS document. I > > am read

Re: [jackson-user] PackageVersion

2023-11-25 Thread Tatu Saloranta
On Sat, Nov 25, 2023 at 4:41 PM thom...@gmail.com wrote: > > I have pulled the 2.17 branch of jackson-dataformat-xml and am attempting to > rercreate my issue.There seems to be a build issue missing PackageVersion. I > have found this note in PackageVersion.java.in > > /** > * Automatically

Re: [jackson-user] Wrong tag names on xml serialize

2023-11-25 Thread Tatu Saloranta
On Sat, Nov 25, 2023 at 10:42 AM thom...@gmail.com wrote: > > Hello, again. > > I am trying to pull in OSIS documents and then create an OSIS document. I am > reading the following lines, for example: > > > חֲז֖וֹן > עֹֽבַדְיָ֑ה > > here is the definition I'm using

Re: [jackson-user] Unrecognized field ""

2023-11-17 Thread Tatu Saloranta
Good! -+ Tatu +- On Fri, Nov 17, 2023 at 12:33 PM thom...@gmail.com wrote: > > Thanks, that fixed it. > > On Friday, November 17, 2023 at 3:14:42 PM UTC-5 Tatu Saloranta wrote: >> >> Typically you would file an issue for the component mentioned. >> >> Bu

Re: [jackson-user] Unrecognized field ""

2023-11-17 Thread Tatu Saloranta
Typically you would file an issue for the component mentioned. But in this case you need -- as per my other answer -- another property, annotated with `@JacksonXmlText`, to map character data into. Hope this helps, -+ Tatu +- On Fri, Nov 17, 2023 at 11:16 AM thom...@gmail.com wrote: > > I

Re: [jackson-user] Gettting access to body

2023-11-17 Thread Tatu Saloranta
On Fri, Nov 17, 2023 at 11:53 AM thom...@gmail.com wrote: > > I am parsing the following line: > > חֲז֖וֹן > > I have created a class, OsisWord, for this line of text and have properties > set up for lemma, morph, etc. How do I access the body text between the tags? Add one more

Re: [jackson-user] XML serialization: UnsupportedOperationException: Not implemented

2023-10-18 Thread Tatu Saloranta
stxInputFactory) and XMLOutputFactory (WstxOutputFactory). -+ Tatu +- > > On Wednesday, October 11, 2023 at 11:01:33 PM UTC+2 Tatu Saloranta wrote: >> >> On Wed, Oct 11, 2023 at 12:29 AM mlic...@gmail.com wrote: >> > >> > Hi >> > I have this issue occur

Re: [jackson-user] XML serialization: UnsupportedOperationException: Not implemented

2023-10-11 Thread Tatu Saloranta
On Wed, Oct 11, 2023 at 12:29 AM mlic...@gmail.com wrote: > > Hi > I have this issue occur randomly and wonder how Jackson binds to an XML > writer? By default underlying Stax implementation to use is detected using Java platform SPI interface. If you do not include specific implementation it

Re: [jackson-user] Let FilteringParserDelegate fail when a matching property does not exist

2023-09-22 Thread Tatu Saloranta
includeProperty()` works "reactively" against the >> actual incoming JSON stream. Then, it works for matching properties, but >> it could not work for non-match. (In the example, `includeProperty()` might >> never be called against "foo" while reading {"xxx":{"y

Re: [jackson-user] Let FilteringParserDelegate fail when a matching property does not exist

2023-09-22 Thread Tatu Saloranta
I wondered if some of them > could be used, but not dived deeper yet. Or, otherwise, I thought that I might > have to hack `FilteringParserDelegate` reimplemented. Right, I think `TokenFilter.filterFinishObject()` and checking nesting allows you to detect absence of content (assuming you keep t

Re: [jackson-user] Let FilteringParserDelegate fail when a matching property does not exist

2023-09-19 Thread Tatu Saloranta
On Tue, Sep 19, 2023 at 10:31 AM Dai MIKURUBE wrote: > > Hi, > > I have a sequence of multiple JSONs in a stream, and wanted to filter the > sequence by FilteringParserDelegate / JsonPointerBasedFilter. > > It works in normal matching cases. But, I wanted to raise an error when a > matching

Re: [jackson-user] Field level Custom Annotation for JsonPointer expression

2023-09-19 Thread Tatu Saloranta
ght it could be annotations are not copied during annotation >> processing. >> Definitely I will give it a try without lombok annotations. >> >> >> >> On Tuesday, September 19, 2023 at 2:27:49 PM UTC+10 Tatu Saloranta wrote: >>> >>> On Sun, Sep 17, 20

Re: [jackson-user] Field level Custom Annotation for JsonPointer expression

2023-09-18 Thread Tatu Saloranta
On Sun, Sep 17, 2023 at 9:39 PM Aditya Pant wrote: > > Hello Jackson community, > > The input Json have nested fields and different field names. I am looking for > a way to deserilize using JsonPointer espression (because it allows path > lookup). > > I have tried several approaches but none of

Re: [jackson-user] Simple(Des|S)erializers not a good fit for handling generic types: what is a good fit?

2023-09-01 Thread Tatu Saloranta
Correct, `SimpleSerializers`/`-Deserializers` won't work for generic types in general, and structured types specifically. On implementations that do support these, `jackson-datatype-guava` from https://github.com/FasterXML/jackson-datatypes-collections/ might be a good example: it supports some

Re: [jackson-user] Re: convertValue ignore anySetter/anyGettter

2023-08-18 Thread Tatu Saloranta
On Wed, Aug 16, 2023 at 7:35 AM Ken Hancock wrote: > > Success. I used the setAnnotationIntrospector to essentially remove the > @JsonAnyGetter(): > > ObjectMapper mapper = new ObjectMapper(); > > mapper.setAnnotationIntrospector(new JacksonAnnotationIntrospector() { > @Override > public

Re: [jackson-user] serializing and deserializing issues on version update from jackson 2.7.4 to 2.15.0.

2023-08-09 Thread Tatu Saloranta
Please either file an issue with reproduction (unit test), or include actual description of specific differences. General question of "what changed" will not get you much since you are both missing important details (actual Java class definition(s), configuration of ObjectMapper) and include a

Re: [jackson-user] Jackson compatibility with JAVA 17

2023-07-25 Thread Tatu Saloranta
On Fri, Jul 21, 2023 at 6:57 PM NIKITAH wrote: > > Hi All, > > I am using below components from FASTERXML, I have plan to upgrade my java > compilation from 1.8 to JDK 17. Need to check on the compatibility of the > below to compile on JDK 17 . > > Component - version used. > > Jackson

Re: [jackson-user] Jackson deserialazing

2023-07-13 Thread Tatu Saloranta
On Thu, Jul 13, 2023 at 3:00 PM Max Szmid wrote: > > I have this issue, when I try to return an object from my API, sometimes the > format is as an object and other times it's just the ID of that object. I > need it to always return the object. I've noticed that it only happens if the > object

Re: [jackson-user] 2.12.7 to 2.13.5 Behavioural Change

2023-07-03 Thread Tatu Saloranta
On Tue, Jun 27, 2023 at 12:22 PM Martin Samm wrote: > > So, i have an issue i'm struggling to resolve. I have a service making a REST > call to another service. Using jackson 2.12.7 all's well. Upgrading to > jackson 2.13.5 the same code, config etc i'm getting this error: > > Could not resolve

Re: [jackson-user] RFE: Make MAX_ERROR_TOKEN_LENGTH configurable

2023-06-10 Thread Tatu Saloranta
On Sat, Jun 10, 2023 at 7:04 AM Joo Hyuk Kim (김주혁) wrote: > > I will try to implement the configuration. If that's okay?  Absolutely! -+ Tatu +- > On Wednesday, June 7, 2023 at 3:53:08 AM UTC+9 Tatu Saloranta wrote: >> >> Thank you sharing this, it makes sense (wrt newl

Re: [jackson-user] NoSuchMethodError: com.fasterxml.jackson.core.JsonParser.getReadCapabilities()

2023-06-08 Thread Tatu Saloranta
est (sadly not a solution) is do some searching around maven >> how to specify dep. version, override, etc.. >> On Wednesday, June 7, 2023 at 4:16:48 AM UTC+9 Tatu Saloranta wrote: >>> >>> On Tue, Jun 6, 2023 at 12:04 PM Ted Yu wrote: >>> > >>> >

Re: [jackson-user] NoSuchMethodError: com.fasterxml.jackson.core.JsonParser.getReadCapabilities()

2023-06-06 Thread Tatu Saloranta
itely come from non-jackson jar. :-( I don't know how to figure out where ClassLoader gets particular classes; chances are it's necessary to see what various jars included in classpath contain. -+ Tatu +- > > Cheers > > On Tuesday, June 6, 2023 at 11:55:07 AM UTC-7 Tatu Saloran

Re: [jackson-user] NoSuchMethodError: com.fasterxml.jackson.core.JsonParser.getReadCapabilities()

2023-06-06 Thread Tatu Saloranta
Version 2.6 is not supported (and hasn't for a while), so I am not sure how much we can help here with specific details. But exception message does suggest a version discrepancy: not between 2.6.7.1 and 2.6.7 (those are compatible being patch/micro-path within same minor release), but by

Re: [jackson-user] RFE: Make MAX_ERROR_TOKEN_LENGTH configurable

2023-06-06 Thread Tatu Saloranta
ly in the sense that there is no way to disable the original > exception, so I get a truncated exception message first followed by this log. > > Gili > > On 2023-06-05 18:30, Tatu Saloranta wrote: > > There is no way to configure this currently. > > If anyone has time and interes

Re: [jackson-user] RFE: Make MAX_ERROR_TOKEN_LENGTH configurable

2023-06-05 Thread Tatu Saloranta
There is no way to configure this currently. If anyone has time and interest in making this configurable I'd be happy to help; it'd need to go via `JsonFactory.builder()` configuration. But static config methods (static method, system properties) not acceptable. Ideally there would probably an

Re: [jackson-user] Expression Tree

2023-05-03 Thread Tatu Saloranta
On Mon, May 1, 2023 at 4:11 PM Marcus Biel wrote: > > Hello everyone, > > I'm dealing with a project that has a complex setup, and I'm trying to > simplify it. Our application allows users to establish Conditions or Filters > in the UI. These Conditions/Filters are stored in a database and can

Re: [jackson-user] Quick way to get the keys of a JSON object passed to my POJO?

2023-05-02 Thread Tatu Saloranta
On Tue, May 2, 2023 at 2:57 PM Laird Nelson wrote: > > Given a JSON object with, say, three keys mapped to three values, is there a > way in Jackson 2.15 or later to annotate some setter method or constructor of > my POJO to receive the set of such keys, known and unknown? > > e.g. something

Re: [jackson-user] Is it possible to conditionally apply a CustomSerializer?

2023-04-23 Thread Tatu Saloranta
On Sun, Apr 23, 2023 at 11:12 AM Olive Ahn wrote: > > I created a CustomSerializer for String class, is there a way to apply this > to a specific class only? > > ex. > > class Response { > > private T result; > > } > > > class DefaultResponse { > > private T result; > > } > > > When there

[jackson-user] Jackson 2.15.0-rc2 -- second pre-release -- now out. Help with testing needed!!!

2023-03-28 Thread Tatu Saloranta
So, I went ahead and published 2.15.0-rc2; release notes are: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.15 and the hope is to get things cleared up enough to release 2.15.0 final within 2 weeks. For this to happen we REALLY need help testing this pre-release version -- in

Re: [jackson-user] value string canonicalization?

2023-03-28 Thread Tatu Saloranta
On Tue, Mar 28, 2023 at 4:30 PM Viktor Szathmáry wrote: > > > On Mar 29, 2023, at 00:58, Tatu Saloranta wrote: > > Yes, I think that shows a simple idea that could work as intended (in > this case, for `String` -valued properties. > > > > Seems

Re: [jackson-user] value string canonicalization?

2023-03-28 Thread Tatu Saloranta
On Tue, Mar 28, 2023 at 3:24 PM Viktor Szathmáry wrote: > > On Mar 28, 2023, at 20:51, Tatu Saloranta wrote: > > But as I said, decoding from bytes to chars itself does not require > allocations, yet. > So `parser.getTextCharacters()` for example typically avoids > allocatio

Re: [jackson-user] value string canonicalization?

2023-03-28 Thread Tatu Saloranta
On Mon, Mar 27, 2023 at 11:11 PM Viktor Szathmáry wrote: > > Hi, > > > > On Mar 28, 2023, at 02:01, Tatu Saloranta wrote: > > > > On Mon, Mar 27, 2023 at 2:15 PM Viktor Szathmáry wrote: > > > > Right, it depends on what are important optimizations: if

Re: [jackson-user] value string canonicalization?

2023-03-27 Thread Tatu Saloranta
On Mon, Mar 27, 2023 at 2:15 PM Viktor Szathmáry wrote: > > Hi, > > Is there a good way of applying the equivalent of INTERN_FIELD_NAMES but for > field values? I'm guessing a custom deserializer There is no such functionality, although I think it has been requested. But design is more

[jackson-user] Re: [jackson-dev] Re: Jackson 2.15.0-rc1 release process started...

2023-03-19 Thread Tatu Saloranta
On Sat, Mar 18, 2023 at 3:32 PM Tatu Saloranta wrote: > > On Sat, Mar 18, 2023 at 1:02 PM Tatu Saloranta wrote: > > > > As per title, it is time for the First Pre-release version of 2.15, > > 2.15.0-rc1. > > Things included are listed on: > > > >

[jackson-user] Re: Jackson 2.15.0-rc1 release process started...

2023-03-18 Thread Tatu Saloranta
On Sat, Mar 18, 2023 at 1:02 PM Tatu Saloranta wrote: > > As per title, it is time for the First Pre-release version of 2.15, > 2.15.0-rc1. > Things included are listed on: > > https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.15 > > As usual, the release pr

[jackson-user] Jackson 2.15.0-rc1 release process started...

2023-03-18 Thread Tatu Saloranta
As per title, it is time for the First Pre-release version of 2.15, 2.15.0-rc1. Things included are listed on: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.15 As usual, the release process will take a couple of hours; I will send an update later on. Once release is complete, help

Re: [jackson-user] Stream closed before data is read and written to JSON

2023-03-16 Thread Tatu Saloranta
On Wed, Mar 15, 2023 at 5:41 PM Oliver Hancock wrote: > > I am taking in a JSON file that is an array of objects. I am trying to unnest > it and serialize it however memory management is very import, meaning that > the json being read and unested needs to be done through through a stream. >

Re: [jackson-user] How can I parse LoaclDateTime to ISO 8601 String?

2023-03-10 Thread Tatu Saloranta
On Fri, Mar 10, 2023 at 11:28 AM Igor Wojda wrote: > > Hi > > How can I parse LoaclDateTime to ISO 8601 format? I think your question is actually "how do I WRITE (serialize) LocalDateTime as JSON String using ISO-8601 format". Parsing would mean reading JSON String into LocalDateTime, which

Re: [jackson-user] 'java.lang.NoSuchMethodError' with jackson-core:2.14.1 when I upgraded to snakeyaml:2.0

2023-02-28 Thread Tatu Saloranta
On Tue, Feb 28, 2023 at 8:18 PM Akhil Ranjan wrote: > > I use jackson-core:2.14.1 in my application, and I tried upgrading to newly > released snakeyaml:2.0, to get rid of vulnerabilities in the earlier > snakeyaml version. > > I started getting the following runtime Exception with the >

Re: [jackson-user] Default typing with interface and implementation

2023-01-30 Thread Tatu Saloranta
On Mon, Jan 30, 2023 at 11:53 AM itineric itineric wrote: > > Hi all, > > I'm trying to work with interfaces and related bean implementation of that > interface. So far, all good. > I then tried to add some Map to the equation and I cannot > understand why I get this result. > Short story: I'm

[jackson-user] Jackson 2.13.5 released: planned to be the last full patch for 2.13.x

2023-01-22 Thread Tatu Saloranta
I ended up releasing 2.13.5 today (Scala module to follow, as usual). Number of changes is relatively smaller, detailed here: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.13.5 and the main thing was to get a full patch release to remove the need to use micro-patches for

Re: [jackson-user] Update only null values using objectMapper "readerForUpdating"

2023-01-22 Thread Tatu Saloranta
On Wed, Dec 14, 2022 at 5:36 PM Senthil Nathan wrote: > > Hi, > > Rather updating all the properties, I want to update the values for only null > fields using readerForUpdating. > > Class: > @Getter > @Setter > public class Record { > public String source; > public String resource; > }

Re: [jackson-user] How to download the Jackson-databind Micro Patch

2023-01-09 Thread Tatu Saloranta
On Mon, Jan 9, 2023 at 2:11 PM Ron Karim wrote: > > Due to a Corporate Security warning at Oracle Corp we will need to download > the following micropatches for the our existing system using > jackson_databind 2.12.7. > > (#3582 and #3590 - jackson-databind 2.12.7.1 (12-Oct-2022) -- with >

Re: [jackson-user] Update only null values using objectMapper "readerForUpdating"

2022-12-14 Thread Tatu Saloranta
On Wed, Dec 14, 2022 at 5:35 PM Senthil Nathan wrote: > > Hi, > > Rather updating all the properties, I want to update the values for only null > fields using readerForUpdating. > > Class: > @Getter > @Setter > public class Record { > public String source; > public String resource; > }

Re: [jackson-user] com.fasterxml.jackson.databind.JsonMappingException: Already had POJO for id (java.util.UUID)

2022-11-17 Thread Tatu Saloranta
On Thu, Nov 17, 2022 at 9:32 AM Syed Iftekharuddin wrote: > > Hi, > I have problem with Deserialization of entities with association. > The entities are as follows: > > @JsonIdentityInfo(generator = ObjectIdGenerators.PropertyGenerator.class, > property = "id", scope = Process.class) > public

Re: [jackson-user] Upgrade Java 11 to Java 17

2022-11-15 Thread Tatu Saloranta
On Tue, Nov 15, 2022 at 2:22 PM TradeInfo wrote: > > Hi All, > I have working on update springboot application of java version 11 to > 17. In that i got a issue regarding Jackson afterburner module fail and > java.lang.illegalAccessError can anyone know how to resolve this issue? That

Re: [jackson-user] Re: [jackson-dev] Re: Jackson 2.14.0 being released -- may take longer today

2022-11-06 Thread Tatu Saloranta
On Sat, Nov 5, 2022 at 9:45 PM Mark Derricutt wrote: > > On 6/11/2022 at 1:36:08 PM, Tatu Saloranta wrote: >> >> At this point most standard Jackson components have their 2.14.0 >> version released, synced up to Maven Central. > > > W00P. Yup yup! So far things

[jackson-user] Re: Jackson 2.14.0 being released -- may take longer today

2022-11-05 Thread Tatu Saloranta
On Sat, Nov 5, 2022 at 4:10 PM Tatu Saloranta wrote: > > So: due to lack of new reports of issues I was able to start the > official 2.14.0 release process today. Core components (jackson-core > (streaming), jackson-annotations, jackson-databind, jackson-bom) have > been publi

[jackson-user] Jackson 2.14.0 being released -- may take longer today

2022-11-05 Thread Tatu Saloranta
So: due to lack of new reports of issues I was able to start the official 2.14.0 release process today. Core components (jackson-core (streaming), jackson-annotations, jackson-databind, jackson-bom) have been published and pushed to Maven Central. Currently I am in the middle of releasing base

[jackson-user] Jackson Security Audit report just published!

2022-11-02 Thread Tatu Saloranta
Ok here is something that I think would be of interest to many of you: there is a new report covering recently completed security audit of Jackson core components by AdaLogics, under OSTIF effort: https://ostif.org/our-audits-of-jackson-core-and-jackson-databind-are-complete/ report itself

Re: [jackson-user] Deserializing record as key

2022-10-13 Thread Tatu Saloranta
On Wed, Oct 12, 2022 at 8:32 PM Tore Petersen wrote: > > Hi, > > My project is using record as keys for several different maps currently. > We are sending these maps over json and in testing we found that we needed a > spesific keyDeserializer and I needed to make an ugly keyDeserializer: > >

Re: [jackson-user] Replacement for deprecated configuration

2022-10-11 Thread Tatu Saloranta
On Tue, Oct 11, 2022 at 5:23 PM David Wallace wrote: > > I have an ObjectMapper which happens NOT to be a JsonMapper, that I receive > from a component outside my control. > > I would like to do something equivalent to > objectMapper.disable(MapperFeature.USE_ANNOTATIONS); but this has been >

[jackson-user] Re: Planning on starting 2.14.0-rc1 release process tomorrow (in 12+ hours or so)

2022-10-10 Thread Tatu Saloranta
with recent CVEs, for which fix is in 2.14. -+ Tatu +- On Sun, Sep 25, 2022 at 9:55 PM Tatu Saloranta wrote: > > 2.14.0-rc1 release process now complete. > > Release notes at: > > https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.14 > > At this point all the help in

Re: [jackson-user] Passing parameter to @JsonProperty

2022-10-08 Thread Tatu Saloranta
On Sat, Oct 8, 2022 at 9:03 AM Shastri Subramaniam wrote: > > > I am using AutoValue and Jackson for testing a GET Web Service. > > So I need to pass the GET Parameter to the @JsonProperty Annotation. > > Any suggestions on how I could achieve this ? > > Thanks ! You would need to give a bit

Re: [jackson-user] Re: Planning on starting 2.14.0-rc1 release process tomorrow (in 12+ hours or so)

2022-09-30 Thread Tatu Saloranta
; > On Monday, September 26, 2022 at 5:56:06 AM UTC+1 Tatu Saloranta wrote: >> >> 2.14.0-rc1 release process now complete. >> >> Release notes at: >> >> https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.14 >> >> At this point

[jackson-user] Re: Planning on starting 2.14.0-rc1 release process tomorrow (in 12+ hours or so)

2022-09-25 Thread Tatu Saloranta
scenario. -+ Tatu +- On Sun, Sep 25, 2022 at 1:20 PM Tatu Saloranta wrote: > > 2.14.0-rc1 release process starting now. > > Please note that it may take a bit longer than usual, during which > there is an incomplete set of versions published: this because we have > to start

[jackson-user] Re: Planning on starting 2.14.0-rc1 release process tomorrow (in 12+ hours or so)

2022-09-25 Thread Tatu Saloranta
to provide atomicity. I will send a note when the release is complete. -+ Tatu +- On Sat, Sep 24, 2022 at 5:48 PM Tatu Saloranta wrote: > > Ok, so I have finally gotten to the point where I feel confident I can > release the first "release candidate" (*) for Jackson 2.14.0. Stuf

Re: [jackson-user] Question: tentative 2.14.0 release date

2022-09-16 Thread Tatu Saloranta
On Fri, Sep 16, 2022 at 1:37 PM 'Chris Hegarty' via jackson-user wrote: > > Hi, > > Sorry if this is not the right place to ask a release related question, but I > cannot find the answer elsewhere. > > Is there a tentative schedule or plan for the release of the next minor > version in

Re: [jackson-user] Default namespace for XML?

2022-07-26 Thread Tatu Saloranta
bound to non-empty namespace URI. But it is a fundamental property of the document and not externally configurable. I suspect I still misunderstand what you are asking? -+ Tatu +- > > On Monday, July 25, 2022 at 2:23:51 PM UTC-7 Tatu Saloranta wrote: >> >> Underlying `XML

Re: [jackson-user] Questions about how to integrate Bean Validation with Jackson

2022-07-25 Thread Tatu Saloranta
On Tue, Jul 5, 2022 at 11:34 AM João Cabrita wrote: > > Hi, > > I've been working on a module to integrate Bean Validation with Jackson: > https://github.com/kewne/jackson-validation > > The basic ideas are: > 1. Without integrating validation into `@JsonCreator` calls, you can't then > enforce

Re: [jackson-user] Derialize/deserialize to a Map with type for bean and no type for primitive/collection/map

2022-07-19 Thread Tatu Saloranta
On Tue, Jul 19, 2022 at 12:44 PM nit...@gmail.com wrote: > > Thanks for your answer. > > Without the any setter/getter but with JsonTypeInfo on the map field, the > @class are added to every entries at the exclusion of the java types mappable > into json (so Long at its @class). But List still

Re: [jackson-user] Derialize/deserialize to a Map with type for bean and no type for primitive/collection/map

2022-07-18 Thread Tatu Saloranta
On Mon, Jul 18, 2022 at 4:47 AM Nicolas Labrot wrote: > > I think for the moment I will try to create a custom serializer / > deserializer for my properties map > - Serializer: introspect the map and build JavaType then call the appropriate > serialize > - Deserializer: convert first into a

Re: [jackson-user] Need help w/recurring error

2022-07-08 Thread Tatu Saloranta
On Thu, Jul 7, 2022 at 10:05 AM Alecia Reyes wrote: > > All, > > My company is working with a TMS software and we have about 45 users. One > user is getting an error when using the software to call out to another > website. He is the only one getting this error and it's been happening every >

Re: [jackson-user] @JsonTypeInfo annotation ObjectMapper equivalent

2022-07-02 Thread Tatu Saloranta
On Sat, Jul 2, 2022 at 3:05 PM Pierre wrote: > > Hello, > > What is the equivalent of @JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include > = JsonTypeInfo.As.PROPERTY) in the ObjectMapper without using annotations (or > mixins) ? > > I'm looking for something like >

Re: [jackson-user] ObjectMapper.configOverride() for interface, not class

2022-06-16 Thread Tatu Saloranta
On Thu, Jun 16, 2022 at 3:10 AM plo...@gmail.com wrote: > > Hello, > > I have several classes (MyClassA, MyClassB...) sharing an interface > (MyInterface), and I want to customize the inclusion setting for those POJOs, > using my custom filter (MyValueFilter). > > This is what I have so far: >

Re: [jackson-user] Json parser for escaped json?

2022-06-09 Thread Tatu Saloranta
On Thu, Jun 9, 2022 at 5:58 PM Ken Hancock wrote: > > I have a very large (> JVM memory) payload that requires the extraction of > certain fields for processing. The twist is the fields have escaped json as > the payload. Does Jackson have any capability of parsing this as a stream? > >

Re: [jackson-user] Jackson adding additional fields to JSON throws com.fasterxml.jackson.databind.exc.InvalidDefinitionException

2022-05-03 Thread Tatu Saloranta
On Tue, May 3, 2022 at 8:03 AM Aravind Baliga wrote: > > I am using Jackson to serialize my Java POJO classes. In addition to fields, > I have in Java POJO, I would like to add some additional information in JSON > I am writing my own custom `CustomClassSerializer`. If I use this class and >

[jackson-user] Jackson 2.14: up Java baseline to 8 for jackson-core, jackson-jr (leave annotations at Java 6)

2022-05-03 Thread Tatu Saloranta
As per title: I decided that it make sense to finally increase the Java/JDK baseline requirement for Jackson Streaming API to Java 8. The same then goes for "jackson-jr" (the only pre-Java-8 component above streaming). The only component to leave as pre-Java-8 will be "jackson-annotations" (no

Re: [jackson-user] Plan to raise minimum JDK requirement for Jackson 2.14 from JDK 6 to JDK 8 for all components

2022-04-20 Thread Tatu Saloranta
sed to be the case that one needed specific support by providers like Travis, and they started dropping support for earlier JDKs. This may have changed, but at the same time there is the diminishing return on time invested at this point. -+ Tatu +- > > On Wed, Apr 20, 2022 at 5:21

[jackson-user] Plan to raise minimum JDK requirement for Jackson 2.14 from JDK 6 to JDK 8 for all components

2022-04-20 Thread Tatu Saloranta
The minimum JDK one can use Jackson on has been JDK 8 for most components since version 2.13 (and minimum JDK to build anything has been JDK 8 as well). Exceptions include: * jackson-core, jackson-annotations only require (in theory) JDK 6 But even with that goal, there have been accidental uses

Re: [jackson-user] Java 17 Compatibility

2022-03-29 Thread Tatu Saloranta
On Tue, Mar 29, 2022 at 8:26 AM Shivaraj wrote: > > Hi All, > > Am using below components from FASTERXML, i have plan to upgrade my java > runtime from 1.8 to java 17. Need to check on the compatibility of the below > FOSS to run on JAVA 17 JRE. > > Component - version used. > > Jackson

[jackson-user] Jackson 2.13.2 release complete (including Kotlin)

2022-03-17 Thread Tatu Saloranta
Jackson patch release 2.13.2: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.13.2 is now out. Most components were already released last week, but we had some issues with the Kotlin module (jackson-module-kotlin), which I just released today. As usual, an upgrade is recommended,

Re: [jackson-user] Re: Issue with order of inheritance type attribute

2022-03-15 Thread Tatu Saloranta
On Mon, Mar 14, 2022 at 1:34 AM Michael Schäfer wrote: > > Hi Again, > > can really nobody help me? Is important information missing from my request? > And off course this is a stripped version of my code to reproduce the case. I > really need the inheritance. To me this also looks like the

Re: [jackson-user] support Path in JsonFactory?

2022-02-11 Thread Tatu Saloranta
ould possibly work. :-) -+ Tatu +- > > Tatu Saloranta 于2022年2月12日周六 06:52写道: > >> On Fri, Feb 11, 2022 at 10:45 AM jonas@gmail.com >> wrote: >> > >> > A missing class for a method parameter shouldn't affect you, you could >> simply n

Re: [jackson-user] support Path in JsonFactory?

2022-02-11 Thread Tatu Saloranta
ar case I would expect actual trouble even if that specific `readValue()` method was not called. -+ Tatu +- > > Michael Rogers schrieb am Freitag, 11. Februar 2022 um 13:48:44 UTC+1: >> >> On 01/02/2022 18:28, Tatu Saloranta wrote: >> > On Mon, Jan 24, 2022 at 8:13 P

Re: [jackson-user] support Path in JsonFactory?

2022-02-11 Thread Tatu Saloranta
On Fri, Feb 11, 2022 at 4:48 AM Michael Rogers wrote: > > On 01/02/2022 18:28, Tatu Saloranta wrote: > > On Mon, Jan 24, 2022 at 8:13 PM Xeno Amess > <mailto:xenoam...@gmail.com>> wrote: > > > > Hi. > > Is there any reason not su

Re: [jackson-user] Inheritance::Cannot deduce unique subtype (multiple candidates)

2022-02-10 Thread Tatu Saloranta
or it to be skipped). But what do you mean by passing a "key"? If you mean adding a new type property, wouldn't it make more sense to not use DEDUCTION at all but the standard, type id property based approach? -+ Tatu +- > Tatu Saloranta schrieb am Mittwoch, 9. Februar 2022 um 18:44:17

Re: [jackson-user] Inheritance::Cannot deduce unique subtype (multiple candidates)

2022-02-09 Thread Tatu Saloranta
On Tue, Feb 8, 2022 at 9:30 AM 'Karsil' via jackson-user wrote: > > Hey everyone, > > I'm trying to solve an inheritance problem where a clear deduction is > currently not possible. A toy example: > > // BASECLASS > @JsonSubTypes( { > @JsonSubTypes.Type( Child.class ) > } ) > @JsonTypeInfo( use

Re: [jackson-user] Compilation error after upgrading from 2.12.3 to 2.13.1

2022-02-02 Thread Tatu Saloranta
On Wed, Feb 2, 2022 at 5:00 PM Madhu Narasimhan < madhu_narasim...@hotmail.com> wrote: > Sorry, the intention was definitely not to blame the jackson package. In > fact, I saw that other groups in my No problem -- I did not consider it blaming but a simple request for help. Actual breakages

Re: [jackson-user] Compilation error after upgrading from 2.12.3 to 2.13.1

2022-02-02 Thread Tatu Saloranta
On Wed, Feb 2, 2022 at 9:41 AM Madhu Narasimhan < madhu_narasim...@hotmail.com> wrote: > Hi, > > I hit a strange issue after upgrading from jackson 2.12.3 to 2.13.1. With > 2.13.1, compilation failed as below without any specific error message. > Er. I see: "From the stack trace below, it

Re: [jackson-user] support Path in JsonFactory?

2022-02-01 Thread Tatu Saloranta
On Mon, Jan 24, 2022 at 8:13 PM Xeno Amess wrote: > Hi. > Is there any reason not support Path in JsonFactory and ObjectMapper? > If not, then I would provide a pr when I have time. > The main reason is that `Path` was added in JDK 7 and for the longest time Jackson only required JDK 6. With

Re: [jackson-user] readValues() from an XML stream

2022-01-24 Thread Tatu Saloranta
On Wed, Jan 19, 2022 at 2:15 PM gapag wrote: > Hi everyone, > > I would like to read an XML stream with readValues, but if I wish to do > something like: > > > *mapper.readValues("i11i22i33")* > > > *Find a concrete example in * > *https://gist.github.com/gapag/8856983e48d94b57c5c63c46dc477cbc*

Re: [jackson-user] Missing array order information

2022-01-16 Thread Tatu Saloranta
On Sun, Jan 16, 2022 at 5:23 PM Juan Rada wrote: > > Hello folks > > I am using jackson xml to deserialize an array of elements of diferent types > like. > > > ...content-1a... > ...content-2... > ...content-1b... > > > The problem is that when using tree model >

Re: [jackson-user] polymorphic deserialization based on existence of a key

2022-01-06 Thread Tatu Saloranta
On Thu, Jan 6, 2022 at 10:58 AM Reji Mathews wrote: > Hello ! > > I have a requirement where I need to select the concrete class based on > presence of a key field in my json > > I have a base abstract class Activity.java which is extended by > CommandActivity.java and ViewActivity.java > > Ex

Re: [jackson-user] Deserializing objects that conform to Collection API

2021-12-28 Thread Tatu Saloranta
On Tue, Dec 28, 2021 at 4:30 AM Mantas Gridinas wrote: > > I've come about to a bit of a pickle. Suppose I have the following structure: > > class CollectionWrapper implements Collection { > private int count; > private Collection items; > > // getters setters omitted for brevity >

[jackson-user] Jackson 2.12.6 and 2.13.1 patch releases: one CVE fix

2021-12-19 Thread Tatu Saloranta
Jackson patch releases * 2.12.6: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.12.6 * 2.13.1: https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.13.1 were just released. In addition to the usual "it is good to use the latest patch", there is one additional reason for

[jackson-user] On Jackson, log4j/logback vulnerabilities: https://cowtowncoder.medium.com/jackson-is-not-affected-by-log4j-logback-cves-fdebf152057f

2021-12-19 Thread Tatu Saloranta
Since I have received I few direct (off-mailing-list/off-twitter) queries on this, I decided to blog about it: https://cowtowncoder.medium.com/jackson-is-not-affected-by-log4j-logback-cves-fdebf152057f So, TL;DNR; -- Jackson is NOT vulnerable to any of CVEs that affect log4j and logback. This is

Re: [jackson-user] Deserialize: nested xml document missing

2021-11-30 Thread Tatu Saloranta
On Mon, Nov 29, 2021 at 4:05 PM Lakshmi Narayana Malempati < lmalemp...@gmail.com> wrote: > Hi there, > When de-serializing the attached xml, the nested xml doc under the > 'payload' > element comes blank. my code: > > Background: > We have a java application that serializes java objects that are

Re: [jackson-user] Jackson library JaxbAnnotation throwing exception on Android

2021-11-30 Thread Tatu Saloranta
On Tue, Nov 30, 2021 at 3:19 AM Lakshmi Narayana Malempati < lmalemp...@gmail.com> wrote: > Trying to use a java jar file on Android which uses Jackson lib. But > getting the below errors, stack trace attached. > java.lang.NoClassDefFoundError: Failed resolution of: >

Re: [jackson-user] Why does Jackson's treatment of Double.NaN differs depending on DefaultTyping ?

2021-11-23 Thread Tatu Saloranta
On Tue, Nov 23, 2021 at 10:35 AM Steffen Springer wrote: > Used version: *jackson 2.13.0* > > In general writing and reading of Double.NaN works fine. However, if I > want to write a class like this > > public class SimpleClass { private Map map;} > > and the map contains a Double.NaN value, it

Re: [jackson-user] Configuring customer serializer via ObjectMapper

2021-11-10 Thread Tatu Saloranta
On Thu, Oct 14, 2021 at 7:40 PM Sasa Vilic wrote: > Hi, > > is there a way to pass configuration to customer serializer, for given > ObjectMapper instance? > > Background: > > I have created custom UUID serializer/deserializer with idea that I want > support both legacy/hex format and advanced

  1   2   3   4   5   6   7   8   >