Re: Baseline auto-adjust`s discuss

2019-01-25 Thread Anton Kalashnikov
Vladimir, thanks  for your notes, both of them looks good enough but I have two 
different thoughts about it. 

I think I agree about enabling only one of manual/auto adjustment. It is easier 
than current solution and in fact as extra feature  we can allow user to force 
task to execute(if they doesn't want to wait until timeout expired). 
But about second one I don't sure that one parameters instead of two would be 
more convenient. For example: in case when user changed timeout and then 
disable auto-adjust after then when someone will want to enable it they should 
know what value of timeout was before auto-adjust was disabled. I think 
"negative value" pattern good choice for always usable parameters like timeout 
of connection (ex. -1 equal to endless waiting) and so on, but in our case we 
want to disable whole functionality rather than change parameter value.

-- 
Best regards,
Anton Kalashnikov


24.01.2019, 22:03, "Vladimir Ozerov" :
> Hi Anton,
>
> This is great feature, but I am a bit confused about automatic disabling of
> a feature during manual baseline adjustment. This may lead to unpleasant
> situations when a user enabled auto-adjustment, then re-adjusted it
> manually somehow (e.g. from some previously created script) so that
> auto-adjustment disabling went unnoticed, then added more nodes hoping that
> auto-baseline is still active, etc.
>
> Instead, I would rather make manual and auto adjustment mutually exclusive
> - baseline cannot be adjusted manually when auto mode is set, and vice
> versa. If exception is thrown in that cases, administrators will always
> know current behavior of the system.
>
> As far as configuration, wouldn’t it be enough to have a single long value
> as opposed to Boolean + long? Say, 0 - immediate auto adjustment, negative
> - disabled, positive - auto adjustment after timeout.
>
> Thoughts?
>
> чт, 24 янв. 2019 г. в 18:33, Anton Kalashnikov :
>
>>  Hello, Igniters!
>>
>>  Work on the Phase II of IEP-4 (Baseline topology) [1] has started. I want
>>  to start to discuss of implementation of "Baseline auto-adjust" [2].
>>
>>  "Baseline auto-adjust" feature implements mechanism of auto-adjust
>>  baseline corresponding to current topology after event join/left was
>>  appeared. It is required because when a node left the grid and nobody would
>>  change baseline manually it can lead to lost data(when some more nodes left
>>  the grid on depends in backup factor) but permanent tracking of grid is not
>>  always possible/desirible. Looks like in many cases auto-adjust baseline
>>  after some timeout is very helpfull.
>>
>>  Distributed metastore[3](it is already done):
>>
>>  First of all it is required the ability to store configuration data
>>  consistently and cluster-wide. Ignite doesn't have any specific API for
>>  such configurations and we don't want to have many similar implementations
>>  of the same feature in our code. After some thoughts is was proposed to
>>  implement it as some kind of distributed metastorage that gives the ability
>>  to store any data in it.
>>  First implementation is based on existing local metastorage API for
>>  persistent clusters (in-memory clusters will store data in memory).
>>  Write/remove operation use Discovery SPI to send updates to the cluster, it
>>  guarantees updates order and the fact that all existing (alive) nodes have
>>  handled the update message. As a way to find out which node has the latest
>>  data there is a "version" value of distributed metastorage, which is
>>  basically . All updates history
>>  until some point in the past is stored along with the data, so when an
>>  outdated node connects to the cluster it will receive all the missing data
>>  and apply it locally. If there's not enough history stored or joining node
>>  is clear then it'll receive shapshot of distributed metastorage so there
>>  won't be inconsistencies.
>>
>>  Baseline auto-adjust:
>>
>>  Main scenario:
>>  - There is grid with the baseline is equal to the current topology
>>  - New node joins to grid or some node left(failed) the grid
>>  - New mechanism detects this event and it add task for changing
>>  baseline to queue with configured timeout
>>  - If new event are happened before baseline would be changed task
>>  would be removed from queue and new task will be added
>>  - When timeout are expired the task would try to set new baseline
>>  corresponded to current topology
>>
>>  First of all we need to add two parameters[4]:
>>  - baselineAutoAdjustEnabled - enable/disable "Baseline
>>  auto-adjust" feature.
>>  - baselineAutoAdjustTimeout - timeout after which baseline should
>>  be changed.
>>
>>  This parameters are cluster wide and can be changed in real time because
>>  it is based on "Distributed metastore". On first time this parameters would
>>  be initiated by corresponded parameters(initBaselineAutoAdjustEnabled,
>>  initBaselineAutoAdjustTimeout) from "

Re: CacheInterceptor ClassCastException in case of cache was updated from thin java client

2019-01-25 Thread Sergey Antonov
Ivan, thank you. I started wrote same test today)

пт, 25 янв. 2019 г. в 10:16, Павлухин Иван :

> Pavel,
>
> Initially I meant Java thick client. And I see the difference between
> thin and thick Java clients. As was already mentioned thin Java client
> behaves in way like each cache is enforced to not unwrap binary
> objects (withKeepBinary()). You can see a test demonstrating current
> behavior [1].
>
> [1] https://gist.github.com/pavlukhin/2c76d11cde5243a73f01019cdd15d243
>
> чт, 24 янв. 2019 г. в 23:01, Pavel Tupitsyn :
> >
> > Ivan,
> >
> > There is no inconsistency between thick and thin clients.
> > All of them work with caches in binary mode, see ClientCacheRequest
> (thin)
> > and PlatformCache (thick) classes.
> >
> > On Thu, Jan 24, 2019 at 10:26 PM Ivan Pavlukhina 
> > wrote:
> >
> > > Sergey,
> > >
> > > There are couple of things which should be addressed:
> > > 1. Unnecessary deserialization.
> > > 2. Inconsistent behavior.
> > > 3. Unclear documentation.
> > >
> > > Deserialization is not free and in my mind should be avoided where
> > > possible. I think that if some feature (like interceptors) requires
> > > deserialization then it should be enabled explicitly and an impact
> should
> > > be clear to user. I can imagine a toggle “withAllowedDeserialization”.
> > >
> > > If there is an inconsistency between thick and thin clients it should
> be
> > > eliminated. I do not see a reason why behavior should be different.
> > >
> > > If something is a good thing but it is not intuitive it could be
> > > documented. But if there is s really good reason for it. Otherwise
> > > simplicity and consistency are better alias.
> > >
> > > > On 24 Jan 2019, at 17:42, Sergey Antonov 
> > > wrote:
> > > >
> > > > I think it's bad idea. This contract nowhere defined and it's not
> clear
> > > for
> > > > users.
> > > >
> > > > чт, 24 янв. 2019 г. в 17:18, Pavel Tupitsyn :
> > > >
> > > >> Yes
> > > >>
> > > >> On Thu, Jan 24, 2019 at 5:15 PM Sergey Antonov <
> > > antonovserge...@gmail.com>
> > > >> wrote:
> > > >>
> > > >>> Pavel,
> > > >>>
> > > >>> "Leave it as is, use instanceof."
> > > >>> You meant always use CacheInterceptor and in all
> > > methods
> > > >>> check, that passed arguments is BinaryObject?
> > > >>>
> > > >>> чт, 24 янв. 2019 г. в 17:10, Pavel Tupitsyn  >:
> > > >>>
> > >  I don't think we should complicate things. Leave it as is, use
> > > >>> instanceof.
> > >  The fact is - you can get anything, BinaryObject or any user
> class, so
> > > >> be
> > >  prepared.
> > >  Good example of older API is CacheEvent, which actually has
> oldValue()
> > > >>> and
> > >  newValue() as Object.
> > > 
> > >  Igniters, any other thoughts?
> > > 
> > > 
> > >  On Thu, Jan 24, 2019 at 2:16 PM Sergey Antonov <
> > > >>> antonovserge...@gmail.com>
> > >  wrote:
> > > 
> > > > Pavel, how about marker interface
> DeserializedValueCacheInterceptor?
> > > >> We
> > > > will deserialize data and pass it to cache interceptor, if
> > >  CacheInterceptor
> > > > implements marker interface.
> > > >
> > > > чт, 24 янв. 2019 г. в 13:41, Pavel Tupitsyn <
> ptupit...@apache.org>:
> > > >
> > > >> You are exactly right, generic parameters don't make much sense
> > > >> here.
> > > >> Ignite caches are not restricted to any type, and there is type
> > > >>> erasure
> > > > in
> > > >> Java so you have no runtime guarantees.
> > > >>
> > > >> Maybe Interceptor design should be improved (e.g. add a flag to
> > > >> force
> > > >> binary or non-binary mode),
> > > >> but Thin or Thick client connector logic is unrelated here.
> > > >> withKeepBinary() call is valid and should not depend on
> Interceptor
> > > >> presence or implementation.
> > > >>
> > > >> On Thu, Jan 24, 2019 at 1:17 PM Sergey Antonov <
> > > > antonovserge...@gmail.com>
> > > >> wrote:
> > > >>
> > > >>> Hi, Pavel,
> > > >>>
> > > >>> "Interceptor should support both modes, binary or not. Any code
> > > >> can
> > > > call
> > > >>> withKeepBinary(), this should be expected.
> > > >>> Just add if (x instanceof BinaryObject) and go from there. "
> > > >>> I don't agree. The cache interceptor[1] is a parametrized class
> > > >> and
> > >  you
> > > >>> couldn't pass multiple cache interceptors in cache
> configuration.
> > > >>> So
> > > > all
> > > >>> cache interceptors must have Object, Object parameters for
> > > >>> supporting
> > > >> both
> > > >>> modes: binary and deserialized. In this case parametrized class
> > > >> no
> > > > sense.
> > > >>>
> > > >>> [1]
> > > >>>
> > > >>>
> > > >>
> > > >
> > > 
> > > >>>
> > > >>
> > >
> https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/cache/CacheInterceptor.html
> > > >>>
> > > >>> чт, 24 янв. 2019 г. в 13:06, Pavel Tupitsyn <
> > > >> ptupit...@apache.or

Distributed MetaStorage discussion

2019-01-25 Thread Ivan Bessonov
Hello, Igniters!

Here's more info "Distributed MetaStorage" feature [1]. It is a part of
Phase II for
IEP-4 (Baseline topology) [2] and was mentioned in recent "Baseline
auto-adjust`s
discuss" topic. I'll partially duplicate that message here.

One of key requirements is the ability to store configuration data (or any
other data)
consistently and cluster-wide. There are also other tickets that require
similar
mechanisms, for example [3]. Ignite doesn't have any specific API for such
configurations and we don't want to have many similar implementations of the
same feature across the code.

