我有一个Hudson服务器和一个git存储库,它们都在我们的服务器上运行(一个ubuntu机器).
每当我尝试使用哈德森构建我的应用程序时,他都会说
Iniciado pelo usuário anonymous
Checkout:workspace / /usr/share/tomcat6/.hudson/jobs/ECF/workspace - hudson.remoting.LocalChannel@176150c
Using strategy: Default
Checkout:workspace / /usr/share/tomcat6/.hudson/jobs/ECF/workspace - hudson.remoting.LocalChannel@176150c
Fetching changes from the remote Git repository
Fetching upstream changes from ssh://git@192.168.0.10/git/germantech.git
ERROR: Problem fetching from servidor / servidor - could be unavailable. Continuing anyway
ERROR: (Underlying report) : Error performing command: git fetch -t ssh://git@192.168.0.10/git/germantech.git +refs/heads/*:refs/remotes/origin/*
Command "git fetch -t ssh://git@192.168.0.10/git/germantech.git +refs/heads/*:refs/remotes/origin/*" returned status code 128: Host key verification failed.
fatal: The remote end hung up unexpectedly
ERROR: Could not …Run Code Online (Sandbox Code Playgroud) 我正在做这样的转储pg_dump prod-db -U postgres > prod-db.sql,但如果我可以像转储那样pg_dump prod-db -U postgres > prod-db-{date}.sql生成一个类似转储的文件就会很酷prod-db-06-02-13.sql......
我不知道如何开始,也不知道在哪里寻找.任何想法,链接,文档将不胜感激.
我有一台运行正常的Eureka服务器和一台连接它的服务.
现在,我正在尝试将Zuul服务器连接到Eureka,但它无法正常工作.
我像这样配置Zuul:
zuul:
ignoredServices: "*"
routes:
contacts-service:
path: /contacts/**
serviceId: contacts-service
eureka:
instance:
preferIpAddress: true
client:
serviceUrl:
defaultZone: http://eureka:admin@127.0.0.1:8761/eureka/
Run Code Online (Sandbox Code Playgroud)
和我的班级一样
@SpringBootApplication
@EnableZuulServer
@EnableDiscoveryClient
public class EdgeApplication {
public static void main(String[] args) {
SpringApplication.run(EdgeApplication.class, args);
}
}
Run Code Online (Sandbox Code Playgroud)
它永远不会在尤里卡显示出与尤里卡相关的zuul记录.好像我还在遗漏一些东西.
编辑
当我改为时@EnableZuulProxy,我收到一个错误,并且仍然没有在Eureka服务器上显示zuul服务
2016-10-06 23:26:46.574 WARN 8303 --- [nio-8080-exec-3] o.s.c.n.z.filters.post.SendErrorFilter : Error during filtering
com.netflix.zuul.exception.ZuulException: Forwarding error
at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.handleException(RibbonRoutingFilter.java:164) ~[spring-cloud-netflix-core-1.2.0.RELEASE.jar:1.2.0.RELEASE]
at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.forward(RibbonRoutingFilter.java:139) ~[spring-cloud-netflix-core-1.2.0.RELEASE.jar:1.2.0.RELEASE]
at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.run(RibbonRoutingFilter.java:84) ~[spring-cloud-netflix-core-1.2.0.RELEASE.jar:1.2.0.RELEASE]
at com.netflix.zuul.ZuulFilter.runFilter(ZuulFilter.java:112) ~[zuul-core-1.2.2.jar:1.2.2]
at com.netflix.zuul.FilterProcessor.processZuulFilter(FilterProcessor.java:197) ~[zuul-core-1.2.2.jar:1.2.2]
at com.netflix.zuul.FilterProcessor.runFilters(FilterProcessor.java:161) ~[zuul-core-1.2.2.jar:1.2.2]
at com.netflix.zuul.FilterProcessor.route(FilterProcessor.java:120) ~[zuul-core-1.2.2.jar:1.2.2]
at com.netflix.zuul.ZuulRunner.route(ZuulRunner.java:96) …Run Code Online (Sandbox Code Playgroud) 更新到tycho 0.14.0后,我看到这个警告:
[WARNING] Entry: germantechEcfNfe/plugins/org.eclipse.ui.intro.universal_3.2.500.v20110510/themes/slate/graphics/standby/fs_standbyhov.gif longer than 100 characters.
Run Code Online (Sandbox Code Playgroud)
有什么方法可以禁用这种验证吗?
感谢你们
编辑:我的构建没有破坏或什么,但我的日志已满,变得难以阅读输出
我有一个 Spring 启动应用程序,它连接到一个用作缓存的 Redis 实例。当我在开发环境中时,我有以下内容:
---
spring:
profiles: default
redis:
host: localhost
port: 6379
Run Code Online (Sandbox Code Playgroud)
而我的缓存配置类是这样的:
@Configuration
@EnableCaching
public class CacheConfiguration {
@Value("${redis.host}")
String redisHost;
@Value("${redis.port}")
int redisPort;
Run Code Online (Sandbox Code Playgroud)
在生产中,这个应用程序是 Dockerized,我有以下docker-compose.yml文件:
redis:
image: tutum/redis
ports:
- "6379:6379"
volumes:
- /data
app:
build: .
ports:
- "8080:8080"
links:
- redis
Run Code Online (Sandbox Code Playgroud)
这application.yml是:
---
spring:
profiles: docker
redis:
host: redis
port: 6379
Run Code Online (Sandbox Code Playgroud)
要在 Docker 上启动应用程序,我使用 运行-Dspring.profiles.active=docker,但是当应用程序启动时,会发生以下错误:
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private int com.inkdrop.config.cache.CacheConfiguration.redisPort; nested exception is …Run Code Online (Sandbox Code Playgroud) 我有一个带有 Bootstrap 的 Rails 5 应用程序,我用纱线安装了它。我做了以下事情:
yarn add bootstrap
bootstrap@^3.3.7:
version "3.3.7"
resolved "https://registry.yarnpkg.com/bootstrap/-/bootstrap-3.3.7.tgz#5a389394549f23330875a3b150656574f8a9eb71"
Run Code Online (Sandbox Code Playgroud)
在 application.css 上
*= require bootstrap/dist/css/bootstrap
Run Code Online (Sandbox Code Playgroud)
在 application.js 上
//= require bootstrap/dist/js/bootstrap
//= require rails-ujs
//= require @fnando/sparkline/dist/sparkline
//= require_tree .
Run Code Online (Sandbox Code Playgroud)
关于资产.rb
Rails.application.config.assets.paths << Rails.root.join('node_modules')
Rails.application.config.assets.paths << Rails.root.join('node_modules/bootstrap/dist/fonts')
Rails.application.config.assets.precompile << %r{node_modules/bootstrap/dist/fonts/[\w-]+\.(?:eot|svg|ttf|woff2?)$}
Run Code Online (Sandbox Code Playgroud)
尽管如此,当我在生产环境(Heroku)上访问它时,我得到了
ActionController::RoutingError (No route matches [GET] "/fonts/glyphicons-halflings-regular.ttf"):
Run Code Online (Sandbox Code Playgroud)
我$icon-font-path: "node_modules/bootstrap/dist/fonts";也尝试添加到我的 scss 中,但这也不起作用
当我尝试通过Spring Boot amqp连接到这个服务器时,我明白了 com.rabbitmq.client.AuthenticationFailureException: ACCESS_REFUSED - Login was refused using authentication mechanism PLAIN. For details see the broker logfile.
我的配置就是这个
# Message
spring.activemq.broker-url=tcp://127.0.0.1:5672
spring.activemq.user=test
spring.activemq.password=test
Run Code Online (Sandbox Code Playgroud)
是的,用户测试可以在/上访问虚拟主机,是的,我可以在RabbitMQ GUI上使用test/test登录
编辑
看着rabbitmq日志,我看到了这个
{handshake_error,starting,0,
{amqp_error,access_refused,
"PLAIN login refused: user 'guest' - invalid credentials",
'connection.start_ok'}}
Run Code Online (Sandbox Code Playgroud)
看起来Spring似乎无视我的配置并试图与之联系 guest
我想截断整个数据库,同时保持序列同一性。我想出了这样的事情:
WITH tables_to_be_truncated AS (
SELECT table_name
FROM information_schema.tables
WHERE table_type='BASE TABLE'
AND table_schema='public'
AND table_name NOT IN ('admins', 'admin_roles')
)
TRUNCATE TABLE (SELECT table_name FROM tables_to_be_truncated) CONTINUE IDENTITY RESTRICT;
Run Code Online (Sandbox Code Playgroud)
我收到此错误:
ERROR: syntax error at or near "TRUNCATE"
LINE 9: TRUNCATE TABLE (SELECT table_name FROM tables_to_be_truncated...
Run Code Online (Sandbox Code Playgroud)
我确实有权截断表,并且当我运行单个表时,TRUNCATE TABLE access_tokens它工作得很好。
我也尝试过这个
ERROR: syntax error at or near "TRUNCATE"
LINE 9: TRUNCATE TABLE (SELECT table_name FROM tables_to_be_truncated...
Run Code Online (Sandbox Code Playgroud)
但效果不太好。
从我在其他帖子中看到的情况来看,人们正在用函数来做这件事。老实说,我不想走这条路,但如果这是唯一的方法......
我有一个像这样的Procfile:
web: bundle exec unicorn -c config/unicorn.rb -E production
god: god -c services.god
Run Code Online (Sandbox Code Playgroud)
但是foreman start god没有开始...它只是这样说:
17:14:32 god.1 | started with pid 29506
17:14:32 god.1 | exited with code 0
17:14:32 system | sending SIGTERM to all processes
SIGTERM received
Run Code Online (Sandbox Code Playgroud)
如果我跑god -c services.god,所有服务运行良好...
任何想法?
谢谢
if (number < 0) number = (number* -1);
Run Code Online (Sandbox Code Playgroud)
这条线意味着什么,特别是number*,我从来没有见过像java这样的声明,我是新的.
java ×3
postgresql ×2
spring ×2
spring-boot ×2
amqp ×1
backup ×1
docker ×1
dump ×1
dynamic-sql ×1
eclipse-rcp ×1
foreman ×1
git ×1
god ×1
heroku ×1
hudson ×1
linux ×1
netflix-zuul ×1
rabbitmq ×1
ruby ×1
shell ×1
spring-cloud ×1
tomcat ×1
tomcat6 ×1
truncate ×1
tycho ×1
yarnpkg ×1