[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15409118#comment-15409118 ] ASF GitHub Bot commented on IGNITE-2122: Github user ptupitsyn closed the pull request at: https://github.com/apache/ignite/pull/316 > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, platforms >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Priority: Critical > Labels: .net > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15066225#comment-15066225 ] Pavel Tupitsyn commented on IGNITE-2122: Moved to 1.6 because of api uncertainty. Let's do a simple cleanup for 1.5: IGNITE-2215 > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Pavel Tupitsyn >Priority: Critical > Fix For: 1.6 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15059693#comment-15059693 ] Vladimir Ozerov commented on IGNITE-2122: - Yes, let's go this way. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15058300#comment-15058300 ] Pavel Tupitsyn commented on IGNITE-2122: 1) What is user supposed to do if he wants a concrete type like HashSet or ConcurrentBag? 2) Exactly, and current solution does not have this problem. 3) Looks good, similar to current solution, slightly less versatile, but easier to use. Should we agree on this one? > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057934#comment-15057934 ] Pavel Tupitsyn commented on IGNITE-2122: 1) Ok 2) Then we should only keep non-generic methods without adders. Which is the best approach, probably. There is no point in providing half-baked generic support, user can simply call OfType<>() on a non-generic ICollection and be done with it. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057872#comment-15057872 ] Vladimir Ozerov commented on IGNITE-2122: - 1) Split - separate methods for generic and non-generic collections. 2) IEnumerable is not needed in value objects. I can hardly imagine a situation where user operates on IEnumetables inside a class which is going to be passed over wire. So we should use ICollection as a most expected use case. 3) No need for any filtering or any other logic. This is collection write method. Any filtering must be done before user call this method. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057971#comment-15057971 ] Vladimir Ozerov commented on IGNITE-2122: - Why are we going to force user using casts or OfType<> conversions if in 99% he will operate on generic collection? The most common case must require minimal actions from user. This is why we need to separate generic and non-generic cases. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057897#comment-15057897 ] Pavel Tupitsyn commented on IGNITE-2122: 1) What is the advantage? 2) I can easily imagine such situations, moreover, I've been there. You can never expect where "enterprisey" code takes you. Good API should accept the most general type possible. There is no single reason to restrict user to ICollection there. Especially when it is so easy to support on our side. 3) We are talking about read methods. Write methods do not have adders. Another example: user may operate on a Person set in his business logic, but use PersonDto to write/read them. {code} class Department { MyCollection Persons {get;set;} void WriteBinary(..) { writer.WriteCollection(Persons.Select(p => p.ToPersonDto())); } void ReadBinary(..) { Persons = reader.ReadCollection(cnt => new MyCollection(cnt), (col, dto) => col.Insert(new Person(dto))); } } {code} > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057862#comment-15057862 ] Pavel Tupitsyn commented on IGNITE-2122: 1) What do you mean by "split"? Rename? 2) We should not do this. Accepting IEnumerable in writer is very important, it is not a specific case. LINQ and yield-style enumerators return IEnumerable, we should not force the user to do an extra memory copy if we can easily write lazy enumeration directly to a stream. 3) Not sure about this either, current API avoids all possible casts on the user side, allows any kind of custom collection/dictionary, allows filtering and other processing in the adder. And it provides a simple overload without adder/factory. Imagine that user wants to read collection into HashSet. Current API provides the most efficient way of doing this in one line. What you suggest will require allocating extra collection. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Pavel Tupitsyn >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057922#comment-15057922 ] Vladimir Ozerov commented on IGNITE-2122: - 1) Advantage - no adders for generic collections. Only factory func is needed. 2) Our goal is to support the most common use cases. Any non-trivial stuff will be handled by user manually. 3) Ok. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15057993#comment-15057993 ] Pavel Tupitsyn commented on IGNITE-2122: With your approach of "ICollection ReadCollection" without factory/adder there WILL be additional action from the user 99% of the time, because, most likely, user needs some specific collection, like List<>, and we give him ICollection<>: * List persons = reader.ReadCollection().ToList(); * List persons = reader.ReadGenericCollection().ToList() This kind of generic support is rarely useful and will only confuse users. > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15058037#comment-15058037 ] Vladimir Ozerov commented on IGNITE-2122: - My concerns: 1) Users are not supposed to use concrete types when using "ReadCollection()" method. Concrete types are expected only with factories. 2) ToList() produces garbage. At the very least it is a collection and enumerator. Plus copying. 3) What about having the following interface. No casts, no copying: {code} T ReadCollectionfactory) where T : ICollection; {code} > .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. > > > Key: IGNITE-2122 > URL: https://issues.apache.org/jira/browse/IGNITE-2122 > Project: Ignite > Issue Type: Task > Components: general, interop >Affects Versions: ignite-1.4 >Reporter: Vladimir Ozerov >Assignee: Vladimir Ozerov >Priority: Critical > Fix For: 1.5 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2122) .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods.
[ https://issues.apache.org/jira/browse/IGNITE-2122?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15050983#comment-15050983 ] ASF GitHub Bot commented on IGNITE-2122: GitHub user ptupitsyn opened a pull request: https://github.com/apache/ignite/pull/316 IGNITE-2122 .NET: Add generic Read/WriteCollection and Read/WriteDictionary methods. You can merge this pull request into a Git repository by running: $ git pull https://github.com/ptupitsyn/ignite ignite-2122 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/ignite/pull/316.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #316 commit 86f4892dced3f4ed6b3dcfb59f639aaa9cc53f77 Author: vozerov-gridgainDate: 2015-12-09T09:53:00Z IGNITE-2099: WIP. commit 5c41396817b9d8b208d4107edf805865220b9172 Author: vozerov-gridgain Date: 2015-12-09T10:00:43Z IGNITE-2099: Enhanced test, all is fine for now. commit 75d5874cb89722152de009c1581831bf6b2bc0e4 Author: vozerov-gridgain Date: 2015-12-09T10:05:07Z IGNITE-2099: Removed collection types which are no longer used. commit d53472e5de989c994cd534e21ce10d54db4cd277 Author: vozerov-gridgain Date: 2015-12-09T10:11:42Z IGNITE-2099: Removed entries handling. commit 755fe6dd80c4d3c846bea35f8232fc4650b5e966 Author: vozerov-gridgain Date: 2015-12-09T10:21:04Z IGNITE-2099: Minor fix. commit e7992323d1c7ab435173282f590f277e76bfaa3b Author: vozerov-gridgain Date: 2015-12-09T10:21:11Z Merge branch 'ignite-2099' into ignite-2099-noentry commit 6172ce1c3dfc7266cd22fdb1cc29eb64ca795041 Author: vozerov-gridgain Date: 2015-12-09T10:25:53Z IGNITE-2099: Fixing tests. commit d72d8462030b5610a5c7b5cd6469e25bef1f5fcc Author: vozerov-gridgain Date: 2015-12-09T10:34:27Z IGNITE-2099: Minor fix. commit 9ff351b50b481c85460c4c95f9c3aad93a5a9a6f Author: vozerov-gridgain Date: 2015-12-09T12:03:59Z Merge branch 'ignite-1.5' into ignite-2099 commit 5d401c4d64abd6e53c6e786e457f75208d606fc8 Author: vozerov-gridgain Date: 2015-12-09T13:41:24Z Merge branch 'ignite-1.5' into ignite-2099 commit 7d734157b1935ffc6ed7be2b6779bd7ce8f9 Author: vozerov-gridgain Date: 2015-12-09T14:02:25Z IGNITE-2099: Remove entry support in .NET. commit 1c8208e0dc3217a98ce22cace4bc7e20c25a0f4a Author: vozerov-gridgain Date: 2015-12-09T14:17:56Z Merge branch 'ignite-1.5' into ignite-2099 Conflicts: modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/BinarySystemHandlers.cs commit 821953dd30796fd2edada6147761023a134ac8ce Author: vozerov-gridgain Date: 2015-12-09T14:34:30Z IGNITE-2099: Finalization. commit 22322fa0dced1dae4d859f3d3b09dc7027824d96 Author: vozerov-gridgain Date: 2015-12-09T14:47:30Z IGNITE-2099: Finished .NET part. commit 84006b9570ef19bf8ebda20a3008b22a34564d22 Author: vozerov-gridgain Date: 2015-12-10T06:47:49Z Merge branch 'ignite-1.5' into ignite-2099 commit 7407f4967d6974ed4b4c5dbd91128d638251ae31 Author: Pavel Tupitsyn Date: 2015-12-10T08:48:25Z wip commit 6c0ebb0bb7fcd958ef1ec1969f3d30f729c3175b Author: Pavel Tupitsyn Date: 2015-12-10T08:51:28Z Merge from 1.5 commit 6527bd81507e26902c99df83711a287b388b0410 Author: Pavel Tupitsyn Date: 2015-12-10T08:51:42Z Merge from 1.5 commit ffbe11d1250141c29b49fce064adeb55c5bfd04d Author: Pavel Tupitsyn Date: 2015-12-10T08:55:39Z wip commit 966166d174e6b89cfaf783bf92df0d715fc0d81b Author: Pavel Tupitsyn Date: 2015-12-10T08:58:12Z wip commit a440540486a2b6af795afb2464c03dac47380559 Author: Pavel Tupitsyn Date: 2015-12-10T09:07:32Z wip commit 2e972de6d5e694d775d13726bee6033c07f5c105 Author: Pavel Tupitsyn Date: 2015-12-10T09:17:53Z wip commit 935c4ab00079861680806984db0810c06d835738 Author: Pavel Tupitsyn Date: 2015-12-10T09:21:11Z fix tests commit 7626f61f6fa1781342198536b858320281b37bd4 Author: Pavel Tupitsyn Date: 2015-12-10T10:06:10Z wip commit bd05f57b9aaa61f3296905327175d67d25b77eeb Author: Pavel Tupitsyn Date: 2015-12-10T10:10:57Z wip commit f76e50c009f7b5fbe7e5b4d957faa00e4cb55ae4 Author: Pavel Tupitsyn Date: 2015-12-10T10:15:29Z