[
https://issues.apache.org/jira/browse/IGNITE-13588?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Pavel Tupitsyn updated IGNITE-13588:
------------------------------------
Description:
Using a generic type as a QueryEntity value type results in a wrong binary type
name being registered:
{code}
var ignite = Ignition.Start(TestUtils.GetTestConfiguration());
var cfg = new CacheConfiguration(
TestUtils.TestName,
new QueryEntity(typeof(int), typeof(GenericTest<string>)));
var cache = ignite.GetOrCreateCache<int, GenericTest<string>>(cfg);
cache[1] = new GenericTest<string> {Prop = "1"};
var tables = cache.Query(new SqlFieldsQuery("SELECT TABLE_NAME FROM
INFORMATION_SCHEMA.TABLES"))
.Select(x => (string) x.Single()).ToArray();
{code}
Resulting table name is *0, CULTURE=NEUTRAL, PUBLICKEYTOKEN=7CEC85D7BEA7798E]]*.
We should clean up the generic type name in {{BinaryUtils.GetSqlTypeName}}.
was:
Using a generic type as a QueryEntity value type results in a broken SQL table
name:
{code}
var ignite = Ignition.Start(TestUtils.GetTestConfiguration());
var cfg = new CacheConfiguration(
TestUtils.TestName,
new QueryEntity(typeof(int), typeof(GenericTest<string>)));
var cache = ignite.GetOrCreateCache<int, GenericTest<string>>(cfg);
cache[1] = new GenericTest<string> {Prop = "1"};
var tables = cache.Query(new SqlFieldsQuery("SELECT TABLE_NAME FROM
INFORMATION_SCHEMA.TABLES"))
.Select(x => (string) x.Single()).ToArray();
{code}
Resulting table name is *0, CULTURE=NEUTRAL, PUBLICKEYTOKEN=7CEC85D7BEA7798E]]*.
We should clean up the generic type name in {{BinaryUtils.GetSqlTypeName}}.
> .NET: Incorrect binary type name is registered for generic query types
> ----------------------------------------------------------------------
>
> Key: IGNITE-13588
> URL: https://issues.apache.org/jira/browse/IGNITE-13588
> Project: Ignite
> Issue Type: Bug
> Components: platforms
> Affects Versions: 2.9, 2.8.1
> Environment: Apache Ignite: v2.8.1
> JDK: v1.8
> .NET Core: v3.1
> Reporter: Danut Radoaica
> Assignee: Pavel Tupitsyn
> Priority: Major
> Labels: .NET, 2.9.1-rc
> Attachments: Untitled.png
>
> Time Spent: 40m
> Remaining Estimate: 0h
>
> Using a generic type as a QueryEntity value type results in a wrong binary
> type name being registered:
> {code}
> var ignite = Ignition.Start(TestUtils.GetTestConfiguration());
> var cfg = new CacheConfiguration(
> TestUtils.TestName,
> new QueryEntity(typeof(int), typeof(GenericTest<string>)));
> var cache = ignite.GetOrCreateCache<int,
> GenericTest<string>>(cfg);
> cache[1] = new GenericTest<string> {Prop = "1"};
> var tables = cache.Query(new SqlFieldsQuery("SELECT TABLE_NAME
> FROM INFORMATION_SCHEMA.TABLES"))
> .Select(x => (string) x.Single()).ToArray();
> {code}
> Resulting table name is *0, CULTURE=NEUTRAL,
> PUBLICKEYTOKEN=7CEC85D7BEA7798E]]*.
> We should clean up the generic type name in {{BinaryUtils.GetSqlTypeName}}.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)