There are several API methods required for the feature:

 - read(key) / iterate(keyPrefix) - access to the distributed data. Should
be
   consistent for all nodes in cluster when it's in active state.
 - write / remove - modify data in distributed metastorage. Should
guarantee that
   every node in cluster will have this update after the method is finished.
 - writeAsync / removeAsync (not yet implemented) - same as above, but
async.
   Might be useful if one needs to update several values one after another.
 - compareAndWrite / compareAndRemove - helpful to reduce number of data
   updates (more on that later).
 - listen(keyPredicate) - a way of being notified when some data was
changed.
   Normally it is triggered on "write/remove" operation or node activation.
Listener
   itself will be notified with .

Now some implementation details:

First implementation is based on existing local metastorage API for
persistent
clusters (in-memory clusters will store data in memory). Write/remove
operation
use Discovery SPI to send updates to the cluster, it guarantees updates
order
and the fact that all existing (alive) nodes have handled the update
message.

As a way to find out which node has the latest data there is a "version"
value of
distributed metastorage, which is basically . Whole updates history until some point in the past is stored
along with
the data, so when an outdated node connects to the cluster it will receive
all the
missing data and apply it locally. Listeners will also be invoked after
such updates.
If there's not enough history stored or joining node is clear then it'll
receive
shapshot of distributed metastorage so there won't be inconsistencies.
"compareAndWrite" / "compareAndRemove" API might help reducing the size of
the history, especially for Boolean or other primitive values.

There are, of course, many more details, feel free to ask about them. First
implementation is in master, but there are already known improvements that
can
be done and I'm working on them right now.

See package "org.apache.ignite.internal.processors.metastorage" for the new
interfaces and comment your opinion or questions. Thank you!

[1] https://issues.apache.org/jira/browse/IGNITE-10640
[2]
https://cwiki.apache.org/confluence/display/IGNITE/IEP-4+Baseline+topology+for+caches
[3] https://issues.apache.org/jira/browse/IGNITE-8717

-- 
Sincerely yours,
Ivan Bessonov


Re: [DISCUSSION] Control.sh global rework in apache ignite 3.0

2019-01-25 Thread Sergey Kozlov
Sergey

You're right that both modes would be good to support.
My concerns are about the approaches for interactive mode and current
implementation for visor cmd looks ugly: in interactive mode you execute
command like in command-line:
*visor> disco -r -t=2m -c=1*

I think the interactive mode should look close to SQL (but it will require
to implement a parser and increase the complexity of development)


On Thu, Jan 24, 2019 at 11:36 PM Sergey  wrote:

> Hi!
> Why should we choose between interactive and command mode?
> I'd suggest that new utility doesn't matter of its name control.sh or visor
> should have support of both modes.
>
> Sergey Kosarev
>
> чт, 24 янв. 2019 г., 23:02 Denis Magda dma...@apache.org:
>
> > Sergey,
> >
> > Let's break and rebuild the visor from the ground. It's fine if it
> becomes
> > incompatible with older versions.
> >
> > -
> > Denis
> >
> >
> > On Thu, Jan 24, 2019 at 7:05 AM Sergey Kozlov 
> > wrote:
> >
> > > Denis
> > >
> > > I'm not sure that visorcmd can be refactored without incompatible
> changes
> > > or significant changes for behaviour:
> > > 1. Visorcmd starts as demon node and joins the cluster. The modern
> > > utilities don't need spring config and just connect to TCP management
> > port.
> > > 2. Visorcmd is mostly an interactive tool but control.sh looks like
> *nix
> > > regular command-line program.
> > > 3. Visorcmd command set (IMO) is weird and has some commands that
> > sometimes
> > > are not about ignite (like deploy - copy file to remote nodes) or not
> > clear
> > > why we need them (mlist/mget/mcompact)
> > >
> > > I think we should define the root purpose for new utility (or for
> > > refactored visorcmd)
> > > From my standpoint they are following:
> > >  - cluster status commands (topology, node status, configuration, etc)
> > >  - cluster management commands (control.sh baseline commands + visrcmd
> > > kill/stop nodes)
> > >  - cache content commands (print/clear cache content)
> > >  - cache management commands (create/stop/destroy/copy/rename etc
> cache)
> > >  - service/job management commands (start/stop/restart service/job)
> > >  - tx management (tx list, kill)
> > >  - data consistency commands (idle_verify, crc_check, checkpoint)
> > >  - statistics commands (cluster/cache metrics)
> > >
> > >
> > >
> > >
> > > On Thu, Jan 24, 2019 at 12:12 PM Sergey Antonov <
> > antonovserge...@gmail.com
> > > >
> > > wrote:
> > >
> > > > Alexey, Denis I agree yours points.
> > > >
> > > > I think we should rewrite visor.cmd from scala to java at first. And
> > then
> > > > merge control.sh into visor.cmd.
> > > >
> > > > чт, 24 янв. 2019 г. в 11:44, Alexey Kuznetsov  >:
> > > >
> > > > > I agree with Denis,
> > > > >
> > > > > How about to merge control.sh into Visor.CMD ?
> > > > > And rewrite Visor.CMD from Scala to Java.
> > > > >
> > > > > What do you think?
> > > > >
> > > > > On Thu, Jan 24, 2019 at 4:41 AM Denis Magda 
> > wrote:
> > > > >
> > > > > > Why don't we go in a reverse direction - instead of creating
> > multiple
> > > > > > scripts for different needs we incorporate all capabilities
> within
> > > > > > visorcmd? Visor is an app/script that can be updated to meet the
> > > > > > requirements of specific tools.
> > > > > >
> > > > > >
> > > > > > -
> > > > > > Denis
> > > > > >
> > > > > >
> > > > > > On Wed, Jan 23, 2019 at 1:23 PM Sergey Kozlov <
> > skoz...@gridgain.com>
> > > > > > wrote:
> > > > > >
> > > > > > > Thanks Sergey for the raising the question.
> > > > > > >
> > > > > > > What's about move actual/interesting commands from visorcmd and
> > > > remove
> > > > > > that
> > > > > > > script at all?
> > > > > > >
> > > > > > > Also would good simplify the bash code of script and ideally
> > > process
> > > > > > > everyting inside java code?
> > > > > > >
> > > > > > > On Wed, Jan 23, 2019 at 7:38 PM Stanislav Lukyanov <
> > > > > > stanlukya...@gmail.com
> > > > > > > >
> > > > > > > wrote:
> > > > > > >
> > > > > > > > I value strict compatibility rules very highly, and would be
> > > happy
> > > > if
> > > > > > we
> > > > > > > > never removed a public class (even if it is in the “internal”
> > > > > package)
> > > > > > > > in a minor release.
> > > > > > > > Unfortunately, Ignite is far from that place for now. We
> don’t
> > > have
> > > > > any
> > > > > > > > distinction between API and internal classes, don’t have
> > > > > > > > plugin-only APIs, etc. All classes are public, everything is
> > > > > accessible
> > > > > > > to
> > > > > > > > user code. We even refer to internal classes in public
> Javadoc
> > > > > > > > (e.g. I recall mentions of IgniteUtils in examples here and
> > > there).
> > > > > > > > Considering this, moving CommandHandler from ignite-core to
> > > > > > > > ignite-control-utility
> > > > > > > > doesn't look that bad. It doesn’t differ to much from any
> other
> > > > > change
> > > > > > > > that removes or renames a class.
> > > > > > > > There could be required changes with a h

