{"action":"created","issue":{"url":"https://api.github.com/repos/xetorthio/jedis/issues/1263","repository_url":"https://api.github.com/repos/xetorthio/jedis","labels_url":"https://api.github.com/repos/xetorthio/jedis/issues/1263/labels{/name}","comments_url":"https://api.github.com/repos/xetorthio/jedis/issues/1263/comments","events_url":"https://api.github.com/repos/xetorthio/jedis/issues/1263/events","html_url":"https://github.com/xetorthio/jedis/issues/1263","id":149783436,"number":1263,"title":"Resolve ambiguity between single argument and varargs by replacing varargs to Collection<>","user":{"login":"HeartSaVioR","id":1317309,"avatar_url":"https://avatars1.githubusercontent.com/u/1317309?v=3","gravatar_id":"","url":"https://api.github.com/users/HeartSaVioR","html_url":"https://github.com/HeartSaVioR","followers_url":"https://api.github.com/users/HeartSaVioR/followers","following_url":"https://api.github.com/users/HeartSaVioR/following{/other_user}","gists_url":"https://api.github.com/users/HeartSaVioR/gists{/gist_id}","starred_url":"https://api.github.com/users/HeartSaVioR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HeartSaVioR/subscriptions","organizations_url":"https://api.github.com/users/HeartSaVioR/orgs","repos_url":"https://api.github.com/users/HeartSaVioR/repos","events_url":"https://api.github.com/users/HeartSaVioR/events{/privacy}","received_events_url":"https://api.github.com/users/HeartSaVioR/received_events","type":"User","site_admin":false},"labels":[{"id":175479723,"url":"https://api.github.com/repos/xetorthio/jedis/labels/DISCUSSION%20NEEDED","name":"DISCUSSION NEEDED","color":"eb6420","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/xetorthio/jedis/milestones/10","html_url":"https://github.com/xetorthio/jedis/milestone/10","labels_url":"https://api.github.com/repos/xetorthio/jedis/milestones/10/labels","id":561407,"number":10,"title":"3.0.0","description":"","creator":{"login":"xetorthio","id":139687,"avatar_url":"https://avatars3.githubusercontent.com/u/139687?v=3","gravatar_id":"","url":"https://api.github.com/users/xetorthio","html_url":"https://github.com/xetorthio","followers_url":"https://api.github.com/users/xetorthio/followers","following_url":"https://api.github.com/users/xetorthio/following{/other_user}","gists_url":"https://api.github.com/users/xetorthio/gists{/gist_id}","starred_url":"https://api.github.com/users/xetorthio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xetorthio/subscriptions","organizations_url":"https://api.github.com/users/xetorthio/orgs","repos_url":"https://api.github.com/users/xetorthio/repos","events_url":"https://api.github.com/users/xetorthio/events{/privacy}","received_events_url":"https://api.github.com/users/xetorthio/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":30,"state":"open","created_at":"2014-02-06T21:15:59Z","updated_at":"2016-07-04T00:14:41Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2016-04-20T14:26:13Z","updated_at":"2017-06-02T11:33:23Z","closed_at":null,"body":"Relevant issue: #566 \n\nDue to ambiguity issue Scala users should use workaround like...\n\n```\nval stringArray = Array[String](\"mystring\")\nj.del(stringArray:_*)\n```\n\nIn order to avoid this issue, as I stated from #566, we should define two methods as...\n\ndel(String key);\ndel(String firstKey, String secondKey, String... remainKeys);\n\nwhich I really don't like it.\n\nSpring Data Redis uses Collection<> to avoid ambiguity. Some of the method definitions are...\n\nhttps://github.com/spring-projects/spring-data-redis/blob/master/src/main/java/org/springframework/data/redis/core/ScanOptions.java\nhttps://github.com/spring-projects/spring-data-redis/blob/master/src/main/java/org/springframework/data/redis/core/ZSetOperations.java\n\nWe should use Collection<> at least ambiguity methods, but it hurts consistency.\nSo I suggest we replace all methods using varargs to Collection<> to make consistency.\n\nIt changes Jedis APIs completely so this should be applied to only Jedis 3.0.0.\n\nIf we really want to apply workaround like `k1, k2, keys` I'm not sure that it breaks backward compatibility. It anyway could break `binary` backward compatibility.\n"},"comment":{"url":"https://api.github.com/repos/xetorthio/jedis/issues/comments/305761881","html_url":"https://github.com/xetorthio/jedis/issues/1263#issuecomment-305761881","issue_url":"https://api.github.com/repos/xetorthio/jedis/issues/1263","id":305761881,"user":{"login":"vy","id":72137,"avatar_url":"https://avatars3.githubusercontent.com/u/72137?v=3","gravatar_id":"","url":"https://api.github.com/users/vy","html_url":"https://github.com/vy","followers_url":"https://api.github.com/users/vy/followers","following_url":"https://api.github.com/users/vy/following{/other_user}","gists_url":"https://api.github.com/users/vy/gists{/gist_id}","starred_url":"https://api.github.com/users/vy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vy/subscriptions","organizations_url":"https://api.github.com/users/vy/orgs","repos_url":"https://api.github.com/users/vy/repos","events_url":"https://api.github.com/users/vy/events{/privacy}","received_events_url":"https://api.github.com/users/vy/received_events","type":"User","site_admin":false},"created_at":"2017-06-02T11:33:23Z","updated_at":"2017-06-02T11:33:23Z","body":"I am working on a throttler for [Log4j 2 Redis Appender](https://github.com/vy/log4j2-redis-appender). While calling `Jedis#rpush(String key, String... strings)`, I need to provide an array as a second parameter. For that purpose I'm re-using a pre-allocated `String[]` to avoid allocation at every call. Sometimes even when there are not enough messages to fill the buffer, I still want to push the messages. But since Java does not support shared slicing of arrays, I either need to create a new array and copy the contents from the bigger buffer to here, or just send them one by one each time. Accepting an `Iterable` or `Collection` in `rpush()` would really ease my work."}}
{"actor":{"display_login":"vy"}}