Hi Summer,

If you take a look to the CommitUpdateCommand class, you will notice no
Flag is in there.

// this is the toString for example

@Override
public String toString() {
  return super.toString() + ",optimize="+optimize
          +",openSearcher="+openSearcher
          +",waitSearcher="+waitSearcher
          +",expungeDeletes="+expungeDeletes
          +",softCommit="+softCommit
          +",prepareCommit="+prepareCommit
          +'}';
}


If you then access the UpdateCommand object, you find the flag :


public static int BUFFERING = 0x00000001;    // update command is
being buffered.
public static int REPLAY    = 0x00000002;    // update command is from
replaying a log.
public static int PEER_SYNC    = 0x00000004; // update command is a
missing update being provided by a peer.
public static int IGNORE_AUTOCOMMIT = 0x00000008; // this update
should not count toward triggering of autocommits.
public static int CLEAR_CACHES = 0x00000010; // clear caches
associated with the update log.  used when applying reordered DBQ
updates when doing an add.

So the flag =2 is actually saying that the update command is from
replaying a log ( which is what you would expect)


Cheers


2015-07-08 3:01 GMT+01:00 Summer Shire <shiresum...@gmail.com>:

>
> Hi,
>
> When I restart my solr core the log replay starts and just before it
> finishes I see the following commit
>
> start
> commit{flags=2,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false,prepareCommit=false}
>
> what does the “flags=2” param do ?
>
> when I try to send that param to the updateHandler manually solr does not
> like it
>
> curl http://localhost:6600/solr/main/update -H "Content-Type: text/xml"
> --data-binary '<commit  openSearcher="true" flags="2"
> waitSearcher="false"/>'
>
> <?xml version="1.0" encoding="UTF-8"?>
> <response>
> <lst name="responseHeader"><int name="status">400</int><int
> name="QTime">0</int></lst><lst name="error"><str name="msg">Unknown commit
> parameter 'flags'</str><int name="code">400</int></lst>
> </response>
>
> thanks,
> Summer




-- 
--------------------------

Benedetti Alessandro
Visiting card : http://about.me/alessandro_benedetti

"Tyger, tyger burning bright
In the forests of the night,
What immortal hand or eye
Could frame thy fearful symmetry?"

William Blake - Songs of Experience -1794 England

Reply via email to