Re: [jackson-user] Windows CentOS differences

2018-08-08 Thread Sean Dawson
Oh ok - thanks so much for the info and that suggestion. Will check it out.


On Wed, Aug 8, 2018 at 2:55 AM, Tatu Saloranta  wrote:

>
>
> On Wed, Aug 8, 2018 at 6:52 AM  wrote:
>
>>
>> Hello, we have a web app that sits in Tomcat and uses RestEasy
>> 3.0.16.Final and Jackson 2.5.2. It's built once, using maven, and then
>> deployed pretty much the same to a Windows 7 and a CentOS 7.2 machines.
>>
>> Just in the last week, we've started to get ProcessingException errors on
>> a couple of our dtos...
>>
>> com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException:
>> Unrecognized field "date" (class ...), not marked as ignorable (0 known
>> properties: ])
>>  at [Source: java.io.BufferedInputStream@44daddab; line: 1, column: 52]
>> (through reference chain: ...["date"])
>>
>> So for one of the dto's, I had to add 3 variables into
>> @JsonIgnoreProperties and for the other, I had to add 
>> @JsonAutoDetect(fieldVisibility
>> = JsonAutoDetect.Visibility.ANY).
>>
>> I don't know why this is. I can't think of anything that's changed in
>> this area recently. Or why it happens only on Linux (all the required
>> libraries are included on both, and they are exactly the same).
>>
>> Could it be a JDK issue? Some difference in configuration of another
>> component like RestEasy or Hibernate ?
>>
>>
> I do not know what specifically could cause this, but I would first
> consider upgrading at least to latest 2.5.x patch version (2.5.5).
> As to root cause I would probably try to thoroughly check that you do not
> somehow have multiple versions of Jackson-databind jar; if multiple exist,
> loading order is arbitrary and could well be OS dependant. And typically
> nothing good comes out of conflicting versions anyway; it is a common cause
> for strange errors. So maybe that could be happening here?
>
> -+ Tatu +-
>
>
>> Thanks.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "jackson-user" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to jackson-user+unsubscr...@googlegroups.com.
>> To post to this group, send email to jackson-user@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "jackson-user" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/jackson-user/8CEA11OKlxE/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> jackson-user+unsubscr...@googlegroups.com.
> To post to this group, send email to jackson-user@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jackson-user+unsubscr...@googlegroups.com.
To post to this group, send email to jackson-user@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [jackson-user] Windows CentOS differences

2018-08-08 Thread Tatu Saloranta
On Wed, Aug 8, 2018 at 6:52 AM  wrote:

>
> Hello, we have a web app that sits in Tomcat and uses RestEasy
> 3.0.16.Final and Jackson 2.5.2. It's built once, using maven, and then
> deployed pretty much the same to a Windows 7 and a CentOS 7.2 machines.
>
> Just in the last week, we've started to get ProcessingException errors on
> a couple of our dtos...
>
> com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException:
> Unrecognized field "date" (class ...), not marked as ignorable (0 known
> properties: ])
>  at [Source: java.io.BufferedInputStream@44daddab; line: 1, column: 52]
> (through reference chain: ...["date"])
>
> So for one of the dto's, I had to add 3 variables into
> @JsonIgnoreProperties and for the other, I had to add
> @JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.ANY).
>
> I don't know why this is. I can't think of anything that's changed in this
> area recently. Or why it happens only on Linux (all the required libraries
> are included on both, and they are exactly the same).
>
> Could it be a JDK issue? Some difference in configuration of another
> component like RestEasy or Hibernate ?
>
>
I do not know what specifically could cause this, but I would first
consider upgrading at least to latest 2.5.x patch version (2.5.5).
As to root cause I would probably try to thoroughly check that you do not
somehow have multiple versions of Jackson-databind jar; if multiple exist,
loading order is arbitrary and could well be OS dependant. And typically
nothing good comes out of conflicting versions anyway; it is a common cause
for strange errors. So maybe that could be happening here?

-+ Tatu +-


> Thanks.
>
> --
> You received this message because you are subscribed to the Google Groups
> "jackson-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jackson-user+unsubscr...@googlegroups.com.
> To post to this group, send email to jackson-user@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jackson-user+unsubscr...@googlegroups.com.
To post to this group, send email to jackson-user@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[jackson-user] Windows CentOS differences

2018-08-08 Thread seandawson2015

Hello, we have a web app that sits in Tomcat and uses RestEasy 3.0.16.Final 
and Jackson 2.5.2. It's built once, using maven, and then deployed pretty 
much the same to a Windows 7 and a CentOS 7.2 machines.

Just in the last week, we've started to get ProcessingException errors on a 
couple of our dtos...

com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: 
Unrecognized field "date" (class ...), not marked as ignorable (0 known 
properties: ])
 at [Source: java.io.BufferedInputStream@44daddab; line: 1, column: 52] 
(through reference chain: ...["date"])

So for one of the dto's, I had to add 3 variables into 
@JsonIgnoreProperties and for the other, I had to add 
@JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.ANY).

I don't know why this is. I can't think of anything that's changed in this 
area recently. Or why it happens only on Linux (all the required libraries 
are included on both, and they are exactly the same).

Could it be a JDK issue? Some difference in configuration of another 
component like RestEasy or Hibernate ?

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jackson-user+unsubscr...@googlegroups.com.
To post to this group, send email to jackson-user@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.