Re: Baseline auto-adjust`s discuss

2019-01-25 Thread Vladimir Ozerov
Got it, makes sense.

On Fri, Jan 25, 2019 at 11:06 AM Anton Kalashnikov 
wrote:

> Vladimir, thanks  for your notes, both of them looks good enough but I
> have two different thoughts about it.
>
> I think I agree about enabling only one of manual/auto adjustment. It is
> easier than current solution and in fact as extra feature  we can allow
> user to force task to execute(if they doesn't want to wait until timeout
> expired).
> But about second one I don't sure that one parameters instead of two would
> be more convenient. For example: in case when user changed timeout and then
> disable auto-adjust after then when someone will want to enable it they
> should know what value of timeout was before auto-adjust was disabled. I
> think "negative value" pattern good choice for always usable parameters
> like timeout of connection (ex. -1 equal to endless waiting) and so on, but
> in our case we want to disable whole functionality rather than change
> parameter value.
>
> --
> Best regards,
> Anton Kalashnikov
>
>
> 24.01.2019, 22:03, "Vladimir Ozerov" :
> > Hi Anton,
> >
> > This is great feature, but I am a bit confused about automatic disabling
> of
> > a feature during manual baseline adjustment. This may lead to unpleasant
> > situations when a user enabled auto-adjustment, then re-adjusted it
> > manually somehow (e.g. from some previously created script) so that
> > auto-adjustment disabling went unnoticed, then added more nodes hoping
> that
> > auto-baseline is still active, etc.
> >
> > Instead, I would rather make manual and auto adjustment mutually
> exclusive
> > - baseline cannot be adjusted manually when auto mode is set, and vice
> > versa. If exception is thrown in that cases, administrators will always
> > know current behavior of the system.
> >
> > As far as configuration, wouldn’t it be enough to have a single long
> value
> > as opposed to Boolean + long? Say, 0 - immediate auto adjustment,
> negative
> > - disabled, positive - auto adjustment after timeout.
> >
> > Thoughts?
> >
> > чт, 24 янв. 2019 г. в 18:33, Anton Kalashnikov :
> >
> >>  Hello, Igniters!
> >>
> >>  Work on the Phase II of IEP-4 (Baseline topology) [1] has started. I
> want
> >>  to start to discuss of implementation of "Baseline auto-adjust" [2].
> >>
> >>  "Baseline auto-adjust" feature implements mechanism of auto-adjust
> >>  baseline corresponding to current topology after event join/left was
> >>  appeared. It is required because when a node left the grid and nobody
> would
> >>  change baseline manually it can lead to lost data(when some more nodes
> left
> >>  the grid on depends in backup factor) but permanent tracking of grid
> is not
> >>  always possible/desirible. Looks like in many cases auto-adjust
> baseline
> >>  after some timeout is very helpfull.
> >>
> >>  Distributed metastore[3](it is already done):
> >>
> >>  First of all it is required the ability to store configuration data
> >>  consistently and cluster-wide. Ignite doesn't have any specific API for
> >>  such configurations and we don't want to have many similar
> implementations
> >>  of the same feature in our code. After some thoughts is was proposed to
> >>  implement it as some kind of distributed metastorage that gives the
> ability
> >>  to store any data in it.
> >>  First implementation is based on existing local metastorage API for
> >>  persistent clusters (in-memory clusters will store data in memory).
> >>  Write/remove operation use Discovery SPI to send updates to the
> cluster, it
> >>  guarantees updates order and the fact that all existing (alive) nodes
> have
> >>  handled the update message. As a way to find out which node has the
> latest
> >>  data there is a "version" value of distributed metastorage, which is
> >>  basically . All updates history
> >>  until some point in the past is stored along with the data, so when an
> >>  outdated node connects to the cluster it will receive all the missing
> data
> >>  and apply it locally. If there's not enough history stored or joining
> node
> >>  is clear then it'll receive shapshot of distributed metastorage so
> there
> >>  won't be inconsistencies.
> >>
> >>  Baseline auto-adjust:
> >>
> >>  Main scenario:
> >>  - There is grid with the baseline is equal to the current
> topology
> >>  - New node joins to grid or some node left(failed) the grid
> >>  - New mechanism detects this event and it add task for changing
> >>  baseline to queue with configured timeout
> >>  - If new event are happened before baseline would be changed
> task
> >>  would be removed from queue and new task will be added
> >>  - When timeout are expired the task would try to set new
> baseline
> >>  corresponded to current topology
> >>
> >>  First of all we need to add two parameters[4]:
> >>  - baselineAutoAdjustEnabled - enable/disable "Baseline
> >>  auto-adjust" feature.
> >>  - baselineAutoAdjustTimeout - timeout after which baseline
> s

[jira] [Created] (IGNITE-11076) Add documentation for control.sh idle_verify --exclude-caches

2019-01-25 Thread Sergey Antonov (JIRA)
Sergey Antonov created IGNITE-11076:
---

 Summary: Add documentation for control.sh idle_verify 
--exclude-caches
 Key: IGNITE-11076
 URL: https://issues.apache.org/jira/browse/IGNITE-11076
 Project: Ignite
  Issue Type: Task
  Components: documentation
Reporter: Sergey Antonov
Assignee: Artem Budnikov
 Fix For: 2.8


control.sh cache --help output 
{noformat}
The '--cache subcommand' is used to get information about and perform actions 
with caches. The command has the following syntax:

control.sh [--host HOST_OR_IP] [--port PORT] [--user USER] [--password 
PASSWORD] [--ping-interval PING_INTERVAL] [--ping-timeout PING_TIMEOUT] 
[--ssl-protocol SSL_PROTOCOL[, SSL_PROTOCOL_2, ..., SSL_PROTOCOL_N]] 
[--ssl-cipher-suites SSL_CIPHER_1[, SSL_CIPHER_2, ..., SSL_CIPHER_N]] 
[--ssl-key-algorithm SSL_KEY_ALGORITHM] [--keystore-type KEYSTORE_TYPE] 
[--keystore KEYSTORE_PATH] [--keystore-password KEYSTORE_PASSWORD] 
[--truststore-type TRUSTSTORE_TYPE] [--truststore TRUSTSTORE_PATH] 
[--truststore-password TRUSTSTORE_PASSWORD] --cache [subcommand] 


The subcommands that take [nodeId] as an argument ('list', 'contention' and 
'validate_indexes') will be executed on the given node or on all server nodes 
if the option is not specified. Other commands will run on a random server node.


Subcommands:


--cache list regexPattern [--groups|--seq] [nodeId] [--config] [--output-format 
multi-line]

Show information about caches, groups or sequences that match a regular 
expression. When executed without parameters, this subcommand prints the list 
of caches.

Parameters:
--config - print all configuration parameters for each cache.
--output-format multi-line - print configuration parameters per line. This 
option has effect only when used with --config and without [--groups|--seq].
--groups - print information about groups.
--seq - print information about sequences.



--cache contention minQueueSize [nodeId] [maxPrint]

Show the keys that are point of contention for multiple transactions.



--cache idle_verify [--dump] [--skip-zeros] [--check-crc] [(--exclude-caches 
cacheName1,...,cacheNameN)|(--cache-filter 
ALL|SYSTEM|PERSISTENT|NOT_PERSISTENT)|cacheName1,...,cacheNameN]

Verify counters and hash sums of primary and backup partitions for the 
specified caches on an idle cluster and print out the differences, if any.

Parameters:
--check-crc - check the CRC-sum of pages stored on disk before verifying data 
consistency in partitions between primary and backup nodes.



--cache validate_indexes [cacheName1,...,cacheNameN] [nodeId] [--check-first 
N|--check-through K]

Validate indexes on an idle cluster and print out the keys that are missing in 
the indexes.

Parameters:
--check-first N - validate only the first N keys
--check-through K - validate every Kth key



--cache distribution nodeId|null [cacheName1,...,cacheNameN] [--user-attributes 
attrName1,...,attrNameN]

Prints the information about partition distribution.



--cache reset_lost_partitions cacheName1,...,cacheNameN

Reset the state of lost partitions for the specified caches.{noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11077) Add information about SSL cipher suites to apacheignite.readme.io

2019-01-25 Thread Sergey Antonov (JIRA)
Sergey Antonov created IGNITE-11077:
---

 Summary: Add information about SSL cipher suites to 
apacheignite.readme.io
 Key: IGNITE-11077
 URL: https://issues.apache.org/jira/browse/IGNITE-11077
 Project: Ignite
  Issue Type: Task
  Components: documentation
Reporter: Sergey Antonov


I didn't find information about ssl cipher suites on 
https://apacheignite.readme.io/docs/ssltls



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11079) MVCC: IgniteCacheContinuousQueryBackupQueueTest is flacky.

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11079:
-

 Summary: MVCC: IgniteCacheContinuousQueryBackupQueueTest is flacky.
 Key: IGNITE-11079
 URL: https://issues.apache.org/jira/browse/IGNITE-11079
 Project: Ignite
  Issue Type: Test
  Components: mvcc
Reporter: Andrew Mashenkov


See Tc run
 
[https://ci.ignite.apache.org/viewLog.html?buildId=2859831&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccQueries#testNameId925274886589214180]

Test fails after series of long JVM pauses with stacktrace:
{code:java}
junit.framework.AssertionFailedError
 at junit.framework.Assert.fail(Assert.java:55)
 at junit.framework.Assert.assertTrue(Assert.java:22)
 at junit.framework.Assert.assertTrue(Assert.java:31)
 at 
org.apache.ignite.internal.processors.cache.query.continuous.IgniteCacheContinuousQueryBackupQueueTest.testManyQueryBackupQueue(IgniteCacheContinuousQueryBackupQueueTest.java:175)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:498)
 at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
 at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
 at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
 at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
 at 
org.apache.ignite.testframework.junits.GridAbstractTest$6.run(GridAbstractTest.java:2088)
 at java.lang.Thread.run(Thread.java:748){code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11078) MVCC: Tests fails sporadically with ConcurrentModificationException

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11078:
-

 Summary: MVCC: Tests fails sporadically with 
ConcurrentModificationException
 Key: IGNITE-11078
 URL: https://issues.apache.org/jira/browse/IGNITE-11078
 Project: Ignite
  Issue Type: Test
  Components: mvcc
Reporter: Andrew Mashenkov


Next test failed on TC.

[CacheMvccReplicatedSqlCoordinatorFailoverTest.testCoordinatorChangeActiveQueryClientFails_Simple|https://ci.ignite.apache.org/viewLog.html?buildId=2902796&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccQueries#testNameId3071204292938919018]

See TC run for details:

[TC 
run|https://ci.ignite.apache.org/viewLog.html?buildId=2902796&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccQueries#testNameId3071204292938919018]


Stacktrace example:
{code:java}
java.util.ConcurrentModificationException
at java.util.HashMap$HashIterator.nextNode(HashMap.java:1442)
at java.util.HashMap$KeyIterator.next(HashMap.java:1466)
at java.util.AbstractCollection.toString(AbstractCollection.java:461)
at java.lang.String.valueOf(String.java:2994)
at java.lang.StringBuilder.append(StringBuilder.java:131)
at 
java.util.concurrent.ConcurrentHashMap.toString(ConcurrentHashMap.java:1321)
at java.lang.String.valueOf(String.java:2994)
at java.lang.StringBuilder.append(StringBuilder.java:131)
at 
org.apache.ignite.internal.processors.cache.mvcc.CacheMvccAbstractTest$12.apply(CacheMvccAbstractTest.java:1757)
at 
org.apache.ignite.testframework.GridTestUtils.waitForCondition(GridTestUtils.java:1682)
at 
org.apache.ignite.internal.processors.cache.mvcc.CacheMvccAbstractTest.checkActiveQueriesCleanup(CacheMvccAbstractTest.java:1750)
at 
org.apache.ignite.internal.processors.cache.mvcc.CacheMvccAbstractBasicCoordinatorFailoverTest.checkCoordinatorChangeActiveQueryClientFails_Simple(CacheMvccAbstractBasicCoordinatorFailoverTest.java:689)
at 
org.apache.ignite.internal.processors.cache.mvcc.CacheMvccAbstractSqlCoordinatorFailoverTest.testCoordinatorChangeActiveQueryClientFails_Simple(CacheMvccAbstractSqlCoordinatorFailoverTest.java:164)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.apache.ignite.testframework.junits.GridAbstractTest$6.run(GridAbstractTest.java:2088)
at java.lang.Thread.run(Thread.java:748)
{code}
 

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11080) Flacky test GridCacheDhtPreloadDelayedSelfTest.testManualPreload

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11080:
-

 Summary: Flacky test 
GridCacheDhtPreloadDelayedSelfTest.testManualPreload
 Key: IGNITE-11080
 URL: https://issues.apache.org/jira/browse/IGNITE-11080
 Project: Ignite
  Issue Type: Test
Reporter: Andrew Mashenkov


Test is flacky on TC.

Seems, we have to either add ScaleFactor support for those test or rework to 
make it finish in test timeout.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11081) Flacky test CacheGetReadFromBackupFailoverTest.testFailover

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11081:
-

 Summary: Flacky test 
CacheGetReadFromBackupFailoverTest.testFailover
 Key: IGNITE-11081
 URL: https://issues.apache.org/jira/browse/IGNITE-11081
 Project: Ignite
  Issue Type: Test
Reporter: Andrew Mashenkov


[CacheGetReadFromBackupFailoverTest.testFailover|https://ci.ignite.apache.org/viewLog.html?buildId=2899047&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccCache2#testNameId1077882218748001125]
 fails on TC sporadically.

Smth goes wrong on node stop. At first glance, test is broken.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11082) Test GridCacheDhtTxPreloadSelfTest.testLocalTxPreloadingPessimistic hangs on TC sporadically.

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11082:
-

 Summary: Test 
GridCacheDhtTxPreloadSelfTest.testLocalTxPreloadingPessimistic hangs on TC 
sporadically.
 Key: IGNITE-11082
 URL: https://issues.apache.org/jira/browse/IGNITE-11082
 Project: Ignite
  Issue Type: Test
  Components: mvcc
Reporter: Andrew Mashenkov


[GridCacheDhtTxPreloadSelfTest.testLocalTxPreloadingPessimistic|https://ci.ignite.apache.org/viewLog.html?buildId=2899049&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccCache4#testNameId-815824464492790356]
 hanged on TC.

I've saw no failures in non-mvcc 4 cache suite. Probably, the issue relates to 
mvcc.

TC run:
https://ci.ignite.apache.org/viewLog.html?buildId=2899049&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccCache4#testNameId-815824464492790356



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: Review and merge IGNITE-10921

2019-01-25 Thread Dmitriy Pavlov
I see that discussion is already running in
https://github.com/apache/ignite/pull/5891/files

So let's merge once we reach consensus on changes. Don't hesitate to
contact me if you need my assistance.

чт, 24 янв. 2019 г. в 15:40, Dmitriy Pavlov :

> Count on my support if nobody else would like to help with the merge.
> Eventually, I will pick up.
>
> ср, 23 янв. 2019 г. в 19:53, Stanislav Lukyanov :
>
>> Hi Igniters,
>>
>> Can anyone please review and merge IGNITE-10921?
>> Artur Muradimov contributed the change, I did a review myself and now we
>> need a committer to finish this.
>>
>> Thanks,
>> Stan
>>
>>


[jira] [Created] (IGNITE-11083) SQL: Extract query model from splitter

2019-01-25 Thread Vladimir Ozerov (JIRA)
Vladimir Ozerov created IGNITE-11083:


 Summary: SQL: Extract query model from splitter
 Key: IGNITE-11083
 URL: https://issues.apache.org/jira/browse/IGNITE-11083
 Project: Ignite
  Issue Type: Task
  Components: sql
Reporter: Vladimir Ozerov
Assignee: Vladimir Ozerov
 Fix For: 2.8


We will need a common query model with join/subquery info for future splitter 
and partition pruning improvements. 
Let's extract accurately the model from splitter aiming to reuse it for 
partition pruning in future.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11084) Change copyrights to 2019

2019-01-25 Thread Andrey Aleksandrov (JIRA)
Andrey Aleksandrov created IGNITE-11084:
---

 Summary: Change copyrights to 2019
 Key: IGNITE-11084
 URL: https://issues.apache.org/jira/browse/IGNITE-11084
 Project: Ignite
  Issue Type: Task
Reporter: Andrey Aleksandrov
Assignee: Andrey Aleksandrov
 Fix For: 2.8


Change copyrights to 2019



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11085) MVCC: Mute GridCachePartitionEvictionDuringReadThroughSelfTest.

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11085:
-

 Summary: MVCC: Mute 
GridCachePartitionEvictionDuringReadThroughSelfTest.
 Key: IGNITE-11085
 URL: https://issues.apache.org/jira/browse/IGNITE-11085
 Project: Ignite
  Issue Type: Test
  Components: mvcc
Reporter: Andrew Mashenkov


There is no need to run GridCachePartitionEvictionDuringReadThroughSelfTest in 
MvccCache 6 suite.

Test uses ATOMIC cache, so we have to either remove it from mvcc run or make it 
use TRANSACTIONAL cache and mute with certain reason as no CacheStore is 
supported in Mvcc mode.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11086) IGNITE_REST_SECURITY_TOKEN_TIMEOUT parameter is set in deciseconds instead of seconds.

2019-01-25 Thread Vitaliy Biryukov (JIRA)
Vitaliy Biryukov created IGNITE-11086:
-

 Summary: IGNITE_REST_SECURITY_TOKEN_TIMEOUT parameter is set in 
deciseconds instead of seconds.
 Key: IGNITE-11086
 URL: https://issues.apache.org/jira/browse/IGNITE-11086
 Project: Ignite
  Issue Type: Bug
  Components: rest
Affects Versions: 2.7
Reporter: Vitaliy Biryukov


According to javaDoc IGNITE_REST_SECURITY_TOKEN_TIMEOUT should sit in seconds.

Can be fixed by multiplying this parameter by 1000 instead of 100 in 
GridRestProcessor's constructor:
{code:java}
sesTokTtl = IgniteSystemProperties.getLong(IGNITE_REST_SECURITY_TOKEN_TIMEOUT, 
DFLT_SES_TOKEN_INVALIDATE_INTERVAL) * 100;
{code}




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: Baseline auto-adjust`s discuss

