Skip to content

Heads-up: data corrupting bug in ODP.NET Core 3.21.1 #28

Open
@jods4

Description

TL;DR: don't use attachments (DataBus) with Oracle.ManagedDataAccess.Core 3.21.1

After upgrading packages in our project we experienced data-corruption when reading attachments.

I tracked this down to an ODP.NET regression when setting InitalLOBFetchSize on the command (Rebus.Oracle sets it to 4000).

I made some unit tests using ODP.NET directly.
I downloaded a blob that was 2386 bytes in size and I observed:

  • ODP.NET 2.19.110: always ok ✔
  • ODP.NET 3.21.1 without InitialLOBFetchSize: ok ✔
  • ODP.NET 3.21.1 with InitialLOBFetchSize = 4000: result is 4096 bytes long, padded with zeroes ❌

Further investigation shows that blobs < 2048 are padded with zeroes to 2048; blobs < 4096 are padded to 4096; larger blobs seem ok.

Hopefully Oracle fixes this soon, in the meantime be careful with 3.21.1

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions