Timotheus Preisinger created IGNITE-15820:
---------------------------------------------
Summary: Streaming from .NET Thin Client does not create table
entries
Key: IGNITE-15820
URL: https://issues.apache.org/jira/browse/IGNITE-15820
Project: Ignite
Issue Type: Bug
Components: platforms, sql, streaming, thin client
Affects Versions: 2.11
Environment: Ignite 2.11, both as standalone (started from C#) and in
Docker container
net5
C#
Windows 10
Reporter: Timotheus Preisinger
Fix For: None
Attachments: ClientDataStreamerReader.java,
IgniteStreamingBugShowcase.zip, image-2021-10-25-09-47-15-262.png,
image-2021-10-25-09-50-01-610.png
Binary streaming from .NET Thin Client does not create table entries visible
through SQL.
The cause seems to be an additional wrapping of the object in the Java
implementation.
* screenshot from Java debugger for STREAMING ON IIgnite OBJECT: The "val" of
the DataStreamerEntry is a "BinaryObjectImpl":
!image-2021-10-25-09-47-15-262.png|width=306,height=208!
* screenshot from Java debugger for STREAMING ON IIgniteClient OBJECT: The
"val" of the DataStreamerEntry is a CacheObjectImpl that holds the
BinaryObjectImpl:
!image-2021-10-25-09-50-01-610.png|width=316,height=214!
Using the Thin Client,
org.apache.ignite.internal.processors.platform.client.streamer.ClientDataStreamerReader.readCacheObject(...)
is called and wraps the object read from the input stream again, no matter if
it already is an instance of CacheObject.
When calling with Thin Client, a warning is shown:
[09:12:02,778][WARNING][data-streamer-stripe-16-#41][GridQueryProcessor]
Key-value pair is not inserted into any SQL table [cacheName=cache1,
val=CacheObjectImpl [val=Person [idHash=501908769, hash=-123912966, Age=34,
Name=Joe], hasValBytes=true]]
[09:12:02,779][WARNING][data-streamer-stripe-16-#41][GridQueryProcessor] ^--
Value type(s) are specified via CacheConfiguration.indexedTypes or
CacheConfiguration.queryEntities
[09:12:02,779][WARNING][data-streamer-stripe-16-#41][GridQueryProcessor] ^--
Make sure that same type(s) used when adding Object or BinaryObject to cache
[09:12:02,779][WARNING][data-streamer-stripe-16-#41][GridQueryProcessor] ^--
Otherwise, entries will be stored in cache, but not appear as SQL Table rows
Sample code and Java source code file with patch proposal is attached.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)