我正在调试使用React.js的应用程序,Chrome Extensions列表清楚地显示安装了React Developer Tools,当我访问React网站http://facebook.github.io/react/时我可以清楚地看到开发人员工具窗口中的"React"选项卡.然而,当我调试我的应用程序时,我在控制台中看到了这一点:
Download the React DevTools for a better development experience: http://fb.me/react-devtools React.js:87
有人能告诉我如何使用React Developer Tools吗?
谢谢!
Gitlab是一种免费的,开源的托管私有.git
存储库的方式,但它似乎不适用于GoLang.创建项目时,它会生成以下形式的URL:
git@1.2.3.4:private-developers/project.git
Run Code Online (Sandbox Code Playgroud)
哪里:
1.2.3.4
是gitlab服务器的IP地址private-developers
是一个可以访问私人仓库的用户组Golang 1.2.1似乎不理解这种语法.
go get git@1.2.3.4:private-developers/project.git
Run Code Online (Sandbox Code Playgroud)
结果是:
package git@23.251.148.129/project.git: unrecognized import path "git@1.2.3.4/project.git"
Run Code Online (Sandbox Code Playgroud)
有没有办法让这个工作?
我在Firefox 44.0.2浏览器中的http:// localhost:3000上运行了一个ecmascript 7浏览器应用程序.它发布在https://localdev.net:8443上运行的Beego 1.6.0服务器上.'localdev.net'位于同一个框中,并解析为localhost地址.浏览器代码是:
var serverURL = 'https://localdev.net:8443/v1/user/login'
fetch(serverURL, {
method: 'post',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json'
},
mode: 'cors',
cache: 'default',
body: JSON.stringify({username: this.state.username, password: this.state.password})
})
.then(function(response){
if (response.status >= 200 && response.status < 300) {
return Promise.resolve(response)
}
return Promise.reject(new Error(response.statusText))
})
.then(function(data){
console.log('data: ' + data)
})
.catch((err) => console.error(serverURL, err.toString()))
Run Code Online (Sandbox Code Playgroud)
}
beego服务器配置为处理CORS请求,如下所示:
beego.InsertFilter("*", beego.BeforeRouter, cors.Allow(&cors.Options{
AllowOrigins: []string{"*"},
AllowMethods: []string{"*"},
AllowHeaders: []string{"Origin"},
ExposeHeaders: []string{"Content-Length"},
AllowCredentials: true,
}))
Run Code Online (Sandbox Code Playgroud)
Wireshark看到客户端向服务器发送飞行前CORS选项请求:
OPTIONS /v1/user/login …
Run Code Online (Sandbox Code Playgroud) 我正在尝试使用https://github.com/mesos/kafka/tree/master/src/docker#running-image-in-marathon中规定的docker容器启动kafka-mesos框架调度程序,使用Marathon实现在minimesos中运行(我想添加minimesos标签,但没有积分).该应用程序已注册,可以在Marathon控制台中查看,但它仍处于等待状态,而部署GUI则说它正在尝试使用ScaleApplication.
我已经尝试在marathon和mesos-master容器中查找/ var/log文件,这些文件可能会显示为什么会发生这种情况.最初我认为它可能是因为图像没有被拉,所以我添加"forcePullImage": true
到JSON应用程序配置但它仍然等待.我还假设这与http://minimesos.readthedocs.org/en/latest/上的minimesos警告一致,我也将网络从HOST更改为BRIDGE .
在mesos日志中,我确实看到:
I0106 20:07:15.259790 15 master.cpp:4967] Sending 1 offers to framework 5e1508a8-0024-4626-9e0e-5c063f3c78a9-0000 (marathon) at scheduler-575c233a-8bc3-413f-b070-505fcf138ece@172.17.0.6:39111
I0106 20:07:15.266100 9 master.cpp:3300] Processing DECLINE call for offers: [ 5e1508a8-0024-4626-9e0e-5c063f3c78a9-O77 ] for framework 5e1508a8-0024-4626-9e0e-5c063f3c78a9-0000 (marathon) at scheduler-575c233a-8bc3-413f-b070-505fcf138ece@172.17.0.6:39111
I0106 20:07:15.266633 9 hierarchical.hpp:1103] Recovered ports(*):[33000-34000]; cpus(*):1; mem(*):1001; disk(*):13483 (total: ports(*):[33000-34000]; cpus(*):1; mem(*):1001; disk(*):13483, allocated: ) on slave 5e1508a8-0024-4626-9e0e-5c063f3c78a9-S0 from framework 5e1508a8-0024-4626-9e0e-5c063f3c78a9-0000
I0106 20:07:15.266770 9 hierarchical.hpp:1140] Framework 5e1508a8-0024-4626-9e0e-5c063f3c78a9-0000 filtered slave 5e1508a8-0024-4626-9e0e-5c063f3c78a9-S0 for 2mins
I0106 20:07:16.261010 11 hierarchical.hpp:1521] …