Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
kvdb
rocksdb
提交
fcd1e0bf
R
rocksdb
项目概览
kvdb
/
rocksdb
12 个月 前同步成功
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rocksdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
fcd1e0bf
编写于
10月 26, 2016
作者:
I
Islam AbdelRahman
提交者:
Islam AbdelRahman
10月 28, 2016
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Make rocksdb work with internal repo
fbshipit-source-id: f52d2b6d39668516270c51945fc4e1693e553ff7
上级
0aab5e55
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
12 addition
and
15 deletion
+12
-15
.arcconfig
.arcconfig
+1
-1
.gitignore
.gitignore
+1
-0
arcanist_util/config/RocksDBCommonHelper.php
arcanist_util/config/RocksDBCommonHelper.php
+10
-14
未找到文件。
.arcconfig
浏览文件 @
fcd1e0bf
{
"project_id" : "rocksdb",
"conduit_uri" : "https://
reviews.facebook.net
/",
"conduit_uri" : "https://
phabricator.fb.com/api
/",
"copyright_holder" : "Facebook",
"load" : [
"arcanist_util"
...
...
.gitignore
浏览文件 @
fcd1e0bf
...
...
@@ -69,3 +69,4 @@ LOG
db_logs/
tp2/
fbcode/
fbcode
arcanist_util/config/RocksDBCommonHelper.php
浏览文件 @
fcd1e0bf
...
...
@@ -12,7 +12,6 @@ define("ENV_HTTPS_APP_VALUE", "HTTPS_APP_VALUE");
define
(
"ENV_HTTPS_TOKEN_VALUE"
,
"HTTPS_TOKEN_VALUE"
);
define
(
"PRIMARY_TOKEN_FILE"
,
'/home/krad/.sandcastle'
);
define
(
"SECONDARY_TOKEN_FILE"
,
'$HOME/.sandcastle'
);
define
(
"CONT_RUN_ALIAS"
,
"leveldb"
);
//////////////////////////////////////////////////////////////////////
...
...
@@ -25,9 +24,7 @@ function postURL($diffID, $url) {
$cmd
=
'echo \'{"diff_id": "'
.
$diffID
.
'", '
.
'"name":"click here for sandcastle tests for D'
.
$diffID
.
'", '
.
'"link":"'
.
$url
.
'"}\' | '
.
'no_proxy=facebook.com,tfbnw.net,fb.com '
.
'http_proxy=fwdproxy.any.facebook.com:8080 '
.
'https_proxy=fwdproxy.any.facebook.com:8080 arc call-conduit '
.
'arc call-conduit '
.
'differential.updateunitresults'
;
shell_exec
(
$cmd
);
}
...
...
@@ -41,9 +38,7 @@ function buildUpdateTestStatusCmd($diffID, $test, $status) {
$cmd
=
'echo \'{"diff_id": "'
.
$diffID
.
'", '
.
'"name":"'
.
$test
.
'", '
.
'"result":"'
.
$status
.
'"}\' | '
.
'no_proxy=facebook.com,tfbnw.net,fb.com '
.
'http_proxy=fwdproxy.any.facebook.com:8080 '
.
'https_proxy=fwdproxy.any.facebook.com:8080 arc call-conduit '
.
'arc call-conduit '
.
'differential.updateunitresults'
;
return
$cmd
;
}
...
...
@@ -108,8 +103,7 @@ function getSteps($applyDiff, $diffID, $username, $test) {
// Patch the code (keep your fingures crossed).
$patch
=
array
(
"name"
=>
"Patch "
.
$diffID
,
"shell"
=>
"no_proxy=facebook.com,tfbnw.net,fb.com "
.
"HTTPS_PROXY=fwdproxy:8080 arc --arcrc-file ~/.arcrc "
"shell"
=>
"arc --arcrc-file ~/.arcrc "
.
"patch --nocommit --diff "
.
$diffID
,
"user"
=>
"root"
);
...
...
@@ -178,6 +172,8 @@ function getSteps($applyDiff, $diffID, $username, $test) {
function
getSandcastleConfig
()
{
$sandcastle_config
=
array
();
$cwd
=
getcwd
();
$cwd_token_file
=
"
{
$cwd
}
/.sandcastle"
;
// This is a case when we're executed from a continuous run. Fetch the values
// from the environment.
if
(
getenv
(
ENV_POST_RECEIVE_HOOK
))
{
...
...
@@ -188,20 +184,20 @@ function getSandcastleConfig() {
// configuration files.
for
(
$i
=
0
;
$i
<
50
;
$i
++
)
{
if
(
file_exists
(
PRIMARY_TOKEN_FILE
)
||
file_exists
(
SECONDARY_TOKEN_FILE
))
{
file_exists
(
$cwd_token_file
))
{
break
;
}
// If we failed to fetch the tokens, sleep for 0.2 second and try again
usleep
(
200000
);
}
assert
(
file_exists
(
PRIMARY_TOKEN_FILE
)
||
file_exists
(
SECONDARY_TOKEN_FILE
));
file_exists
(
$cwd_token_file
));
// Try the primary location first, followed by a secondary.
if
(
file_exists
(
PRIMARY_TOKEN_FILE
))
{
$cmd
=
'cat '
.
PRIMARY_TOKEN_FILE
;
}
else
{
$cmd
=
'cat '
.
SECONDARY_TOKEN_FILE
;
$cmd
=
'cat '
.
$cwd_token_file
;
}
assert
(
strlen
(
$cmd
)
>
0
);
...
...
@@ -305,7 +301,7 @@ function getSandcastleConfig() {
// Submit to Sandcastle.
$url
=
'https://interngraph.intern.facebook.com/sandcastle/generate?'
.
'command=SandcastleUniversalCommand'
.
'&vcs=rocksdb-git&revision=origin%2Fmaster&type=lego'
.
'&vcs=rocksdb-
int-
git&revision=origin%2Fmaster&type=lego'
.
'&user='
.
$username
.
'&alias=rocksdb-precommit'
.
'&command-args='
.
urlencode
(
json_encode
(
$command
));
...
...
@@ -315,7 +311,7 @@ function getSandcastleConfig() {
$app
=
$sandcastle_config
[
0
];
$token
=
$sandcastle_config
[
1
];
$cmd
=
'
https_proxy= HTTPS_PROXY=
curl -s -k -F app='
.
$app
.
' '
$cmd
=
'curl -s -k -F app='
.
$app
.
' '
.
'-F token='
.
$token
.
' "'
.
$url
.
'"'
;
$output
=
shell_exec
(
$cmd
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录