2019-01-25 Thread Sergey Chugunov
Anton,

As I understand from the IEP document policy was supposed to support two
timeouts: soft and hard, so here you're proposing a bit simpler
functionality.

Just to clarify, do I understand correctly that this feature when enabled
will auto-adjust blt on each node join/node left event, and timeout is
necessary to protect us from blinking nodes?
So no complexities with taking into account number of alive backups or
something like that?

On Fri, Jan 25, 2019 at 1:11 PM Vladimir Ozerov 
wrote:

> Got it, makes sense.
>
> On Fri, Jan 25, 2019 at 11:06 AM Anton Kalashnikov 
> wrote:
>
> > Vladimir, thanks  for your notes, both of them looks good enough but I
> > have two different thoughts about it.
> >
> > I think I agree about enabling only one of manual/auto adjustment. It is
> > easier than current solution and in fact as extra feature  we can allow
> > user to force task to execute(if they doesn't want to wait until timeout
> > expired).
> > But about second one I don't sure that one parameters instead of two
> would
> > be more convenient. For example: in case when user changed timeout and
> then
> > disable auto-adjust after then when someone will want to enable it they
> > should know what value of timeout was before auto-adjust was disabled. I
> > think "negative value" pattern good choice for always usable parameters
> > like timeout of connection (ex. -1 equal to endless waiting) and so on,
> but
> > in our case we want to disable whole functionality rather than change
> > parameter value.
> >
> > --
> > Best regards,
> > Anton Kalashnikov
> >
> >
> > 24.01.2019, 22:03, "Vladimir Ozerov" :
> > > Hi Anton,
> > >
> > > This is great feature, but I am a bit confused about automatic
> disabling
> > of
> > > a feature during manual baseline adjustment. This may lead to
> unpleasant
> > > situations when a user enabled auto-adjustment, then re-adjusted it
> > > manually somehow (e.g. from some previously created script) so that
> > > auto-adjustment disabling went unnoticed, then added more nodes hoping
> > that
> > > auto-baseline is still active, etc.
> > >
> > > Instead, I would rather make manual and auto adjustment mutually
> > exclusive
> > > - baseline cannot be adjusted manually when auto mode is set, and vice
> > > versa. If exception is thrown in that cases, administrators will always
> > > know current behavior of the system.
> > >
> > > As far as configuration, wouldn’t it be enough to have a single long
> > value
> > > as opposed to Boolean + long? Say, 0 - immediate auto adjustment,
> > negative
> > > - disabled, positive - auto adjustment after timeout.
> > >
> > > Thoughts?
> > >
> > > чт, 24 янв. 2019 г. в 18:33, Anton Kalashnikov :
> > >
> > >>  Hello, Igniters!
> > >>
> > >>  Work on the Phase II of IEP-4 (Baseline topology) [1] has started. I
> > want
> > >>  to start to discuss of implementation of "Baseline auto-adjust" [2].
> > >>
> > >>  "Baseline auto-adjust" feature implements mechanism of auto-adjust
> > >>  baseline corresponding to current topology after event join/left was
> > >>  appeared. It is required because when a node left the grid and nobody
> > would
> > >>  change baseline manually it can lead to lost data(when some more
> nodes
> > left
> > >>  the grid on depends in backup factor) but permanent tracking of grid
> > is not
> > >>  always possible/desirible. Looks like in many cases auto-adjust
> > baseline
> > >>  after some timeout is very helpfull.
> > >>
> > >>  Distributed metastore[3](it is already done):
> > >>
> > >>  First of all it is required the ability to store configuration data
> > >>  consistently and cluster-wide. Ignite doesn't have any specific API
> for
> > >>  such configurations and we don't want to have many similar
> > implementations
> > >>  of the same feature in our code. After some thoughts is was proposed
> to
> > >>  implement it as some kind of distributed metastorage that gives the
> > ability
> > >>  to store any data in it.
> > >>  First implementation is based on existing local metastorage API for
> > >>  persistent clusters (in-memory clusters will store data in memory).
> > >>  Write/remove operation use Discovery SPI to send updates to the
> > cluster, it
> > >>  guarantees updates order and the fact that all existing (alive) nodes
> > have
> > >>  handled the update message. As a way to find out which node has the
> > latest
> > >>  data there is a "version" value of distributed metastorage, which is
> > >>  basically . All updates
> history
> > >>  until some point in the past is stored along with the data, so when
> an
> > >>  outdated node connects to the cluster it will receive all the missing
> > data
> > >>  and apply it locally. If there's not enough history stored or joining
> > node
> > >>  is clear then it'll receive shapshot of distributed metastorage so
> > there
> > >>  won't be inconsistencies.
> > >>
> > >>  Baseline auto-adjust:
> > >>
> > >>  Main scenario:
> > >>  - There is grid with the baseline i

[jira] [Created] (IGNITE-11087) GridJobCheckpointCleanupSelfTest.testCheckpointCleanup is flaky

2019-01-25 Thread Nikolai Kulagin (JIRA)
Nikolai Kulagin created IGNITE-11087:


 Summary: GridJobCheckpointCleanupSelfTest.testCheckpointCleanup is 
flaky
 Key: IGNITE-11087
 URL: https://issues.apache.org/jira/browse/IGNITE-11087
 Project: Ignite
  Issue Type: Bug
Reporter: Nikolai Kulagin
Assignee: Nikolai Kulagin
 Fix For: 2.8
 Attachments: #removeCheckpoint isn't called.txt, #removeCheckpointis 
called once more.txt

The method of remove a checkpoint is sometimes not called or is called once 
more. Test has a very low fail rate, 0 per 360 runs on TC and 1 per 412 on TC 
Bot. On local machine approximately 1 failure per 100 runs. Logs in the 
attachment.

