[jira] [Assigned] (IGNITE-13029) Support Spring Data repositories initialization with Spring Boot auto-starter

2020-09-26 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-13029?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani reassigned IGNITE-13029:
--

Assignee: (was: Kartik Somani)

> Support Spring Data repositories initialization with Spring Boot auto-starter
> -
>
> Key: IGNITE-13029
> URL: https://issues.apache.org/jira/browse/IGNITE-13029
> Project: Ignite
>  Issue Type: Improvement
>  Components: spring, springdata
>Affects Versions: 2.8
>Reporter: Denis A. Magda
>Priority: Major
>  Labels: newbie
>
> It's required to use {{@EnableIgniteRepositories}} annotation and follow this 
> procedure to enable Ignite Spring Data repositories:
> https://apacheignite-mix.readme.io/docs/spring-data#spring-data-and-apache-ignite-configuration
> Support the Spring Data repositories enablement via the Spring Boot 
> auto-starter if Spring Boot is used by a project:
> https://apacheignite-mix.readme.io/docs/spring-boot



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (IGNITE-13029) Support Spring Data repositories initialization with Spring Boot auto-starter

2020-06-27 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-13029?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani reassigned IGNITE-13029:
--

Assignee: Kartik Somani

> Support Spring Data repositories initialization with Spring Boot auto-starter
> -
>
> Key: IGNITE-13029
> URL: https://issues.apache.org/jira/browse/IGNITE-13029
> Project: Ignite
>  Issue Type: Improvement
>  Components: spring, springdata
>Affects Versions: 2.8
>Reporter: Denis A. Magda
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> It's required to use {{@EnableIgniteRepositories}} annotation and follow this 
> procedure to enable Ignite Spring Data repositories:
> https://apacheignite-mix.readme.io/docs/spring-data#spring-data-and-apache-ignite-configuration
> Support the Spring Data repositories enablement via the Spring Boot 
> auto-starter if Spring Boot is used by a project:
> https://apacheignite-mix.readme.io/docs/spring-boot



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-14 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17135126#comment-17135126
 ] 

Kartik Somani commented on IGNITE-13128:


I think the changes have been merged. Should I close this now?

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}
> This does not happen if we add any lock2 call before lock1.close(). The 
> following works as expected, returning "Failed to find reentrant lock with 
> given name" exception:
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock2.isLocked();
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-14 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17135048#comment-17135048
 ] 

Kartik Somani edited comment on IGNITE-13128 at 6/14/20, 6:09 AM:
--

[~ptupitsyn]

I've done both the above.


was (Author: kay_jpr):
[~ptupitsyn]

It's done both the above.

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}
> This does not happen if we add any lock2 call before lock1.close(). The 
> following works as expected, returning "Failed to find reentrant lock with 
> given name" exception:
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock2.isLocked();
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-14 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17135048#comment-17135048
 ] 

Kartik Somani commented on IGNITE-13128:


[~ptupitsyn]

It's done both the above.

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}
> This does not happen if we add any lock2 call before lock1.close(). The 
> following works as expected, returning "Failed to find reentrant lock with 
> given name" exception:
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock2.isLocked();
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-10 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17132240#comment-17132240
 ] 

Kartik Somani commented on IGNITE-13128:


[~ptupitsyn] 
I added a check for exception message also.
for #2, I've triggered test here : 
[https://mtcga.gridgain.com/pr.html?serverId=apache=IgniteTests24Java8_RunAll==pull%2F7913%2Fhead=Lates|https://mtcga.gridgain.com/pr.html?serverId=apache=IgniteTests24Java8_RunAll==pull%2F7913%2Fhead=Latest]

 

Looks like it failed. Can you help me interpret this?

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}
> This does not happen if we add any lock2 call before lock1.close(). The 
> following works as expected, returning "Failed to find reentrant lock with 
> given name" exception:
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock2.isLocked();
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-08 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17128471#comment-17128471
 ] 

Kartik Somani commented on IGNITE-13128:


