-
Notifications
You must be signed in to change notification settings - Fork 24.8k
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
Move tribe to a module #25778
Merged
ywelsch
merged 12 commits into
elastic:master
from
ywelsch:enhance/move-tribe-to-plugin
Jul 28, 2017
Merged
Move tribe to a module #25778
Changes from 9 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
92b07cd
move tribe to its own module
ywelsch 36454ec
remove obsolete tribe tests
ywelsch 462a600
remove stale test
ywelsch e6064ea
fix test name
ywelsch fdcc93a
Fix TribeUnitTests
ywelsch f290c59
properly clean up if inner tribe fails to initialize
ywelsch e86a5cf
Merge remote-tracking branch 'elastic/master' into enhance/move-tribe…
ywelsch 2025150
unguice
ywelsch 996d7d7
don't allow dynamic updates to tribe settings
ywelsch 5b81192
byebye Node.newNode(...)
ywelsch e9c4519
Remove classpathPlugins parameter
ywelsch be55c18
fix testTribeNodeDeprecation
ywelsch File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
core/src/main/java/org/elasticsearch/cluster/MergableCustomMetaData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/* | ||
* Licensed to Elasticsearch under one or more contributor | ||
* license agreements. See the NOTICE file distributed with | ||
* this work for additional information regarding copyright | ||
* ownership. Elasticsearch licenses this file to you under | ||
* the Apache License, Version 2.0 (the "License"); you may | ||
* not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
package org.elasticsearch.cluster; | ||
|
||
import org.elasticsearch.cluster.metadata.MetaData; | ||
|
||
/** | ||
* Interface to allow merging {@link org.elasticsearch.cluster.metadata.MetaData.Custom}. | ||
* When multiple Mergable Custom metadata of the same type are found (from underlying clusters), the | ||
* Custom metadata can be merged using {@link #merge(MetaData.Custom)}. | ||
* | ||
* @param <T> type of custom meta data | ||
*/ | ||
public interface MergableCustomMetaData<T extends MetaData.Custom> { | ||
|
||
/** | ||
* Merges this custom metadata with other, returning either this or <code>other</code> custom metadata. | ||
* This method should not mutate either <code>this</code> or the <code>other</code> custom metadata. | ||
* | ||
* @param other custom meta data | ||
* @return the same instance or <code>other</code> custom metadata based on implementation | ||
* if both the instances are considered equal, implementations should return this | ||
* instance to avoid redundant cluster state changes. | ||
*/ | ||
T merge(T other); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should not make this a first class citizen. Instead I suggest we remove the Node#newNode entirely and add a
MockTribePlugin
class that passes such a function that delegates to / creates aMockNode
. Given that tribe goes away I think that is the right tradeoff. WDYT?