Test is flaky for a long time. Before replacing IP Finder in IGNITE-10555, test 
was slower, which made fail rate even less.

 
{code:java}
[2019-01-25 14:49:03,050][ERROR][main][root] Test failed.
junit.framework.AssertionFailedError: expected:<1> but was:<0>
at junit.framework.Assert.fail(Assert.java:57)
at junit.framework.Assert.failNotEquals(Assert.java:329)
at junit.framework.Assert.assertEquals(Assert.java:78)
at junit.framework.Assert.assertEquals(Assert.java:234)
at junit.framework.Assert.assertEquals(Assert.java:241)
at 
org.apache.ignite.internal.GridJobCheckpointCleanupSelfTest.testCheckpointCleanup(GridJobCheckpointCleanupSelfTest.java:88)
at sun.reflect.GeneratedMethodAccessor22.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.apache.ignite.testframework.junits.GridAbstractTest$6.run(GridAbstractTest.java:2088)
at java.lang.Thread.run(Thread.java:748){code}
 

[^#removeCheckpoint isn't called.txt]

^_^

 
{code:java}
[2019-01-25 14:50:03,282][ERROR][main][root] Test failed.
junit.framework.AssertionFailedError: expected:<-1> but was:<0>
 at junit.framework.Assert.fail(Assert.java:57)
 at junit.framework.Assert.failNotEquals(Assert.java:329)
 at junit.framework.Assert.assertEquals(Assert.java:78)
 at junit.framework.Assert.assertEquals(Assert.java:234)
 at junit.framework.Assert.assertEquals(Assert.java:241)
 at 
org.apache.ignite.internal.GridJobCheckpointCleanupSelfTest.testCheckpointCleanup(GridJobCheckpointCleanupSelfTest.java:88)
 at sun.reflect.GeneratedMethodAccessor22.invoke(Unknown Source)
 at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.lang.reflect.Method.invoke(Method.java:498)
 at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
 at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
 at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
 at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
 at 
org.apache.ignite.testframework.junits.GridAbstractTest$6.run(GridAbstractTest.java:2088)
 at java.lang.Thread.run(Thread.java:748){code}
[^#removeCheckpointis called once more.txt]



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11088) Flacky LocalWalModeChangeDuringRebalancingSelfTest.testWithExchangesMerge

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11088:
-

 Summary: Flacky 
LocalWalModeChangeDuringRebalancingSelfTest.testWithExchangesMerge
 Key: IGNITE-11088
 URL: https://issues.apache.org/jira/browse/IGNITE-11088
 Project: Ignite
  Issue Type: Test
  Components: mvcc
Reporter: Andrew Mashenkov


[LocalWalModeChangeDuringRebalancingSelfTest.testWithExchangesMerge|https://ci.ignite.apache.org/viewLog.html?buildId=2895774&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_MvccPds2#testNameId-6585115376754732686]
 fails sporadicatlly in MvccPds 2 suite.

I've found no failures in non-mvcc Pds 2 suite, so, probably it is mvcc issue.

See stacktraces from 2 failures that may have same reason. We have to 
investigate this.
{noformat}
java.lang.AssertionError: nodeIdx=2, key=6606 expected:<13212> but was:
at org.junit.Assert.fail(Assert.java:88)
at org.junit.Assert.failNotEquals(Assert.java:743)
at org.junit.Assert.assertEquals(Assert.java:118)
at 
org.apache.ignite.internal.processors.cache.persistence.LocalWalModeChangeDuringRebalancingSelfTest.testWithExchangesMerge(LocalWalModeChangeDuringRebalancingSelfTest.java:473)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at 
org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at 
org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at 
org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at 
org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at 
org.apache.ignite.testframework.junits.GridAbstractTest$6.run(GridAbstractTest.java:2088)
at java.lang.Thread.run(Thread.java:748) {noformat}
{noformat}
[2019-01-23 
11:26:25,287][ERROR][sys-stripe-5-#6186%persistence.LocalWalModeChangeDuringRebalancingSelfTest3%][GridDhtColocatedCache]
  Failed processing get request: GridNearSingleGetRequest 
[futId=1548243502606, key=KeyCacheObjectImpl [part=381, val=7037, 
hasValBytes=true], flags=1, topVer=AffinityTopologyVersion [topVer=8, 
minorTopVer=1], subjId=f1fbb371-3232-4bfa-a20a-d4cad4b2, taskNameHash=0, 
createTtl=-1, accessTtl=-1, txLbl=null, mvccSnapshot=MvccSnapshotResponse 
[futId=7040, crdVer=1548242747966, cntr=20023, opCntr=1073741823, txs=null, 
cleanupVer=0, tracking=0]] class org.apache.ignite.IgniteCheckedException: 
Runtime failure on bounds: [lower=MvccSnapshotSearchRow [res=null, 
snapshot=MvccSnapshotResponse [futId=7040, crdVer=1548242747966, cntr=20023, 
opCntr=1073741823, txs=null, cleanupVer=0, tracking=0]], upper=MvccMinSearchRow 
[]] at 
org.apache.ignite.internal.processors.cache.persistence.tree.BPlusTree.iterate(BPlusTree.java:1043)
 at 
org.apache.ignite.internal.processors.cache.IgniteCacheOffheapManagerImpl$CacheDataStoreImpl.mvccFind(IgniteCacheOffheapManagerImpl.java:2683)
 at 
org.apache.ignite.internal.processors.cache.persistence.GridCacheOffheapManager$GridCacheDataStore.mvccFind(GridCacheOffheapManager.java:2141)
 at 
org.apache.ignite.internal.processors.cache.IgniteCacheOffheapManagerImpl.mvccRead(IgniteCacheOffheapManagerImpl.java:666)
 at 
org.apache.ignite.internal.processors.cache.GridCacheAdapter.getAllAsync0(GridCacheAdapter.java:2023)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter.getDhtAllAsync(GridDhtCacheAdapter.java:807)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtGetSingleFuture.getAsync(GridDhtGetSingleFuture.java:399)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtGetSingleFuture.map0(GridDhtGetSingleFuture.java:277)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtGetSingleFuture.map(GridDhtGetSingleFuture.java:259)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtGetSingleFuture.init(GridDhtGetSingleFuture.java:182)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter.getDhtSingleAsync(GridDhtCacheAdapter.java:918)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter.processNearSingleGetRequest(GridDhtCacheAdapter.java:933)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtTransactionalCacheAdapter$2.apply(GridDhtTransactionalCacheAdapter.java:152)
 at 
org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtTransactionalCacheAdapter$2.apply(GridDhtTransactionalCacheAdapter.java:150)
 at 
org.apache.ignite.internal.processors.cache.GridCacheIoManager.processMessage(GridCacheIoManager.java:1125)
 at 
org.apache.ign

[jira] [Created] (IGNITE-11090) Test IgniteRebalanceOnCachesStoppingOrDestroyingTest.testDestroySpecificCacheAndCacheGroupFirstGroup hangs sporadically.

2019-01-25 Thread Andrew Mashenkov (JIRA)
Andrew Mashenkov created IGNITE-11090:
-

 Summary: Test 
IgniteRebalanceOnCachesStoppingOrDestroyingTest.testDestroySpecificCacheAndCacheGroupFirstGroup
 hangs sporadically.
 Key: IGNITE-11090
 URL: https://issues.apache.org/jira/browse/IGNITE-11090
 Project: Ignite
  Issue Type: Test
Reporter: Andrew Mashenkov


[IgniteRebalanceOnCachesStoppingOrDestroyingTest.testDestroySpecificCacheAndCacheGroupFirstGroup|https://ci.ignite.apache.org/viewLog.html?buildId=2863858&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_Pds4#testNameId7513268742645138398]
 fails sporadically on TC.
{noformat}
[2019-01-21 21:29:28,714][WARN 
][exchange-worker-#58898%rebalancing.IgniteRebalanceOnCachesStoppingOrDestroyingTest1%][diagnostic]
 Latch manager state: ExchangeLatchManager [serverLatches=ConcurrentHashMap {}, 
clientLatches=ConcurrentHashMap {}]
[21:29:29] (err) Failed to notify listener: 
o.a.i.i.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$2...@42d0164ejava.lang.AssertionError
at 
org.apache.ignite.internal.processors.cache.WalStateManager.onGroupRebalanceFinished(WalStateManager.java:492)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$2.applyx(GridDhtPartitionDemander.java:298)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$2.applyx(GridDhtPartitionDemander.java:295)
at 
org.apache.ignite.internal.util.lang.IgniteInClosureX.apply(IgniteInClosureX.java:38)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.notifyListener(GridFutureAdapter.java:399)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.unblock(GridFutureAdapter.java:347)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.unblockAll(GridFutureAdapter.java:335)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.onDone(GridFutureAdapter.java:511)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.onDone(GridFutureAdapter.java:490)
at 
org.apache.ignite.internal.util.future.GridFutureAdapter.onDone(GridFutureAdapter.java:467)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$RebalanceFuture.checkIsDone(GridDhtPartitionDemander.java:1281)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$RebalanceFuture.checkIsDone(GridDhtPartitionDemander.java:1242)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$RebalanceFuture.partitionDone(GridDhtPartitionDemander.java:1215)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander$RebalanceFuture.access$1100(GridDhtPartitionDemander.java:988)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionDemander.handleSupplyMessage(GridDhtPartitionDemander.java:803)
at 
org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPreloader.handleSupplyMessage(GridDhtPreloader.java:374)
at 
org.apache.ignite.internal.processors.cache.GridCachePartitionExchangeManager$5.apply(GridCachePartitionExchangeManager.java:426)
at 
org.apache.ignite.internal.processors.cache.GridCachePartitionExchangeManager$5.apply(GridCachePartitionExchangeManager.java:416)
at 
org.apache.ignite.internal.processors.cache.GridCacheIoManager.processMessage(GridCacheIoManager.java:1125)
at 
org.apache.ignite.internal.processors.cache.GridCacheIoManager.onMessage0(GridCacheIoManager.java:590)
at 
org.apache.ignite.internal.processors.cache.GridCacheIoManager.access$700(GridCacheIoManager.java:108)
at 
org.apache.ignite.internal.processors.cache.GridCacheIoManager$OrderedMessageListener.onMessage(GridCacheIoManager.java:1687)
at 
org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1561)
at 
org.apache.ignite.internal.managers.communication.GridIoManager.access$4100(GridIoManager.java:127)
at 
org.apache.ignite.internal.managers.communication.GridIoManager$GridCommunicationMessageSet.unwind(GridIoManager.java:2753)
at 
org.apache.ignite.internal.managers.communication.GridIoManager.unwindMessageSet(GridIoManager.java:1521)
at 
org.apache.ignite.internal.managers.communication.GridIoManager.access$4400(GridIoManager.java:127)
at 
org.apache.ignite.internal.managers.communication.GridIoManager$9.run(GridIoManager.java:1490)
at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748){noformat}
[TC 
run|h

[jira] [Created] (IGNITE-11089) Get rid of partition ID in intra-partition page links stored in delta records

2019-01-25 Thread Ivan Rakov (JIRA)
Ivan Rakov created IGNITE-11089:
---

 Summary: Get rid of partition ID in intra-partition page links 
stored in delta records
 Key: IGNITE-11089
 URL: https://issues.apache.org/jira/browse/IGNITE-11089
 Project: Ignite
  Issue Type: Improvement
Reporter: Ivan Rakov
 Fix For: 2.8


We had faced numerous bugs when pages that were initially allocated in 
partition X migrated to partition Y (example: IGNITE-8659). Such migration may 
cause storage corruption: in partition Y gets evicted, attempt to dereference 
link to migrated page will cause error.
We may prevent such situations in general and gain few percent performance 
boost at the same time:
1) Locate all links to pages in delta records, including self-links (examples: 
InitNewPageRecord#newPageId, PagesListSetNextRecord#nextPageId, 
MergeRecord#rightId).
2) Change storing format for such links: save only 6 bytes instead of 8 
(without partition ID).
3) In every delta record constructor, assert that link's partition ID is equal 
to PageDeltaRecord#pageId. Exception is pages from index partition: they may 
refer to pages from other partitions by design.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: Baseline auto-adjust`s discuss

2019-01-25 Thread Anton Kalashnikov
Initially, hard timeout should protect grid from constantly changing 
topology(constantly blinking node). But in fact if we have constantly changing 
topology, baseline adjust operation is failed in most cases. As result hard 
timeout only added complexity but it don't give any new guarantee. So I think 
we can skip it in first implementation.

First of all timeout protect us from unnecessary adjust of baseline . If node 
left the grid and immediately(or after some time less than us timeout) it join 
back to grid. Also timeout is helpful in other cases when some events happened 
one after another.

This feature doesn't have any complex heuristic to react, except of described 
in restrictions section.

Also I want to notes that this feature isn't protect us from constantly 
blinking node. We need one more heuristic mechanism for detect this situation 
and doing some actions like removing this node from grid.

-- 
Best regards,
Anton Kalashnikov


25.01.2019, 15:43, "Sergey Chugunov" :
> Anton,
>
> As I understand from the IEP document policy was supposed to support two
> timeouts: soft and hard, so here you're proposing a bit simpler
> functionality.
>
> Just to clarify, do I understand correctly that this feature when enabled
> will auto-adjust blt on each node join/node left event, and timeout is
> necessary to protect us from blinking nodes?
> So no complexities with taking into account number of alive backups or
> something like that?
>
> On Fri, Jan 25, 2019 at 1:11 PM Vladimir Ozerov 
> wrote:
>
>>  Got it, makes sense.
>>
>>  On Fri, Jan 25, 2019 at 11:06 AM Anton Kalashnikov 
>>  wrote:
>>
>>  > Vladimir, thanks for your notes, both of them looks good enough but I
>>  > have two different thoughts about it.
>>  >
>>  > I think I agree about enabling only one of manual/auto adjustment. It is
>>  > easier than current solution and in fact as extra feature we can allow
>>  > user to force task to execute(if they doesn't want to wait until timeout
>>  > expired).
>>  > But about second one I don't sure that one parameters instead of two
>>  would
>>  > be more convenient. For example: in case when user changed timeout and
>>  then
>>  > disable auto-adjust after then when someone will want to enable it they
>>  > should know what value of timeout was before auto-adjust was disabled. I
>>  > think "negative value" pattern good choice for always usable parameters
>>  > like timeout of connection (ex. -1 equal to endless waiting) and so on,
>>  but
>>  > in our case we want to disable whole functionality rather than change
>>  > parameter value.
>>  >
>>  > --
>>  > Best regards,
>>  > Anton Kalashnikov
>>  >
>>  >
>>  > 24.01.2019, 22:03, "Vladimir Ozerov" :
>>  > > Hi Anton,
>>  > >
>>  > > This is great feature, but I am a bit confused about automatic
>>  disabling
>>  > of
>>  > > a feature during manual baseline adjustment. This may lead to
>>  unpleasant
>>  > > situations when a user enabled auto-adjustment, then re-adjusted it
>>  > > manually somehow (e.g. from some previously created script) so that
>>  > > auto-adjustment disabling went unnoticed, then added more nodes hoping
>>  > that
>>  > > auto-baseline is still active, etc.
>>  > >
>>  > > Instead, I would rather make manual and auto adjustment mutually
>>  > exclusive
>>  > > - baseline cannot be adjusted manually when auto mode is set, and vice
>>  > > versa. If exception is thrown in that cases, administrators will always
>>  > > know current behavior of the system.
>>  > >
>>  > > As far as configuration, wouldn’t it be enough to have a single long
>>  > value
>>  > > as opposed to Boolean + long? Say, 0 - immediate auto adjustment,
>>  > negative
>>  > > - disabled, positive - auto adjustment after timeout.
>>  > >
>>  > > Thoughts?
>>  > >
>>  > > чт, 24 янв. 2019 г. в 18:33, Anton Kalashnikov :
>>  > >
>>  > >> Hello, Igniters!
>>  > >>
>>  > >> Work on the Phase II of IEP-4 (Baseline topology) [1] has started. I
>>  > want
>>  > >> to start to discuss of implementation of "Baseline auto-adjust" [2].
>>  > >>
>>  > >> "Baseline auto-adjust" feature implements mechanism of auto-adjust
>>  > >> baseline corresponding to current topology after event join/left was
>>  > >> appeared. It is required because when a node left the grid and nobody
>>  > would
>>  > >> change baseline manually it can lead to lost data(when some more
>>  nodes
>>  > left
>>  > >> the grid on depends in backup factor) but permanent tracking of grid
>>  > is not
>>  > >> always possible/desirible. Looks like in many cases auto-adjust
>>  > baseline
>>  > >> after some timeout is very helpfull.
>>  > >>
>>  > >> Distributed metastore[3](it is already done):
>>  > >>
>>  > >> First of all it is required the ability to store configuration data
>>  > >> consistently and cluster-wide. Ignite doesn't have any specific API
>>  for
>>  > >> such configurations and we don't want to have many similar
>>  > implementations
>>  > >> of the same feature in our code. After som

Re: Distributed MetaStorage discussion

2019-01-25 Thread Vladimir Ozerov
Ivan,

The change you describe is extremely valuable thing as it allows to detect
changes into global configuration which is of great importance for SQL.
Will topology and affinity changes be reflected in metastore history as
well? From SQL perspective it is important for us to be able to understand
whether cluster topology, data distribution or SQL schema has changed
between two versions. Is it possible to have a kind of composite version
instead of hashed counter? E.g.

class ConfigurationVersion {
long globalVer; // Global counter
long topVer; // Increasing topology version
long affVer; // Increasing affinity version which is incremented every
time data distribution is changed (node join/leave, baseline changes, late
affinity assignment)
long sqlSchemaVer; // Incremented every time SQL schema changes
}

Vladimir.


On Fri, Jan 25, 2019 at 11:45 AM Ivan Bessonov 
wrote:

> Hello, Igniters!
>
> Here's more info "Distributed MetaStorage" feature [1]. It is a part of
> Phase II for
> IEP-4 (Baseline topology) [2] and was mentioned in recent "Baseline
> auto-adjust`s
> discuss" topic. I'll partially duplicate that message here.
>
> One of key requirements is the ability to store configuration data (or any
> other data)
> consistently and cluster-wide. There are also other tickets that require
> similar
> mechanisms, for example [3]. Ignite doesn't have any specific API for such
> configurations and we don't want to have many similar implementations of
> the
> same feature across the code.
>
> There are several API methods required for the feature:
>
>  - read(key) / iterate(keyPrefix) - access to the distributed data. Should
> be
>consistent for all nodes in cluster when it's in active state.
>  - write / remove - modify data in distributed metastorage. Should
> guarantee that
>every node in cluster will have this update after the method is
> finished.
>  - writeAsync / removeAsync (not yet implemented) - same as above, but
> async.
>Might be useful if one needs to update several values one after another.
>  - compareAndWrite / compareAndRemove - helpful to reduce number of data
>updates (more on that later).
>  - listen(keyPredicate) - a way of being notified when some data was
> changed.
>Normally it is triggered on "write/remove" operation or node activation.
> Listener
>itself will be notified with .
>
> Now some implementation details:
>
> First implementation is based on existing local metastorage API for
> persistent
> clusters (in-memory clusters will store data in memory). Write/remove
> operation
> use Discovery SPI to send updates to the cluster, it guarantees updates
> order
> and the fact that all existing (alive) nodes have handled the update
> message.
>
> As a way to find out which node has the latest data there is a "version"
> value of
> distributed metastorage, which is basically  all
> updates>. Whole updates history until some point in the past is stored
> along with
> the data, so when an outdated node connects to the cluster it will receive
> all the
> missing data and apply it locally. Listeners will also be invoked after
> such updates.
> If there's not enough history stored or joining node is clear then it'll
> receive
> shapshot of distributed metastorage so there won't be inconsistencies.
> "compareAndWrite" / "compareAndRemove" API might help reducing the size of
> the history, especially for Boolean or other primitive values.
>
> There are, of course, many more details, feel free to ask about them. First
> implementation is in master, but there are already known improvements that
> can
> be done and I'm working on them right now.
>
> See package "org.apache.ignite.internal.processors.metastorage" for the new
> interfaces and comment your opinion or questions. Thank you!
>
> [1] https://issues.apache.org/jira/browse/IGNITE-10640
> [2]
>
> https://cwiki.apache.org/confluence/display/IGNITE/IEP-4+Baseline+topology+for+caches
> [3] https://issues.apache.org/jira/browse/IGNITE-8717
>
> --
> Sincerely yours,
> Ivan Bessonov
>


[jira] [Created] (IGNITE-11091) Visor shows all indexes in upper case

2019-01-25 Thread Igor Akkuratov (JIRA)
Igor Akkuratov created IGNITE-11091:
---

 Summary: Visor shows all indexes in upper case
 Key: IGNITE-11091
 URL: https://issues.apache.org/jira/browse/IGNITE-11091
 Project: Ignite
  Issue Type: Task
  Components: cache
Affects Versions: 2.7, 2.6, 2.5
Reporter: Igor Akkuratov
Assignee: Igor Akkuratov






--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: Distributed MetaStorage discussion

2019-01-25 Thread Ivan Bessonov
Vladimir,

thank you for the reply. Topology and affinity changes are not reflected in
distributed metastorage, we didn't touch baseline history at all. I believe
that what you really need it just distributed property "sqlSchemaVer" that
is updated on each schema update. It could be achieved by creating
corresponding key in distributed metastorage without any specific treatment
from the API standpoint.

Same thing applies to topology and affinity versions, but motivation here
is not that clear for me to be honest.

I think that the most common approach with single incrementing version
is much simpler then several counters and I would prefer to leave it that
way.


пт, 25 янв. 2019 г. в 16:39, Vladimir Ozerov :

> Ivan,
>
> The change you describe is extremely valuable thing as it allows to detect
> changes into global configuration which is of great importance for SQL.
> Will topology and affinity changes be reflected in metastore history as
> well? From SQL perspective it is important for us to be able to understand
> whether cluster topology, data distribution or SQL schema has changed
> between two versions. Is it possible to have a kind of composite version
> instead of hashed counter? E.g.
>
> class ConfigurationVersion {
> long globalVer; // Global counter
> long topVer; // Increasing topology version
> long affVer; // Increasing affinity version which is incremented every
> time data distribution is changed (node join/leave, baseline changes, late
> affinity assignment)
> long sqlSchemaVer; // Incremented every time SQL schema changes
> }
>
> Vladimir.
>
>
> On Fri, Jan 25, 2019 at 11:45 AM Ivan Bessonov 
> wrote:
>
> > Hello, Igniters!
> >
> > Here's more info "Distributed MetaStorage" feature [1]. It is a part of
> > Phase II for
> > IEP-4 (Baseline topology) [2] and was mentioned in recent "Baseline
> > auto-adjust`s
> > discuss" topic. I'll partially duplicate that message here.
> >
> > One of key requirements is the ability to store configuration data (or
> any
> > other data)
> > consistently and cluster-wide. There are also other tickets that require
> > similar
> > mechanisms, for example [3]. Ignite doesn't have any specific API for
> such
> > configurations and we don't want to have many similar implementations of
> > the
> > same feature across the code.
> >
> > There are several API methods required for the feature:
> >
> >  - read(key) / iterate(keyPrefix) - access to the distributed data.
> Should
> > be
> >consistent for all nodes in cluster when it's in active state.
> >  - write / remove - modify data in distributed metastorage. Should
> > guarantee that
> >every node in cluster will have this update after the method is
> > finished.
> >  - writeAsync / removeAsync (not yet implemented) - same as above, but
> > async.
> >Might be useful if one needs to update several values one after
> another.
> >  - compareAndWrite / compareAndRemove - helpful to reduce number of data
> >updates (more on that later).
> >  - listen(keyPredicate) - a way of being notified when some data was
> > changed.
> >Normally it is triggered on "write/remove" operation or node
> activation.
> > Listener
> >itself will be notified with .
> >
> > Now some implementation details:
> >
> > First implementation is based on existing local metastorage API for
> > persistent
> > clusters (in-memory clusters will store data in memory). Write/remove
> > operation
> > use Discovery SPI to send updates to the cluster, it guarantees updates
> > order
> > and the fact that all existing (alive) nodes have handled the update
> > message.
> >
> > As a way to find out which node has the latest data there is a "version"
> > value of
> > distributed metastorage, which is basically  of
> > all
> > updates>. Whole updates history until some point in the past is stored
> > along with
> > the data, so when an outdated node connects to the cluster it will
> receive
> > all the
> > missing data and apply it locally. Listeners will also be invoked after
> > such updates.
> > If there's not enough history stored or joining node is clear then it'll
> > receive
> > shapshot of distributed metastorage so there won't be inconsistencies.
> > "compareAndWrite" / "compareAndRemove" API might help reducing the size
> of
> > the history, especially for Boolean or other primitive values.
> >
> > There are, of course, many more details, feel free to ask about them.
> First
> > implementation is in master, but there are already known improvements
> that
> > can
> > be done and I'm working on them right now.
> >
> > See package "org.apache.ignite.internal.processors.metastorage" for the
> new
> > interfaces and comment your opinion or questions. Thank you!
> >
> > [1] https://issues.apache.org/jira/browse/IGNITE-10640
> > [2]
> >
> >
> https://cwiki.apache.org/confluence/display/IGNITE/IEP-4+Baseline+topology+for+caches
> > [3] https://issues.apache.org/jira/browse/IGNITE-8717
> >
> > --
> > Sincerely yours,
> >

Re: Distributed MetaStorage discussion

2019-01-25 Thread Vladimir Ozerov
Ivan,

The idea is that certain changes to the system are not relevant for all
components. E.g. if SQL schema is changed, then some SQL caches needs to be
invalidated. When affinity topology changes, another part of caches needs
to be invalidated. Having a single version may lead to unexpected latency
spikes and invalidations in this case.

On Fri, Jan 25, 2019 at 4:50 PM Ivan Bessonov  wrote:

> Vladimir,
>
> thank you for the reply. Topology and affinity changes are not reflected in
> distributed metastorage, we didn't touch baseline history at all. I believe
> that what you really need it just distributed property "sqlSchemaVer" that
> is updated on each schema update. It could be achieved by creating
> corresponding key in distributed metastorage without any specific treatment
> from the API standpoint.
>
> Same thing applies to topology and affinity versions, but motivation here
> is not that clear for me to be honest.
>
> I think that the most common approach with single incrementing version
> is much simpler then several counters and I would prefer to leave it that
> way.
>
>
> пт, 25 янв. 2019 г. в 16:39, Vladimir Ozerov :
>
> > Ivan,
> >
> > The change you describe is extremely valuable thing as it allows to
> detect
> > changes into global configuration which is of great importance for SQL.
> > Will topology and affinity changes be reflected in metastore history as
> > well? From SQL perspective it is important for us to be able to
> understand
> > whether cluster topology, data distribution or SQL schema has changed
> > between two versions. Is it possible to have a kind of composite version
> > instead of hashed counter? E.g.
> >
> > class ConfigurationVersion {
> > long globalVer; // Global counter
> > long topVer; // Increasing topology version
> > long affVer; // Increasing affinity version which is incremented
> every
> > time data distribution is changed (node join/leave, baseline changes,
> late
> > affinity assignment)
> > long sqlSchemaVer; // Incremented every time SQL schema changes
> > }
> >
> > Vladimir.
> >
> >
> > On Fri, Jan 25, 2019 at 11:45 AM Ivan Bessonov 
> > wrote:
> >
> > > Hello, Igniters!
> > >
> > > Here's more info "Distributed MetaStorage" feature [1]. It is a part of
> > > Phase II for
> > > IEP-4 (Baseline topology) [2] and was mentioned in recent "Baseline
> > > auto-adjust`s
> > > discuss" topic. I'll partially duplicate that message here.
> > >
> > > One of key requirements is the ability to store configuration data (or
> > any
> > > other data)
> > > consistently and cluster-wide. There are also other tickets that
> require
> > > similar
> > > mechanisms, for example [3]. Ignite doesn't have any specific API for
> > such
> > > configurations and we don't want to have many similar implementations
> of
> > > the
> > > same feature across the code.
> > >
> > > There are several API methods required for the feature:
> > >
> > >  - read(key) / iterate(keyPrefix) - access to the distributed data.
> > Should
> > > be
> > >consistent for all nodes in cluster when it's in active state.
> > >  - write / remove - modify data in distributed metastorage. Should
> > > guarantee that
> > >every node in cluster will have this update after the method is
> > > finished.
> > >  - writeAsync / removeAsync (not yet implemented) - same as above, but
> > > async.
> > >Might be useful if one needs to update several values one after
> > another.
> > >  - compareAndWrite / compareAndRemove - helpful to reduce number of
> data
> > >updates (more on that later).
> > >  - listen(keyPredicate) - a way of being notified when some data was
> > > changed.
> > >Normally it is triggered on "write/remove" operation or node
> > activation.
> > > Listener
> > >itself will be notified with .
> > >
> > > Now some implementation details:
> > >
> > > First implementation is based on existing local metastorage API for
> > > persistent
> > > clusters (in-memory clusters will store data in memory). Write/remove
> > > operation
> > > use Discovery SPI to send updates to the cluster, it guarantees updates
> > > order
> > > and the fact that all existing (alive) nodes have handled the update
> > > message.
> > >
> > > As a way to find out which node has the latest data there is a
> "version"
> > > value of
> > > distributed metastorage, which is basically  hash
> > of
> > > all
> > > updates>. Whole updates history until some point in the past is stored
> > > along with
> > > the data, so when an outdated node connects to the cluster it will
> > receive
> > > all the
> > > missing data and apply it locally. Listeners will also be invoked after
> > > such updates.
> > > If there's not enough history stored or joining node is clear then
> it'll
> > > receive
> > > shapshot of distributed metastorage so there won't be inconsistencies.
> > > "compareAndWrite" / "compareAndRemove" API might help reducing the size
> > of
> > > the history, especially for Boolean or other prim

[jira] [Created] (IGNITE-11092) CacheInterceptor add callbacks for binary objects

2019-01-25 Thread Sergey Antonov (JIRA)
Sergey Antonov created IGNITE-11092:
---

 Summary: CacheInterceptor add callbacks for binary objects
 Key: IGNITE-11092
 URL: https://issues.apache.org/jira/browse/IGNITE-11092
 Project: Ignite
  Issue Type: Improvement
  Components: cache
Reporter: Sergey Antonov
 Fix For: 3.0


Current API of cache interceptor difficult for use. You should implements 
interface with Object, Object class parameters and use {{if (o instance of 
BinaryObject)}} in each method, if you work with cache in both modes: binary 
and object.
Possible names of new methods:
* onBinaryGet()
* onBeforeBinaryUpdate()/onAfterBinaryUpdate()
* onBeforeBinaryRemove()/onAfterBinaryRemove()



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


Re: [MTCGA]: new failures in builds [2867589] needs to be handled

2019-01-25 Thread Dmitriy Pavlov
It seems to be passing now. Please ignore.

ср, 23 янв. 2019 г. в 00:03, :

> Hi Igniters,
>
>  I've detected some new issue on TeamCity to be handled. You are more than
> welcomed to help.
>
>  If your changes can lead to this failure(s): We're grateful that you were
> a volunteer to make the contribution to this project, but things change and
> you may no longer be able to finalize your contribution.
>  Could you respond to this email and indicate if you wish to continue and
> fix test failures or step down and some committer may revert you commit.
>
>  *New stable failure of a flaky test in master IgniteCoreTest:
> CacheQueryTestSuite: TestFieldsQueryPagesSeveral
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=-4145688911096802577&branch=%3Cdefault%3E&tab=testDetails
>
>  *New stable failure of a flaky test in master IgniteCoreTest:
> CacheQueryTestSuite: TestFieldsQuerySeveral
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=7923965190700916819&branch=%3Cdefault%3E&tab=testDetails
>  Changes may lead to failure were done by
>  - sergi.vladykin
> https://ci.ignite.apache.org/viewModification.html?modId=872823
>
>  - Here's a reminder of what contributors were agreed to do
> https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute
>  - Should you have any questions please contact
> dev@ignite.apache.org
>
> Best Regards,
> Apache Ignite TeamCity Bot
> https://github.com/apache/ignite-teamcity-bot
> Notification generated at 00:02:54 23-01-2019
>


Re: [MTCGA]: new failures in builds [2867594, 2639452] needs to be handled

2019-01-25 Thread Dmitriy Pavlov
Passing now, please ignore

вт, 22 янв. 2019 г. в 23:33, :

> Hi Igniters,
>
>  I've detected some new issue on TeamCity to be handled. You are more than
> welcomed to help.
>
>  If your changes can lead to this failure(s): We're grateful that you were
> a volunteer to make the contribution to this project, but things change and
> you may no longer be able to finalize your contribution.
>  Could you respond to this email and indicate if you wish to continue and
> fix test failures or step down and some committer may revert you commit.
>
>  *New stable failure of a flaky test in master IgniteCoreTest:
> CacheQueryTestSuite: TestFieldsQueryPagesSeveral
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=-4145688911096802577&branch=%3Cdefault%3E&tab=testDetails
>
>  *New stable failure of a flaky test in master IgniteCoreTest:
> CacheQueryTestSuite: TestFieldsQuerySeveral
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=7923965190700916819&branch=%3Cdefault%3E&tab=testDetails
>  Changes may lead to failure were done by
>  - sergi.vladykin
> https://ci.ignite.apache.org/viewModification.html?modId=872823
>
>  *New stable failure of a flaky test in master
> IgniteStartStopTest.TestProcessorInit
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=-8379686487933741046&branch=%3Cdefault%3E&tab=testDetails
>  No changes in the build
>
>  - Here's a reminder of what contributors were agreed to do
> https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute
>  - Should you have any questions please contact
> dev@ignite.apache.org
>
> Best Regards,
> Apache Ignite TeamCity Bot
> https://github.com/apache/ignite-teamcity-bot
> Notification generated at 23:32:51 22-01-2019
>


Re: [MTCGA]: new failures in builds [2807830] needs to be handled

2019-01-25 Thread Dmitriy Pavlov
The test is still flaky and it seems to begin failing recently. Is there
any issue for this test fix?

вт, 22 янв. 2019 г. в 22:49, :

> Hi Igniters,
>
>  I've detected some new issue on TeamCity to be handled. You are more than
> welcomed to help.
>
>  If your changes can lead to this failure(s): We're grateful that you were
> a volunteer to make the contribution to this project, but things change and
> you may no longer be able to finalize your contribution.
>  Could you respond to this email and indicate if you wish to continue and
> fix test failures or step down and some committer may revert you commit.
>
>  *New stable failure of a flaky test in master
> PartitionLossTest.TestReadOnlyAll
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=5428922878479275743&branch=%3Cdefault%3E&tab=testDetails
>  Changes may lead to failure were done by
>  - amalykhgh
> https://ci.ignite.apache.org/viewModification.html?modId=872152
>
>  - Here's a reminder of what contributors were agreed to do
> https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute
>  - Should you have any questions please contact
> dev@ignite.apache.org
>
> Best Regards,
> Apache Ignite TeamCity Bot
> https://github.com/apache/ignite-teamcity-bot
> Notification generated at 22:32:50 22-01-2019
>


Re: [MTCGA]: new failures in builds [2658036] needs to be handled

2019-01-25 Thread Dmitriy Pavlov
Who can advice if mentioned tests change their name from time to time?

The bot will not notify for such tests correctly because it is impossible
to say if a test is the same with some passing test(s).

чт, 24 янв. 2019 г. в 22:17, :

> Hi Igniters,
>
>  I've detected some new issue on TeamCity to be handled. You are more than
> welcomed to help.
>
>  If your changes can lead to this failure(s): We're grateful that you were
> a volunteer to make the contribution to this project, but things change and
> you may no longer be able to finalize your contribution.
>  Could you respond to this email and indicate if you wish to continue and
> fix test failures or step down and some committer may revert you commit.
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheGetWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=-2711660524736740778&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCachePutWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=-7419076455473690169&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheClearKeyWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=1014161704039071695&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheClearKeysWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=6066988179553985738&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheGetSizeWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=8039044665871263128&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testContainsKeyWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=8278104022332781338&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheReplaceWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=2601421891678519225&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheGetAndPutIfAbsentWrongArgs
>
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=6918523075100081828&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheContainsKeysWrongArgs
>
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=8508115998050634179&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheGetAllWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=8010201874973788100&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testRemoveIfEqualsWrongArgs
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=5613882862418653296&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheReplaceIfEqualsWrongArgs
>
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=7510292952369692624&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in master tests:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase:
> Apache\Ignite\Tests\CacheKeyValueOpsTestCase::testCacheGetAndRemoveWrongArgs
>
> https://ci.ignite.apache.org/project.html?projectId=IgniteTests24Java8&testNameId=6767768552589233912&branch=%3Cdefault%3E&tab=testDetails
>
>  *Recently contributed test failed in maste

[jira] [Created] (IGNITE-11093) Introduce transaction state change tracking framework

2019-01-25 Thread Ivan Rakov (JIRA)
Ivan Rakov created IGNITE-11093:
---

 Summary: Introduce transaction state change tracking framework
 Key: IGNITE-11093
 URL: https://issues.apache.org/jira/browse/IGNITE-11093
 Project: Ignite
  Issue Type: Improvement
Reporter: Ivan Rakov


This ticket covers creation of a framework that would allow to track current 
state of active transactions. When it's enabled, transactions code will notify 
framework on every crucial state change of active transaction (prepare phase 
done, commit phase done, rollback). In turn, framework should:
1) Provide list of currently prepared transactions
2) Upon request, start tracking of all prepared transactions and provide list 
of all transactions that were prepared since that
3) Upon request, start tracking of all commited transactions and provide list 
of all transactions that were committed since that
4) Provide a future that will be completed when all prepared transactions will 
be committed
As a possible use case, such framework will allow to perform WAL shipping and 
establish transactional consistency externally.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