I've created a pull request and attached to this ticket [~ptupitsyn] . Please 
review.
Let me know if there is anything missing from my end.

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}
> This does not happen if we add any lock2 call before lock1.close(). The 
> following works as expected, returning "Failed to find reentrant lock with 
> given name" exception:
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock2.isLocked();
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Issue Comment Deleted] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-06-08 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani updated IGNITE-12702:
---
Comment: was deleted

(was: [~PetrovMikhail]I've updated the pull request here: 
[https://github.com/apache/ignite/pull/7882]

 

please review)

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Issue Comment Deleted] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-06-08 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani updated IGNITE-12702:
---
Comment: was deleted

(was: Pull request for this 
https://issues.apache.org/jira/browse/IGNITE-12702?jql=project%20%3D%20IGNITE%20AND%20labels%20in%20(newbie)%20and%20status%20%3D%20OPEN)

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-08 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17127939#comment-17127939
 ] 

Kartik Somani edited comment on IGNITE-13128 at 6/8/20, 6:51 AM:
-

[~isapego] So I'm thinking of throwing IllegalStateException (assuming 
attempting to lock after it has been closed is an illegal state).

Can you confirm if this is correct behavior?


was (Author: kay_jpr):
So I'm thinking of throwing IllegalStateException (assuming attempting to lock 
after it has been closed is an illegal state).

Can you confirm if this is correct behavior?

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-08 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17127939#comment-17127939
 ] 

Kartik Somani commented on IGNITE-13128:


So I'm thinking of throwing IllegalStateException (assuming attempting to lock 
after it has been closed is an illegal state).

Can you confirm if this is correct behavior?

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-07 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17127738#comment-17127738
 ] 

Kartik Somani commented on IGNITE-13128:


What is the expected behavior? Should it be another exception?

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (IGNITE-13128) IgniteLock throws NullPointerException when removed before use

2020-06-07 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-13128?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani reassigned IGNITE-13128:
--

Assignee: Kartik Somani

> IgniteLock throws NullPointerException when removed before use
> --
>
> Key: IGNITE-13128
> URL: https://issues.apache.org/jira/browse/IGNITE-13128
> Project: Ignite
>  Issue Type: Bug
>  Components: data structures
>Affects Versions: 2.8
>Reporter: Pavel Tupitsyn
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
> Fix For: 2.9
>
>
> Reproducer: 
> {code:java}
> public void testClosedLockThrowsIgniteException() {
> final String lockName = "testRemovedLockThrowsIgniteException";
> Ignite srv = ignite(0);
> IgniteLock lock1 = srv.reentrantLock(lockName, false, false, true);
> IgniteLock lock2 = srv.reentrantLock(lockName, false, false, true);
> lock1.close();
> lock2.lock();
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-06-01 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17123354#comment-17123354
 ] 

Kartik Somani commented on IGNITE-12702:


[~PetrovMikhail]I've updated the pull request here: 
[https://github.com/apache/ignite/pull/7882]

 

please review

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-06-01 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17123350#comment-17123350
 ] 

Kartik Somani commented on IGNITE-12702:


Pull request for this 
https://issues.apache.org/jira/browse/IGNITE-12702?jql=project%20%3D%20IGNITE%20AND%20labels%20in%20(newbie)%20and%20status%20%3D%20OPEN

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-04-12 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17081874#comment-17081874
 ] 

Kartik Somani commented on IGNITE-12702:


I have created pull request for this ticket here : 
[https://github.com/apache/ignite/pull/7663]

Need some help in running test suite for this

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12696) Remove deprecated @MXBeanParametersNames and @MXBeanParametersDescriptions annotations

2020-03-29 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12696?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17070221#comment-17070221
 ] 

Kartik Somani commented on IGNITE-12696:


Anirban, I see this issue is still unassigned. Are you working/planning to work 
on it? If not, I can take it up.

> Remove deprecated @MXBeanParametersNames and @MXBeanParametersDescriptions 
> annotations
> --
>
> Key: IGNITE-12696
> URL: https://issues.apache.org/jira/browse/IGNITE-12696
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey N. Gura
>Priority: Major
>  Labels: newbie
> Fix For: 3.0
>
>
> {{@MXBeanParametersNames}} and {{@MXBeanParametersDescriptions}} annotations 
> are deprecated due to the change IGNITE-10698.
> Mentioned annotations must be removed in Apache Ignite 3.0 release, **but not 
> earlier**.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-03-26 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17067941#comment-17067941
 ] 

