国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。
Dockerized 实践 https://github.com/y0ngb1n/dockerized
''' | |
spark/bin/spark-submit \ | |
--master local --driver-memory 4g \ | |
--num-executors 2 --executor-memory 4g \ | |
--packages org.apache.spark:spark-sql-kafka-0-10_2.11:2.4.0 \ | |
sstreaming-spark-final.py | |
''' | |
from pyspark.sql import SparkSession | |
from pyspark.sql.types import * | |
from pyspark.sql.functions import expr |
// Tensorflow Serving Go client for the inception model | |
// go get github.com/golang/protobuf/ptypes/wrappers google.golang.org/grpc | |
// | |
// Compile the proto files: | |
// | |
// git clone https://github.com/tensorflow/serving.git | |
// git clone https://github.com/tensorflow/tensorflow.git | |
// | |
// mkdir -p vendor |
Assuming that the following environment variables are set:
KAFKA_HOME
where Kafka is installed on local machine (e.g. /opt/kafka
)ZK_HOSTS
identifies running zookeeper ensemble, e.g. ZK_HOSTS=192.168.0.99:2181
KAFKA_BROKERS
identifies running Kafka brokers, e.g. KAFKA_BROKERS=192.168.0.99:9092
Start Zookepper and Kafka servers
This procedure explains how to install MySQL using Homebrew on macOS Sierra 10.12
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
At this time of writing, Homebrew has MySQL version 5.7.15 as default formulae in its main repository :
from __future__ import absolute_import | |
from __future__ import division | |
from __future__ import print_function | |
import os.path | |
import re | |
import sys | |
import tarfile | |
import numpy as np |
<?xml version="1.0" encoding="utf-8"?> | |
<!-- | |
Copyright (C) 2015 The Android Open Source Project | |
Licensed 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 |
# Set variables in .bashrc file | |
# don't forget to change your path correctly! | |
export GOPATH=$HOME/golang | |
export GOROOT=/usr/local/opt/go/libexec | |
export PATH=$PATH:$GOPATH/bin | |
export PATH=$PATH:$GOROOT/bin |
#!/bin/bash | |
PROG_NAME=$0 | |
ACTION=$1 | |
usage() { | |
echo "Usage: $PROG_NAME {list|ping|optimal|conn|close|status}" | |
exit 1 | |
} |
/* | |
* Copyright 2014 Chris Banes | |
* | |
* Licensed 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 |