资源简介
使用tar解压要安装的目录即可,实际安装根据自己的想安装的目录修改(注意如果修改,那后边的命令和配置文件中的路径都要相应修改)
tar -zxf zookeeper-3.4.5.tar.gz -C /usr/myapp
代码片段和文件信息
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF 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.apache.zookeeper.util;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.ArrayList;
import java.util.HashMap;
/**
* This is a generic Main class that is completely driven by the
* /mainClasses resource on the class path. This resource has the
* format:
*
* cmd:mainClass:Description
*
* Any lines starting with # will be skipped
*
*/
public class FatJarMain {
static class Cmd {
Cmd(String cmd String clazz String desc) {
this.cmd = cmd;
this.clazz = clazz;
this.desc = desc;
}
String cmd;
String clazz;
String desc;
}
static HashMap cmds = new HashMap();
static ArrayList order = new ArrayList();
/**
* @param args the first parameter of args will be used as an
* index into the /mainClasses resource. The rest will be passed
* to the mainClass to run.
* @throws IOException
* @throws ClassNotFoundException
* @throws NoSuchMethodException
* @throws SecurityException
* @throws IllegalAccessException
* @throws IllegalArgumentException
*/
public static void main(String[] args) throws IOException ClassNotFoundException SecurityException NoSuchMethodException IllegalArgumentException IllegalAccessException {
InputStream is = FatJarMain.class.getResourceAsStream(“/mainClasses“);
if (is == null) {
System.err.println(“Couldn‘t find /mainClasses in classpath.“);
System.exit(3);
}
BufferedReader br = new BufferedReader(new InputStreamReader(is));
String line;
while((line = br.readLine()) != null) {
String parts[] = line.split(“:“ 3);
if (parts.length != 3 || (parts[0].length() > 0 && parts[0].charAt(0) == ‘#‘)) {
continue;
}
if (parts[0].length() > 0) {
cmds.put(parts[0] new Cmd(parts[0] parts[1] parts[2]));
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 238 2012-10-01 01:53 zookeeper-3.4.5\bin\README.txt
文件 1909 2012-10-01 01:53 zookeeper-3.4.5\bin\zkCleanup.sh
文件 1049 2012-10-01 01:53 zookeeper-3.4.5\bin\zkCli.cmd
文件 1512 2012-10-01 01:53 zookeeper-3.4.5\bin\zkCli.sh
文件 1333 2012-10-01 01:53 zookeeper-3.4.5\bin\zkEnv.cmd
文件 2599 2012-10-01 01:53 zookeeper-3.4.5\bin\zkEnv.sh
文件 1084 2012-10-01 01:53 zookeeper-3.4.5\bin\zkServer.cmd
文件 5467 2012-10-01 01:53 zookeeper-3.4.5\bin\zkServer.sh
文件 75988 2012-10-01 01:53 zookeeper-3.4.5\build.xm
文件 70223 2012-10-01 01:53 zookeeper-3.4.5\CHANGES.txt
文件 535 2012-10-01 01:53 zookeeper-3.4.5\conf\configuration.xsl
文件 2161 2012-10-01 01:53 zookeeper-3.4.5\conf\log4j.properties
文件 808 2012-10-01 01:53 zookeeper-3.4.5\conf\zoo.cfg
文件 808 2012-10-01 01:53 zookeeper-3.4.5\conf\zoo_sample.cfg
文件 2984 2012-10-01 01:53 zookeeper-3.4.5\contrib\fatjar\build.xm
文件 707 2012-10-01 01:53 zookeeper-3.4.5\contrib\fatjar\conf\mainClasses
文件 4472 2012-10-01 01:53 zookeeper-3.4.5\contrib\fatjar\src\java\org\apache\zookeeper\util\FatJarMain.java
文件 7088129 2012-11-05 15:59 zookeeper-3.4.5\contrib\fatjar\zookeeper-3.4.5-fatjar.jar
文件 2550 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\build.xm
文件 947 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\FilterException.java
文件 2070 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\FilterOp.java
文件 1207 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\AndOp.java
文件 1209 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\Arg.java
文件 1418 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\EqualsOp.java
文件 2381 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\GreaterThanOp.java
文件 2276 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\LessThanOp.java
文件 1253 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\NotOp.java
文件 1034 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\NumberArg.java
文件 1209 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\OrOp.java
文件 1042 2012-10-01 01:53 zookeeper-3.4.5\contrib\loggraph\src\java\org\apache\zookeeper\graph\filterops\StringArg.java
............此处省略1816个文件信息
- 上一篇:54万条商品条形码数据库
- 下一篇:量子场论量子场论.pdf
相关资源
- zookeeper-3.4.8.tar.gz
- dubbo+zookeeper入门资源
- zookeeper-3.4.5-cdh5.10.0.tar.gz
- zookeeper-3.4.6 下载151871
- zookeeper-3.4.6
- zookeeper-3.4.5.tar.gz178819
- zookeeper 分布式实践
- 从Paxos到Zookeeper分布式一致性原理与实
- zookeeper-3.4.5.tar.gz
- zookeeper-3.4.10 64位 Windows服务版
- zookeeper-3.4.8解压即用低分版
- 从Paxos到Zookeeper++分布式一致性原理与
- dubbo zookeeper demo
- zookeeper插件
- eclipse 中实现dubbo provider、customer源代
- jdk-8u171-linux-i586.tar.gz和zookeeper-3.4.6.
- zookeeper+Dubbo环境搭建所需工具
- 尚硅谷大数据之Zookeeper视频笔记+代码
- idea开发的springboot+dubbo+zookeeper的简单
- Zookeeper源码分析
- zkui-2.0 zookeeper可视化管理器
- springboot-mybatis-dubbo-zookeeper项目框架
- zookeeper 使用指导PDF
- zookeeper+dubbo+spring
-
大数据hadoop+spark+hba
se+zookeeper+kafka - 极客学院Zookeeper全套视频和课件
- ZooKeeper分布式专题与Dubbo微服务入门
- springboot+dubbo+myBatis集成
- springboot+dubbo+zookeeper实现分布式系统增
- Zookeeper学习.txt
评论
共有 条评论