edit access to Apache Ignite wiki

2019-01-25 Thread oignatenko
Hello,

Is it possible to get edit access to Apache Ignite wiki?

I've been working on particular JIRA ticket [1] and one of reviewers
suggested me update particular wiki page [2] after the ticket is done.

Now that the ticket is done I would like to make proposed edits to wiki
page.

TIA,
regards, Oleg

[1]: https://issues.apache.org/jira/browse/IGNITE-10178
[2]: https://cwiki.apache.org/confluence/display/IGNITE/Coding+Guidelines



--
Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/


Re: edit access to Apache Ignite wiki

2019-01-25 Thread Dmitriy Pavlov
Done, I've added permission for Oleg Ignatenko user.

Just in case, let me share
https://cwiki.apache.org/confluence/display/IGNITE/How+to+Document with you
:)

пт, 25 янв. 2019 г. в 20:55, oignatenko :

> Hello,
>
> Is it possible to get edit access to Apache Ignite wiki?
>
> I've been working on particular JIRA ticket [1] and one of reviewers
> suggested me update particular wiki page [2] after the ticket is done.
>
> Now that the ticket is done I would like to make proposed edits to wiki
> page.
>
> TIA,
> regards, Oleg
>
> [1]: https://issues.apache.org/jira/browse/IGNITE-10178
> [2]: https://cwiki.apache.org/confluence/display/IGNITE/Coding+Guidelines
>
>
>
> --
> Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
>


