This file contains hidden or 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
| Index: src/java/main/org/apache/zookeeper/client/StaticHostProvider.java | |
| =================================================================== | |
| --- src/java/main/org/apache/zookeeper/client/StaticHostProvider.java (revision 1450278) | |
| +++ src/java/main/org/apache/zookeeper/client/StaticHostProvider.java (working copy) | |
| @@ -116,8 +116,7 @@ | |
| InetAddress resolvedAddresses[] = InetAddress.getAllByName((ia!=null) ? ia.getHostAddress(): | |
| address.getHostName()); | |
| for (InetAddress resolvedAddress : resolvedAddresses) { | |
| - tmpList.add(new InetSocketAddress(resolvedAddress | |
| - .getHostAddress(), address.getPort())); |
This file contains hidden or 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
| private boolean isBetterSelection(List<StoreFile> bestSelection, | |
| long bestSize, List<StoreFile> selection, long size, boolean mightBeStuck) { | |
| if (mightBeStuck && bestSize > 0 && size > 0) { | |
| // Keep the selection that removes most files for least size. That penaltizes adding | |
| // large files to compaction, but not small files, so we don't become totally inefficient | |
| // (might want to tweak that in future). Also, given the current order of looking at | |
| // permutations, prefer earlier files and smaller selection if the difference is small. | |
| final double REPLACE_IF_BETTER_BY = 1.05; | |
| double thresholdQuality = ((double)bestSelection.size() / bestSize) * REPLACE_IF_BETTER_BY; | |
| return thresholdQuality < ((double)selection.size() / size); |
This file contains hidden or 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
| jps | awk '$2 != "Jps" {print $1}' | xargs kill |
This file contains hidden or 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
| echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p |
This file contains hidden or 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
| [INFO] Zeppelin ........................................... |
This file contains hidden or 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
| 2016-08-02 11:34:31,836 ERROR [main] zookeeper.ZooKeeperWatcher: hconnection-0x6c302a1d0x0, quorum=localhost:2181, baseZNode=/hbase Received unexpected KeeperException, re-throwing exception | |
| org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /hbase/hbaseid | |
| at org.apache.zookeeper.KeeperException.create(KeeperException.java:99) | |
| at org.apache.zookeeper.KeeperException.create(KeeperException.java:51) | |
| at org.apache.zookeeper.ZooKeeper.exists(ZooKeeper.java:1102) | |
| at org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.exists(RecoverableZooKeeper.java:220) | |
| at org.apache.hadoop.hbase.zookeeper.ZKUtil.checkExists(ZKUtil.java:416) | |
| at org.apache.hadoop.hbase.zookeeper.ZKClusterId.readClusterIdZNode(ZKClusterId.java:65) | |
| at org.apache.hadoop.hbase.client.ZooKeeperRegistry.getClusterId(ZooKeeperRegistry.java:102) | |
| at org.apache.hadoop.hbase.client.ConnectionImplementation.retrieveClusterId(ConnectionImplementation.java:443) |
This file contains hidden or 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
| @Override | |
| public int getProgress(InterpreterContext context) { | |
| open(); | |
| return intp.getProgress(context); | |
| } |
This file contains hidden or 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
| { | |
| List<String> set = Lists.newArrayList(); | |
| for (int i = 0; i < 5; i++) { | |
| String a = new String("a"); | |
| String b = "a"; | |
| System.out.println(System.identityHashCode(a)); | |
| System.out.println(System.identityHashCode(b)); | |
| set.add("c"); | |
| System.out.println("?? =====> " + System.identityHashCode(set.get(0))); | |
| set.clear(); |
This file contains hidden or 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
| sudo gem install -n /usr/local/bin GEM_NAME_HERE |
This file contains hidden or 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
| GEM_HOME=/usr/local/bin |
NewerOlder