thx / rap2-delos Goto Github PK
View Code? Open in Web Editor NEW阿里妈妈前端团队出品的开源接口管理工具RAP第二代
Home Page: http://rap2.taobao.org
License: MIT License
阿里妈妈前端团队出品的开源接口管理工具RAP第二代
Home Page: http://rap2.taobao.org
License: MIT License
node-pre-gyp ERR! Tried to download(undefined): https://fsevents-binaries.s3-us-west-2.amazonaws.com/v1.1.3/fse-v1.1.3-node-v51-darwin-x64.tar.gz
node-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v51 ABI, unknown) (falling back to source compile with node-gyp)
SOLINK_MODULE(target) Release/.node
CXX(target) Release/obj.target/fse/fsevents.o
SOLINK_MODULE(target) Release/fse.node
COPY /Users/shuxian/Projects/git/git-tools/alibaba-rap/node_modules/fsevents/lib/binding/Release/node-v51-darwin-x64/fse.node
TOUCH Release/obj.target/action_after_build.stamp
[email protected] install /Users/shuxian/Projects/git/git-tools/alibaba-rap/node_modules/pre-commit
node install.js
pre-commit:
pre-commit: Detected an existing git pre-commit hook
pre-commit: Old pre-commit hook backuped to pre-commit.old
pre-commit:
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] check: npm run linter && test
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] check script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
错误日志
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/Cellar/node/7.9.0/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'run',
1 verbose cli 'check' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'precheck', 'check', 'postcheck' ]
5 info lifecycle [email protected]precheck: [email protected]check: [email protected]
6 info lifecycle [email protected]
7 verbose lifecycle [email protected]check: unsafe-perm in lifecycle truecheck: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users//Projects/git/git-tools/alibaba-rap/node_modules/.bin:/Users//opt/apache-maven/3.5.0/bin:/Library/Java/JavaVirtualMachines/jdk1.8.0_121.jdk/Contents/Home/bin:/Library/gradle/gradle-3.5/bin:/Users//workspace/go/bin:/Users//Library/Android/sdk/tools:/Users//Library/Android/sdk/platform-tools:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/go/bin:/opt/X11/bin:/Library/Frameworks/Mono.framework/Versions/Current/Commands
8 verbose lifecycle [email protected]
9 verbose lifecycle [email protected]check: CWD: /Users/Projects/git/git-tools/alibaba-rapcheck: Args: [ '-c', 'npm run linter && test' ]
10 silly lifecycle [email protected]
11 silly lifecycle [email protected]check: Returned: code: 1 signal: nullcheck: Failed to exec check script
12 info lifecycle [email protected]
13 verbose stack Error: [email protected] check: npm run linter && test
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:280:16)
13 verbose stack at emitTwo (events.js:106:13)
13 verbose stack at EventEmitter.emit (events.js:194:7)
13 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at emitTwo (events.js:106:13)
13 verbose stack at ChildProcess.emit (events.js:194:7)
13 verbose stack at maybeClose (internal/child_process.js:899:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
14 verbose pkgid [email protected]
15 verbose cwd /Users/Projects/git/git-tools/alibaba-rap
16 verbose Darwin 17.2.0
17 verbose argv "/usr/local/Cellar/node/7.9.0/bin/node" "/usr/local/bin/npm" "run" "check"
18 verbose node v7.9.0
19 verbose npm v5.5.1
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] check: npm run linter && test
22 error Exit status 1
23 error Failed at the [email protected] check script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
我使用nohup执行npm start,会话界面退出后,就会关闭,请问需要怎么样执行?
nohup npm start >nohup.out 2>&1 &
1、user表运行初始化数据后缺少empId字段
2、route/analytics.js,中由于1的问题,有个select user.empId报错,同时这个文件里,updatedAt,请统一下,强迫症患者,不要select中 前面At,后面at,数据库的字段时updatedAt
比如支持LDAP ,CAS, http 头代理认证, oauth 这样可以方便企业集成用户
都安装好了,没有报错,但访问时首页,只显示一个超链接:https://rap2.alibaba-inc.com啊;
怎么访问,不会nodejs,只想搭建做接口管理系统。
通过访问http://rap2.taobao.org/account,看到了所有的用户列表,包含的信息是用户名和邮箱。
= =|| 爬虫会不会爬取一波,然后发广告?
然后删除是disabled的,html修改一下后,试了试删除自己,然后真删除了。(有可能删除别人也可以)
重新登录一下,结果……登陆不上了。。。
是否缺少对用户数据权限的处理?
npm run create-db时报下面的错误。
请指教
` [email protected] create-db /usr/local/rap2
node scripts/init
/usr/local/rap2/scripts/init/index.js:5
async function main () {
^^^^^^^^
SyntaxError: Unexpected token function
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:542:28)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:383:7)
at startup (bootstrap_node.js:149:9)
npm ERR! Linux 3.10.0-123.el7.x86_64
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "run" "create-db"
npm ERR! node v6.12.0
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! [email protected] create-db: node scripts/init
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] create-db script 'node scripts/init'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the rap2-delos package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node scripts/init
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs rap2-delos
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls rap2-delos
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /usr/local/rap2/npm-debug.log
`
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] check: npm run linter && test
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] check script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2017-11-30T12_01_13_291Z-debug.log
以下是/root/.npm/_logs/2017-11-30T12_01_13_291Z-debug.log日志文件记录
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/nodejs9/bin/node',
1 verbose cli '/usr/local/nodejs9/bin/npm',
1 verbose cli 'run',
1 verbose cli 'check' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'precheck', 'check', 'postcheck' ]
5 info lifecycle [email protected]precheck: [email protected]check: [email protected]
6 info lifecycle [email protected]
7 verbose lifecycle [email protected]check: unsafe-perm in lifecycle truecheck: PATH: /usr/local/nodejs9/lib/node_modules/npm/bin/node-gyp-bin:/usr/local/rap2/node_modules/.bin:/usr/local/nodejs9/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin
8 verbose lifecycle [email protected]
9 verbose lifecycle [email protected]check: CWD: /usr/local/rap2check: Args: [ '-c', 'npm run linter && test' ]
10 silly lifecycle [email protected]
11 silly lifecycle [email protected]check: Returned: code: 1 signal: nullcheck: Failed to exec check script
12 info lifecycle [email protected]
13 verbose stack Error: [email protected] check: npm run linter && test
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/usr/local/nodejs9/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:280:16)
13 verbose stack at EventEmitter.emit (events.js:159:13)
13 verbose stack at ChildProcess. (/usr/local/nodejs9/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:159:13)
13 verbose stack at maybeClose (internal/child_process.js:943:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:220:5)
14 verbose pkgid [email protected]
15 verbose cwd /usr/local/rap2
16 verbose Linux 3.10.0-693.5.2.el7.x86_64
17 verbose argv "/usr/local/nodejs9/bin/node" "/usr/local/nodejs9/bin/npm" "run" "check"
18 verbose node v9.2.0
19 verbose npm v5.5.1
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] check: npm run linter && test
22 error Exit status 1
23 error Failed at the [email protected] check script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
找不到数据校验的插件,求指点
今天下午由于长时间没有操作,操作的时候跳转到登陆页面,登陆成功后显示的却是chenchuanwen的账号信息,看到的也是他的厂库和内容,本人在他的厂库里面新建了一条消息做为提醒,没有删除任何内容,但是这样的情况出现时非常危险的,为什么我登陆自己的账号却跳转到别人的里面?
npm run create-db
使用的是哪个数据库配置:dev or prod?配置好prod之后,执行无反应;rap2-delos/scripts/rap2_delos.sql
interfaces
、priority
、properties
:缺少priority
字段loggers
缺少creatorId
字段现在不能区别资源传值的不同
比如 PUT {{host}}:{{port}}/post/:org_id/info/:increment_id?order_type=all
环境变量、url参数、问号传参以及body传值都无法区分,希望未来能够加入这些区分功能
建议新增创建公开仓库,有些仓库应该需要开放给所有人查看
新增屏蔽仓库,开发者只需要看到自己需要的仓库就好
建议开发“加入团队”的功能,让管理者审核通过就能查看到项目的接口;
现在团队几百人,要加人减人都很麻烦,需要管理者一个个加
访问网址,只提示有 https://rap2.alibaba-inc.com
怎么操作?能否给些指点
rap1版本还有。。这版没找到哇
添加请求参数的时候,弹窗的操作太复杂了,原有的方式挺好。
多个模块tab之间能够做个keep-alive的类似功能,以免发生未保存时数据清空,或者做个自动保存功能
期待2.0完善版本,加油!
提交人:安全部同学
正在加急修复中....
在接口的请求参数里,callback是有效的。但是xxcallback是无效的。
这两天部署完rap2后,今天一早CPU就一直跑满100%。发现是node占用CPU过高,有遇到过的吗?
希望能提供dock版本release
既然 issue 中有那么多安装出问题的,不如一劳永逸 学习 swagger, 提供 docker 版本。
单个接口可以在任何地方做导入导出,需求多变的时候,模快划分不是那么清晰,后期重新规划时,接口需要在项目间进行迁移。
部署成功, 能够正常使用,但是点击退出按钮,跳转到 host/account/login 404
要保留0.14版本的路由功能,看到2版本有这个功能,最好是保留下来。我们的接口通过代理配置,没有路由会增加很多的配置项,代码实现起来也不难。
最近为公司部署了一套,试用了几天,有几个小问题
在0.14版本的时候,文档会提示被锁定。这个功能非常好。锁定的范围不最好能锁定到tab页的级别,不要锁定到整个项目。
多个人同时编辑接口文档时,在0.14版本的时候通过项目来切分,避免冲突,但是查看接口文档时非常不方便。如果在0.14的基础上,锁定文档能只锁定到tab,使用起来会非常方便。
rap2-delos\scripts\init\index.js
async function main () {
^^^^^^^^
SyntaxError: Unexpected token function
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:542:28)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
初始化之后,运行npm run create-db
脚本并不是根据【/config/config.dev.js】里的配置来运行,而是【/config/config.prod.js】。
如果【/config/config.prod.js】里没有配上生产环境的数据库信息,直接报错如下:
Unable to connect to the database: { SequelizeAccessDeniedError: ER_ACCESS_DENIED_ERROR: Access denied for user 'root'@'localhost' (using password: NO) at Handshake._callback (/Users/coding/rap2/node_modules/sequelize/lib/dialects/mysql/connection-manager.js:83:20) at Handshake.Sequence.end (/Users/coding/rap2/node_modules/mysql/lib/protocol/sequences/Sequence.js:88:24) at Handshake.ErrorPacket (/Users/coding/rap2/node_modules/mysql/lib/protocol/sequences/Handshake.js:132:8) at Protocol._parsePacket (/Users/coding/rap2/node_modules/mysql/lib/protocol/Protocol.js:279:23) at Parser.write (/Users/coding/rap2/node_modules/mysql/lib/protocol/Parser.js:76:12) at Protocol.write (/Users/coding/rap2/node_modules/mysql/lib/protocol/Protocol.js:39:16) at Socket.<anonymous> (/Users/coding/rap2/node_modules/mysql/lib/Connection.js:103:28) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at addChunk (_stream_readable.js:263:12) at readableAddChunk (_stream_readable.js:250:11) at Socket.Readable.push (_stream_readable.js:208:10) at TCP.onread (net.js:594:20) name: 'SequelizeAccessDeniedError', message: 'ER_ACCESS_DENIED_ERROR: Access denied for user \'root\'@\'localhost\' (using password: NO)',
不是很懂node,不知道在哪里可以把这个依赖配置改成对应环境的文件,部署描述也没有细说。
因为同事有外国人,需要使用英文的RAP,不知是否有这个计划么
Rap1的版本管理很好用。用处也非常 大,但在rap2中没有看到,请问这一块有对应 的开发计划 吗?
会增加对外部模拟请求吗?
完成接口开发后,想用rap生成的请求参数,去调用实际地址!这部分功能会增加吗?
登录的时候不要加验证码,或者管理员可配
比如 http://rap2api.taobao.org/app/mock/ xxxx/GET/api/v1/algo/, 我理解这样是为了直接在页面上测试 GET POST 这种 URL,但是程序访问的话 URL 里面是不带这些参数的啊。
模块的定义,相当于是对接口的一个分组管理;那么可不可以添加一个父模块的概念,设计成无限目录分级,提供对模块本身的管理呢?
现在是:项目-模块-接口
修改后是:项目-父父模块-父模块-...-模块-接口
这样还可以避免模块过多的时候,模块标签挤到下一行?
一个项目作为一个系统,如果模块特别多,模块不分组,管理起来就比较麻烦了。
rapV0.14.16 头部会出现广告(阿里云的),找了一圈没找到写的地方,是流量劫持吗?在哪可以修改?
很期待2.0版本的出现
是否有计划支持LDAP/AD或者OAuth,人多了以后不好管……
前面步骤正常, npm run check 也无报错
开发环境:
系统: win7 x64;
node: 8.9.0
npm: 5.5.1
报错日志:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\Program Files\nodejs\node.exe',
1 verbose cli 'C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'dev' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'predev', 'dev', 'postdev' ]
5 info lifecycle [email protected]predev: [email protected]dev: [email protected]
6 info lifecycle [email protected]
7 verbose lifecycle [email protected]dev: unsafe-perm in lifecycle truedev: PATH: C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\rap2\node_modules.bin;C:\Users\53KF\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\local\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\53KF\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Git\cmd;C:\Program Files\nodejs;C:\Program Files\MySQL\MySQL Server 5.7\bin;C:\Users\53KF\AppData\Roaming\npm;C:\Program Files\Git\usr\bin\vendor_perl;C:\Program Files\Git\usr\bin\core_perl
8 verbose lifecycle [email protected]
9 verbose lifecycle [email protected]dev: CWD: C:\rap2dev: Args: [ '/d /s /c',
10 silly lifecycle [email protected]
10 silly lifecycle 'NODE_ENV=development nodemon --watch scripts --watch src scripts/dev.js' ]
11 silly lifecycle [email protected]dev: Returned: code: 1 signal: nulldev: Failed to exec dev script
12 info lifecycle [email protected]
13 verbose stack Error: [email protected] dev: NODE_ENV=development nodemon --watch scripts --watch src scripts/dev.js
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:280:16)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at EventEmitter.emit (events.js:214:7)
13 verbose stack at ChildProcess. (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at ChildProcess.emit (events.js:214:7)
13 verbose stack at maybeClose (internal/child_process.js:925:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
14 verbose pkgid [email protected]
15 verbose cwd C:\rap2
16 verbose Windows_NT 6.1.7601
17 verbose argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "run" "dev"
18 verbose node v8.9.0
19 verbose npm v5.5.1
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] dev: NODE_ENV=development nodemon --watch scripts --watch src scripts/dev.js
22 error Exit status 1
23 error Failed at the [email protected] dev script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
希望进行一下开发计划:
1、不同层级的内容有分颜色显示,类似RAP1的样式;
2、变量含义和备注是否会恢复?现在仅存字段简介可能不是很够用。
3、是否会新增字段是否是必填的选项。
4、模块层级是否会恢复和RAP1一致,可分2级?
5、字段类型是否能和生成规则区分开,主要是:function、regexp
I can not use link like this:
/worker/:id/attendance
Does rap2 not support params in path?
在上一个问题未解决的情况下,我直接执行了
npm run dev
但报如下错误:
Error: listen EADDRINUSE :::8080
at Object._errnoException (util.js:1031:13)
at _exceptionWithHostPort (util.js:1052:20)
at Server.setupListenHandle [as _listen2] (net.js:1367:14)
at listenInCluster (net.js:1408:12)
at Server.listen (net.js:1496:7)
at Application.listen (/usr/local/rap2/node_modules/koa/lib/application.js:64:19)
at start (/usr/local/rap2/scripts/dev.js:8:7)
at Object. (/usr/local/rap2/scripts/dev.js:19:1)
at Module._compile (module.js:641:30)
at Object.Module._extensions..js (module.js:652:10)
at Module.load (module.js:560:32)
at tryModuleLoad (module.js:503:12)
at Function.Module._load (module.js:495:3)
at Function.Module.runMain (module.js:682:10)
at startup (bootstrap_node.js:191:16)
at bootstrap_node.js:613:3
[nodemon] app crashed - waiting for file changes before starting...
看上去是和端口有关,但我在config.dev.js config.local.js config.prod.js 文件里的port都已经改成别的端口了。
在什么地方设置密码呢
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.