Kartik Somani commented on IGNITE-12702:


Also, IgniteCache interface has 3 implementations. I'll have to write log in 
each of these implementations, but won't be able to ensure that future 
implementations will also do this.

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-03-26 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17067939#comment-17067939
 ] 

Kartik Somani commented on IGNITE-12702:


Thats true. Just that on every call of .put, i'll be going through all 
attributes of value's type, to print warning that might be a rare event. Is the 
performance cost worth it?

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-03-25 Thread Kartik Somani (Jira)


[ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17067070#comment-17067070
 ] 

Kartik Somani commented on IGNITE-12702:


When should the warning be triggered? build time, cache creation 
(getOrCreateCache) or at the time of calling put for the cache? (thats when the 
annotation is actually used in case of key) ?

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (IGNITE-12702) Print warning when a cache value contains @AffinityKeyMapped annotation

2020-03-22 Thread Kartik Somani (Jira)


 [ 
https://issues.apache.org/jira/browse/IGNITE-12702?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani reassigned IGNITE-12702:
--

Assignee: Kartik Somani

> Print warning when a cache value contains @AffinityKeyMapped annotation
> ---
>
> Key: IGNITE-12702
> URL: https://issues.apache.org/jira/browse/IGNITE-12702
> Project: Ignite
>  Issue Type: Improvement
>  Components: cache
>Reporter: Denis Mekhanikov
>Assignee: Kartik Somani
>Priority: Major
>  Labels: newbie
>
> Consider the following code snippet:
> {code:java}
> public class WrongAffinityExample {
> public static void main(String[] args) {
> Ignite ignite = Ignition.start("config/ignite.xml");
> IgniteCache cache = 
> ignite.getOrCreateCache("employees");
> EmployeeKey key = new EmployeeKey(1);
> EmployeeValue value = new EmployeeValue(1, "Denis");
> cache.put(key, value);
> }
> public static class EmployeeKey {
> private int id;
> public EmployeeKey(int id) {
> this.id = id;
> }
> }
> public static class EmployeeValue {
> @AffinityKeyMapped
> int departmentId;
> String name;
> public EmployeeValue(int departmentId, String name) {
> this.departmentId = departmentId;
> this.name = name;
> }
> }
> }
> {code}
> Note, that {{EmployeeValue}} contains an {{@AffinityKeyMapped}} annotation, 
> which doesn't have any effect, since it's specified in a value, and not in a 
> key.
> Such mistake is simple to make and pretty hard to track down.
>  This configuration should trigger a warning message printed in log to let 
> the user know that this affinity key configuration is not applied.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-4797) Need to expose offheap memory allocated size metric for internal data structures

2017-04-05 Thread Kartik Somani (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-4797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15957196#comment-15957196
 ] 

Kartik Somani commented on IGNITE-4797:
---

I've addressed your comments [~agura], and raised another pull request. Please 
review

> Need to expose offheap memory allocated size metric for internal data 
> structures
> 
>
> Key: IGNITE-4797
> URL: https://issues.apache.org/jira/browse/IGNITE-4797
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey Gura
>Assignee: Kartik Somani
>  Labels: newbie
> Fix For: 2.0
>
>
> Offheap caches expose offheap memory allocated size via 
> {{CacheMetricsMXBean.getOffHeapAllocatedSize()}}. But this metric doesn't 
> take into account offheap memory that allocated for internal data structures 
> (GridUnsafeMap and LRU eviction policy). 
> However Ignite collects this metric (see 
> GridUnsafeMemory.systemAllocatedSize() method).
> Need to expose this metric via {{CacheMetricsMXBean}}.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (IGNITE-4797) Need to expose offheap memory allocated size metric for internal data structures

2017-03-12 Thread Kartik Somani (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-4797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15906476#comment-15906476
 ] 

Kartik Somani commented on IGNITE-4797:
---

[My First Bug]
The approach that I see is, I'll add the interface for getSystemAllocatedSize() 
to the CacheMetrics and CacheMetricsMxBean Interface. In CacheMetricsImpl, I'll 
use GridCacheContext object (cctx) object to get and return the 
systemAllocatedSize using : cctx.unsafeMemory.systemAllocatedSize(). 