Re: edit access to Apache Ignite wiki

2019-01-25 Thread oignatenko
Thank you Dmitriy!

I updated the wiki.

regards, Oleg

PS. Also thanks for the reference to "How To document" guidelines, that's a
useful read.


Dmitriy Pavlov-3 wrote
> Done, I've added permission for Oleg Ignatenko user.
> 
> Just in case, let me share
> https://cwiki.apache.org/confluence/display/IGNITE/How+to+Document with
> you
> :)
> 
> пт, 25 янв. 2019 г. в 20:55, oignatenko <

> oignatenko@

> >:
> 
>> Hello,
>>
>> Is it possible to get edit access to Apache Ignite wiki?
>>
>> I've been working on particular JIRA ticket [1] and one of reviewers
>> suggested me update particular wiki page [2] after the ticket is done.
>>
>> Now that the ticket is done I would like to make proposed edits to wiki
>> page.
>>
>> TIA,
>> regards, Oleg
>>
>> [1]: https://issues.apache.org/jira/browse/IGNITE-10178
>> [2]: https://cwiki.apache.org/confluence/display/IGNITE/Coding+Guidelines
>>
>>
>>
>> --
>> Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
>>





--
Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/


[jira] [Created] (IGNITE-11094) Add SSL support for ignite zookeeper SPI

