-
Notifications
You must be signed in to change notification settings - Fork 25.2k
NullPointerExceptions when flushing an index #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
The exception on the server side is a bug (well, actually, nothing bad happened, but it should not be printed out). I agree regarding the ability to "wait" for an index to get instantiated on the nodes it can. It might be a flag on the create index, or another API (localhost:9200/test/_wait or something). One last question, I added the debug element to APIs that fail. I know, I have a whole lot of work at getting exception proper and all, but for now, do you think that by default, should it return the debug element, or just the message (9 out of 10 times, the message is enough)? |
"nothing bad happened"... hmm, my cluster would hang for ages - maybe it recovers in the end? i didn't wait. re debug element vs message - perhaps have a server startup flag? the debug messages are only really helpful to you, so to have them enabled by default would just give more crud to the user. but you want to be able to ask them for the debug output, so it should be easy to switch that on. |
Really, it got stuck? Strange, I will have a look at why it might happen. Have you tested it with the new version and it is fixed? I will add a flag that is called traceError that will print it. By default, I will turn it off. |
Here's an example of how it hangs (latest version):
Then, when I shutdown the servers, I get:
And...
|
can you give this a go again? I fixed some things relating to that and I think this will be fixed as well. |
Fixed ++ |
Closes #25. (cherry picked from commit 17d43f5)
Closes #25. (cherry picked from commit 8836775)
Closes #25. (cherry picked from commit c299ce4)
Latest Azure Java SDK is 0.4.6 when looking at http://search.maven.org/#browse%7C-589510877 Closes #25. (cherry picked from commit 89be7b4)
Today, we throw an overly-general IllegalArgumentException to reject unacceptable messages in the consensus layer. We expect messages to be rejected from time to time, if delayed or some other failure occurs, and it is not useful to log the full stack trace leading to these exceptions. This change introduces ConsensusMessageRejectedException for these cases, and suppresses overly verbose logging when receiving such a message. It does not include any of the extra machinery needed to pass these exceptions over the wire.
Removed dots at end of task descriptions to have a common scheme
* Updated following tests * Corrected config and updated following review
Hiya
I'm running a test suite against a local server, started as:
I'm getting NullPointerExceptions if I create an index, flush the indices, then delete the index, without sleeping after the flush. Shouldn't flush/refresh/optimize etc block until the action is complete?
Or is there some way of asking the cluster: are you ready now?
ta
clint
> ./bin/elasticsearch -f
[15:04:00,872][INFO ][server ] [Doe, John] {ElasticSearch/0.5.0/2010-02-18T13:42:47/dev}: Initializing ...
[15:04:02,663][INFO ][server ] [Doe, John] {ElasticSearch/0.5.0/2010-02-18T13:42:47/dev}: Initialized
[15:04:02,663][INFO ][server ] [Doe, John] {ElasticSearch/0.5.0/2010-02-18T13:42:47/dev}: Starting ...
[15:04:02,755][INFO ][transport ] [Doe, John] boundAddress [inet[/0.0.0.0:9300]], publishAddress [inet[/127.0.0.2:9300]]
[15:04:02,771][WARN ][jgroups.UDP ] send buffer of socket java.net.DatagramSocket@1faac07d was set to 640KB, but the OS only allocated 131.07KB. This might lead to performance problems. Please set your max send buffer in the OS correctly (e.g. net.core.wmem_max on Linux)
[15:04:02,771][WARN ][jgroups.UDP ] receive buffer of socket java.net.DatagramSocket@1faac07d was set to 20MB, but the OS only allocated 131.07KB. This might lead to performance problems. Please set your max receive buffer in the OS correctly (e.g. net.core.rmem_max on Linux)
[15:04:02,771][WARN ][jgroups.UDP ] send buffer of socket java.net.MulticastSocket@2259a735 was set to 640KB, but the OS only allocated 131.07KB. This might lead to performance problems. Please set your max send buffer in the OS correctly (e.g. net.core.wmem_max on Linux)
[15:04:02,771][WARN ][jgroups.UDP ] receive buffer of socket java.net.MulticastSocket@2259a735 was set to 25MB, but the OS only allocated 131.07KB. This might lead to performance problems. Please set your max receive buffer in the OS correctly (e.g. net.core.rmem_max on Linux)
[15:04:04,814][INFO ][cluster ] [Doe, John] New Master [Doe, John][getafix-2590][data][inet[/127.0.0.2:9300]]
[15:04:04,882][INFO ][discovery ] [Doe, John] elasticsearch/getafix-2590
[15:04:04,901][INFO ][http ] [Doe, John] boundAddress [inet[/0.0.0.0:9200]], publishAddress [inet[/127.0.0.2:9200]]
[15:04:05,140][INFO ][jmx ] [Doe, John] boundAddress [service:jmx:rmi:///jndi/rmi://:9400/jmxrmi], publishAddress [service:jmx:rmi:///jndi/rmi://127.0.0.2:9400/jmxrmi]
[15:04:05,140][INFO ][server ] [Doe, John] {ElasticSearch/0.5.0/2010-02-18T13:42:47/dev}: Started
[15:04:06,516][INFO ][cluster.metadata ] [Doe, John] Creating Index [es_test_2], shards [3]/[1]
[15:04:06,992][INFO ][cluster.metadata ] [Doe, John] Deleting index [es_test_2]
Exception in thread "elasticsearch[Doe, John]clusterService#updateTask-pool-6-thread-1" java.lang.NullPointerException
at org.elasticsearch.cluster.action.shard.ShardStateAction$4.execute(ShardStateAction.java:129)
at org.elasticsearch.cluster.DefaultClusterService$2.run(DefaultClusterService.java:161)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Exception in thread "elasticsearch[Doe, John]clusterService#updateTask-pool-6-thread-2" java.lang.NullPointerException
at org.elasticsearch.cluster.action.shard.ShardStateAction$4.execute(ShardStateAction.java:129)
at org.elasticsearch.cluster.DefaultClusterService$2.run(DefaultClusterService.java:161)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Exception in thread "elasticsearch[Doe, John]clusterService#updateTask-pool-6-thread-3" java.lang.NullPointerException
at org.elasticsearch.cluster.action.shard.ShardStateAction$4.execute(ShardStateAction.java:129)
at org.elasticsearch.cluster.DefaultClusterService$2.run(DefaultClusterService.java:161)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Test script:
The text was updated successfully, but these errors were encountered: