val environment = StreamExecutionEnvironment.createLocalEnvironment(3)
运行程序:执行main方法
在Linux的nc界面输入内容,在开发工具的控制台查看输出结果
远程脚本部署
客户端程序修改为自动识别运行环境
val environment = StreamExecutionEnvironment.getExecutionEnvironment
通过mvn package生成jar包
把生成的jar传输到Linux系统的/tmp/flink目录下
通过执行flink_home/bin目录下的flink文件的run action,提交job
说明
-c,--class<classname>
Class withthe program entry point ("main()" method). Only needed if the JAR file does not specify the class in its manifest.
指定启动类
-d,--detached
If present, runs the job in detached mode
后台提交
-p,--parallelism <parallelism>
The parallelism withwhich to run the program. Optional flag to override the
default value specified in the configuration.
指定并行度
-m,--jobmanager <arg>
Address of the JobManager (master) to which to connect. Use this flag to connect to a different JobManager than the one specified in the configuration.
提交目标主机
遇到一个奇怪的问题,当SplashActivity跳转到MainActivity之后,按主页键,再去打开程序,程序没法再打开(闪一下),结束任务再开也是这样,只能卸载了再重装。而且每次在Log里都打印了这句话"进入主程序"。后来发现是必须跳转之后再finish掉SplashActivity
本来代码:
// 销毁这个Activity
fin
Kafka is a distributed, partitioned, replicated commit log service.这里的commit log如何理解?
A message is considered "committed" when all in sync replicas for that partition have applied i
安装lua_nginx_module 模块
lua_nginx_module 可以一步步的安装,也可以直接用淘宝的OpenResty
Centos和debian的安装就简单了。。
这里说下freebsd的安装:
fetch http://www.lua.org/ftp/lua-5.1.4.tar.gz
tar zxvf lua-5.1.4.tar.gz
cd lua-5.1.4
ma
今天看Netty如何实现一个Http Server
org.jboss.netty.example.http.file.HttpStaticFileServerPipelineFactory:
pipeline.addLast("decoder", new HttpRequestDecoder());
pipeline.addLast(&quo
环境:Windows XPPHP Version 5.2.9MySQL Server 5.1
第一步、创建一个表date_test(非定长、int时间)
CREATE TABLE `test`.`date_test` (`id` INT NOT NULL AUTO_INCREMENT ,`start_time` INT NOT NULL ,`some_content`
在两个activity直接传递List<xxInfo>时,出现Parcel: unable to marshal value异常。 在MainActivity页面(MainActivity页面向NextActivity页面传递一个List<xxInfo>): Intent intent = new Intent(this, Next
转载:http://www.ibm.com/developerworks/cn/web/wa-jaxrs/
JAX-RS (JSR-311) 【 Java API for RESTful Web Services 】是一种 Java™ API,可使 Java Restful 服务的开发变得迅速而轻松。这个 API 提供了一种基于注释的模型来描述分布式资源。注释被用来提供资源的位
ConnectionKeepAliveStrategy kaStrategy = new DefaultConnectionKeepAliveStrategy() {
@Override
public long getKeepAliveDuration(HttpResponse response, HttpContext context) {
long keepAlive