CacheLocalMetricsMxBean will then call cache.metrics0.getSystemAllocatedSize() 
to return the metric.

Will this work?

> Need to expose offheap memory allocated size metric for internal data 
> structures
> 
>
> Key: IGNITE-4797
> URL: https://issues.apache.org/jira/browse/IGNITE-4797
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey Gura
>Assignee: Kartik Somani
>  Labels: newbie
> Fix For: 2.0
>
>
> Offheap caches expose offheap memory allocated size via 
> {{CacheMetricsMXBean.getOffHeapAllocatedSize()}}. But this metric doesn't 
> take into account offheap memory that allocated for internal data structures 
> (GridUnsafeMap and LRU eviction policy). 
> However Ignite collects this metric (see 
> GridUnsafeMemory.systemAllocatedSize() method).
> Need to expose this metric via {{CacheMetricsMXBean}}.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Assigned] (IGNITE-4797) Need to expose offheap memory allocated size metric for internal data structures

2017-03-11 Thread Kartik Somani (JIRA)

 [ 
https://issues.apache.org/jira/browse/IGNITE-4797?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kartik Somani reassigned IGNITE-4797:
-

Assignee: Kartik Somani

> Need to expose offheap memory allocated size metric for internal data 
> structures
> 
>
> Key: IGNITE-4797
> URL: https://issues.apache.org/jira/browse/IGNITE-4797
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey Gura
>Assignee: Kartik Somani
>  Labels: newbie
> Fix For: 2.0
>
>
> Offheap caches expose offheap memory allocated size via 
> {{CacheMetricsMXBean.getOffHeapAllocatedSize()}}. But this metric doesn't 
> take into account offheap memory that allocated for internal data structures 
> (GridUnsafeMap and LRU eviction policy). 
> However Ignite collects this metric (see 
> GridUnsafeMemory.systemAllocatedSize() method).
> Need to expose this metric via {{CacheMetricsMXBean}}.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (IGNITE-4797) Need to expose offheap memory allocated size metric for internal data structures

2017-03-09 Thread Kartik Somani (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-4797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15903713#comment-15903713
 ] 

Kartik Somani commented on IGNITE-4797:
---

Sure I'll do that. Thank you.

> Need to expose offheap memory allocated size metric for internal data 
> structures
> 
>
> Key: IGNITE-4797
> URL: https://issues.apache.org/jira/browse/IGNITE-4797
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey Gura
>  Labels: newbie
> Fix For: 2.0
>
>
> Offheap caches expose offheap memory allocated size via 
> {{CacheMetricsMXBean.getOffHeapAllocatedSize()}}. But this metric doesn't 
> take into account offheap memory that allocated for internal data structures 
> (GridUnsafeMap and LRU eviction policy). 
> However Ignite collects this metric (see 
> GridUnsafeMemory.systemAllocatedSize() method).
> Need to expose this metric via {{CacheMetricsMXBean}}.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (IGNITE-4797) Need to expose offheap memory allocated size metric for internal data structures

2017-03-07 Thread Kartik Somani (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-4797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15900020#comment-15900020
 ] 

Kartik Somani commented on IGNITE-4797:
---

I would like to work on this as my first ticket here. How can I assign it to 
myself?

> Need to expose offheap memory allocated size metric for internal data 
> structures
> 
>
> Key: IGNITE-4797
> URL: https://issues.apache.org/jira/browse/IGNITE-4797
> Project: Ignite
>  Issue Type: Improvement
>Reporter: Andrey Gura
>  Labels: newbie
> Fix For: 2.0
>
>
> Offheap caches expose offheap memory allocated size via 
> {{CacheMetricsMXBean.getOffHeapAllocatedSize()}}. But this metric doesn't 
> take into account offheap memory that allocated for internal data structures 
> (GridUnsafeMap and LRU eviction policy). 
> However Ignite collects this metric (see 
> GridUnsafeMemory.systemAllocatedSize() method).
> Need to expose this metric via {{CacheMetricsMXBean}}.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)