2019-01-25 Thread Sergey Kozlov (JIRA)
Sergey Kozlov created IGNITE-11094:
--

 Summary: Add SSL support for ignite zookeeper SPI
 Key: IGNITE-11094
 URL: https://issues.apache.org/jira/browse/IGNITE-11094
 Project: Ignite
  Issue Type: Improvement
Affects Versions: 2.7
Reporter: Sergey Kozlov
 Fix For: 2.8


ZK 3.5.4-beta is already supporting SSL. We should add SSL support to ZK server 
connections  if Zookeeper SPI used



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11095) Failed WalCompactionTest flaky test

2019-01-25 Thread Dmitriy Govorukhin (JIRA)
Dmitriy Govorukhin created IGNITE-11095:
---

 Summary: Failed WalCompactionTest flaky test
 Key: IGNITE-11095
 URL: https://issues.apache.org/jira/browse/IGNITE-11095
 Project: Ignite
  Issue Type: Bug
Reporter: Dmitriy Govorukhin






--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (IGNITE-11096) Webagent: flag --disable-demo doesn't work

2019-01-25 Thread Evgenii Zhuravlev (JIRA)
Evgenii Zhuravlev created IGNITE-11096:
--

 Summary: Webagent: flag --disable-demo doesn't work
 Key: IGNITE-11096
 URL: https://issues.apache.org/jira/browse/IGNITE-11096
 Project: Ignite
  Issue Type: Bug
  Components: wizards
Affects Versions: 2.7
 Environment: After enabling this flag it's still possible to start demo
Reporter: Evgenii Zhuravlev






--
This message was sent by Atlassian JIRA
(v7.6.3#76005)