Scrum Master
, one Product Owner
, and Developers
.The team should have all the skills needed to create the product. Having to rely on others outside of the team means dependencies on people outside of the team. This will result in delays. A knowledg
Type | Pros | Cons |
---|---|---|
Native Web Tool | 1.Widely used and supported by a large community of developers. 2.Highly customizable and flexible, allowing for a wide range of solutions to be developed. 3.Can be integrated with a variety of databases and APIs. |
1.Steep learning curve, as JavaScript can be complex and requires a good understanding of programming concepts. 2.Can be difficult to maintain and debug, especially for large and complex applications. 3.Can be slow in older browsers and less optimized devices. |
Power BI | 1.User-friendly interface, making it easy for non-technical users to create and customize reports. 2.Offers a range of built-in visualization options and tools for data analysis. 3.Integrates well with other Microsoft/Azure tools, such as Excel and SharePoint. |
1.Limited customization options compared to JavaScript. 2.Can be less flexible and may not be suitable for more complex reporting requirements. 3. |
GPT-3.5 系列模型最重要的变化,是建立在人类真实反馈基础上的调校。这是一种新使用的 AI 训练方法,标记者会在模型中书写期待的回复,按照期待的回复为标记的答案排序,通过排序来奖励模型。在持续迭代的过程中,输入奖励模型,得到优化参数。
训练步骤
sudo apt-get -y install openvpn
sudo touch /etc/openvpn/credentials
sudo printf '%s\n' 'username' 'password' > /etc/openvpn/credentials
sudo sed -i 's/auth-user-pass/auth-user-pass \/etc\/openvpn\/credentials/g' /etc/openvpn/US-East.ovpn
sudo openvpn --config /etc/openvpn/US-East.ovpn
Reference:
How to Setup OpenVPN Command Line on Linux (Ubuntu)
S3 Select is focused on retrieving data from S3 using SQL:
S3 Select, enables applications to retrieve only a subset of data from an object by using simple SQL expressions. By using S3 Select to retrieve only the data needed by your application, you can achieve drastic performance increases – in many cases you can get as much as a 400% improvement compared with classic S3
ALTER TABLE ZAWTH_Raw_Core_Branch.raw.POS_TRANSACTION ALTER COLUMN [transaction_line_id] VARCHAR(128) NULL;
reference: https://stackoverflow.com/a/29400789
SELECT SPID = er.session_id
,STATUS = ses.STATUS
,[Login] = ses.login_name
,Host = ses.host_name
,BlkBy = er.blocking_session_id
,DBName = DB_Name(er.database_id)
,CommandType = er.command
,ObjectName = OBJECT_NAME(st.objectid)
,CPUTime = er.cpu_time
,StartTime = er.start_time
,TimeElapsed = CAST(GETDATE() - er.start_time AS TIME)
,SQLStatement = st.text
FROM sys.dm_exec_requests er
OUTER APPLY sys.dm_exec_sql_text(er.sql_handle) st
LEFT JOIN sys.dm_exec_sessions ses
ON ses.session_id = er.session_id
LEFT JOIN sys.dm_exec_connections con
ON con.session_id = ses.session_id
WHERE st.text IS NOT NULL
Create EFS on AWS web portal
Edit the security group of EFS to allow access from EC2 instances
Mount EFS on EC2
sudo mkdir efs
sudo chmod 777 /efs
Install amazon-efs-utils
for auto-remount
git clone https://github.com/aws/efs-utils
cd efs-utils/
./build-deb.sh
sudo apt-get -y install ./build/amazon-efs-utils*deb
Configure IAM role in EC2 (already done)
Edit /etc/fstab
fs-xxxxxxxx:/ /efs efs _netdev,tls,iam 0 0
Test mount
sudo mount -fav
Add Linux user in the other EC2's group to avoid readonly
issue
sudo usermod -a -G ubuntu guangningyu
sudo usermod -a -G guangningyu ubuntu
Reference:
1. Mount the Amazon EFS File System on the EC2 Instance and Test
2. Mounting your Amazon EFS file system automatically
3. User and Group ID Permissions for Files and Directories Within a File System
test.csv
key,a,b,c
a,1,,-1
a,2,,
a,3,,4
test.py
from pyspark.sql import SparkSession
from pyspark.sql import functions as F
spark = SparkSession \
.builder \
.appName("spark-app") \
.getOrCreate()
spark.sparkContext.setLogLevel("WARN")
df = spark.read.csv("test.csv", header=True)
res = df.groupBy(["key"]).agg(*[
F.max("a"),
F.max("b"),
F.max("c"),
F.min("a"),
F.min("b"),
F.min("c"),
])
print (res.toPandas())
spark-submit test.py
key max(a) max(b) max(c) min(a) min(b) min(c)
0 a 3 None 4 1 None -1
brew update && brew install azure-cli
az login
brew tap azure/functions
brew install azure-functions-core-tools@2
References:
Install Azure CLI on macOS
Azure/azure-functions-core-tools
Reference: Windows Server 2016 : Initial Settings : Add Local Users
Install dependencies
sudo apt-get update
sudo apt-get install automake autotools-dev fuse g++ git libcurl4-gnutls-dev libfuse-dev libssl-dev libxml2-dev make pkg-config
Install s3fs
git clone https://github.com/s3fs-fuse/s3fs-fuse.git
cd s3fs-fuse
./autogen.sh
./configure --prefix=/usr --with-openssl
make
sudo make install
which s3fs
Config credentials
echo "Your_accesskey:Your_secretkey" >> /etc/passwd-s3fs
sudo chmod 640 /etc/passwd-s3fs
Create mounting point
mkdir /mys3bucket
s3fs your_bucketname -o use_cache=/tmp -o allow_other -o uid=1001 -o mp_umask=002 -o multireq_max=5 /mys3bucket
Config mount after reboot
Add the following command in /etc/rc.local
:
/usr/local/bin/s3fs your_bucketname -o use_cache=/tmp -o allow_other -o uid=1001 -o mp_umask=002 -o multireq_max=5 /mys3bucket
Reference:
How to Mount S3 bucket on EC2 Linux Instance
# Install Nextcloud stack
sudo snap install nextcloud
# Create administrator account
sudo nextcloud.manual-install <admin_username> <admin_password>
# Configure trusted domains (only localhost by default)
sudo nextcloud.occ config:system:get trusted_domains
sudo nextcloud.occ config:system:set trusted_domains 1 --value=<dns-domain>
# Set 512M as PHP memory limit
sudo snap get nextcloud php.memory-limit # Should be 512M
sudo snap set nextcloud php.memory-limit=512M
# Set background jobs interval (e.g. checking for new emails, update RSS feeds, ...)
sudo snap set nextcloud nextcloud.cron-interval=10m # Default: 15m
sudo snap set nextcloud ports.http=81 ports.https=444
Reference:
Nextcloud on AWS
Putting the snap behind a reverse proxy
$ export RELEASE=$(curl -s https://api.github.com/repos/kubeless/kubeless/releases/latest | grep tag_name | cut -d '"' -f 4)
$ kubectl create ns kubeless
$ kubectl create -f https://github.com/kubeless/kubeless/releases/download/$RELEASE/kubeless-$RELEASE.yaml
$ kubectl get pods -n kubeless
$ kubectl get deployment -n kubeless
$ kubectl get customresourcedefinition
def hello(event, context):
print event
return event['data']
$ kubeless function deploy hello --runtime python2.7 \
--from-file test.py \
--handler test.hello
$ kubectl get functions
$ kubeless function ls
$ kubeless function call hello --data 'Hello world!'
create a file
echo This is a sample text file > sample.txt
delete a file
del file_name
move a file
move stats.doc c:\statistics
combine files
copy /b file1 + file2 file3
import pandas as pd
import pyodbc
import sqlalchemy
import urllib
def get_sqlalchemy_engine(driver, server, uid, pwd, database):
conn_str = 'DRIVER={};SERVER={};UID={};PWD={};DATABASE={}'.format(driver, server, uid, pwd, database)
quoted = urllib.parse.quote_plus(conn_str)
engine = sqlalchemy.create_engine('mssql+pyodbc:///?odbc_connect={}'.format(quoted))
return engine
if __name__ == '__main__':
# create engine
driver = 'ODBC Driver 17 for SQL Server'
server = 'xxx'
uid = 'xxx'
pwd = 'xxx'
database = 'xxx'
engine = get_sqlalchemy_engine(driver, server, uid, pwd, database)
# read excel
file_path = 'xxx'
df = pd.read_excel(file_path)
# load into SQL Server
schema_name = 'xxx'
table_name = 'xxx'
df.to_sql(table_name, schema=schema_name, con=engine, index=False, if_exists='replace')