Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Jenkins 中文社区
Simplified Chinese Plugin
提交
41e3a130
S
Simplified Chinese Plugin
项目概览
Jenkins 中文社区
/
Simplified Chinese Plugin
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
Simplified Chinese Plugin
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
41e3a130
编写于
8月 31, 2018
作者:
JenkinsInChina
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
modify git ignore
上级
67b555b2
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
85 addition
and
3 deletion
+85
-3
.gitignore
.gitignore
+7
-1
src/main/java/hudson/plugins/localization/I18nDispatcher.java
...main/java/hudson/plugins/localization/I18nDispatcher.java
+1
-0
src/main/java/hudson/plugins/localization/I18nRequestDispatcher.java
...va/hudson/plugins/localization/I18nRequestDispatcher.java
+21
-1
src/main/java/hudson/plugins/localization/LocalizationFacet.java
...n/java/hudson/plugins/localization/LocalizationFacet.java
+6
-1
src/main/java/hudson/plugins/localization/abcDispatcher.java
src/main/java/hudson/plugins/localization/abcDispatcher.java
+10
-0
src/main/resources/hudson/model/AbstractProject/help-concurrentBuild.html
...es/hudson/model/AbstractProject/help-concurrentBuild.html
+39
-0
src/main/resources/hudson/model/FreeStyleProject/help_zh_CN.html
...n/resources/hudson/model/FreeStyleProject/help_zh_CN.html
+1
-0
未找到文件。
.gitignore
浏览文件 @
41e3a130
**/*.iml
**/*.iml
idea
.idea
.DS_Store
# maven stuff
target
target
# jenkins stuff
work
src/main/java/hudson/plugins/localization/I18nDispatcher.java
浏览文件 @
41e3a130
...
@@ -12,6 +12,7 @@ public class I18nDispatcher extends Dispatcher {
...
@@ -12,6 +12,7 @@ public class I18nDispatcher extends Dispatcher {
@Override
@Override
public
boolean
dispatch
(
RequestImpl
req
,
ResponseImpl
rsp
,
Object
node
)
throws
IOException
,
ServletException
,
IllegalAccessException
,
InvocationTargetException
{
public
boolean
dispatch
(
RequestImpl
req
,
ResponseImpl
rsp
,
Object
node
)
throws
IOException
,
ServletException
,
IllegalAccessException
,
InvocationTargetException
{
if
(
req
.
getOriginalRequestURI
().
endsWith
(
"help"
))
{
if
(
req
.
getOriginalRequestURI
().
endsWith
(
"help"
))
{
// new I18nRequestDispatcher().forward(req.getRequest(), rsp.getResponse());
return
true
;
return
true
;
}
}
...
...
src/main/java/hudson/plugins/localization/I18nRequestDispatcher.java
浏览文件 @
41e3a130
package
hudson.plugins.localization
;
package
hudson.plugins.localization
;
import
org.kohsuke.stapler.RequestImpl
;
import
org.kohsuke.stapler.lang.Klass
;
import
javax.servlet.RequestDispatcher
;
import
javax.servlet.RequestDispatcher
;
import
javax.servlet.ServletException
;
import
javax.servlet.ServletException
;
import
javax.servlet.ServletRequest
;
import
javax.servlet.ServletRequest
;
...
@@ -7,9 +10,26 @@ import javax.servlet.ServletResponse;
...
@@ -7,9 +10,26 @@ import javax.servlet.ServletResponse;
import
java.io.IOException
;
import
java.io.IOException
;
public
class
I18nRequestDispatcher
implements
RequestDispatcher
{
public
class
I18nRequestDispatcher
implements
RequestDispatcher
{
private
RequestImpl
request
;
private
Klass
<?>
type
;
private
Object
it
;
private
String
viewName
;
public
I18nRequestDispatcher
(
RequestImpl
request
,
Klass
<?>
type
,
Object
it
,
String
viewName
)
{
this
.
request
=
request
;
this
.
type
=
type
;
this
.
it
=
it
;
this
.
viewName
=
viewName
;
}
@Override
@Override
public
void
forward
(
ServletRequest
servletRequest
,
ServletResponse
servletResponse
)
throws
ServletException
,
IOException
{
public
void
forward
(
ServletRequest
req
,
ServletResponse
servletResponse
)
throws
ServletException
,
IOException
{
System
.
out
.
println
(
"forward"
);
System
.
out
.
println
(
"forward"
);
String
path
=
this
.
request
.
getOriginalRestOfPath
();
String
uri
=
this
.
request
.
getOriginalRequestURI
();
// this.getClass().getResource("/hudson/model/FreeStyleProject/help_zh_CN.html").openStream() == null
servletResponse
.
getWriter
().
println
(
"sff"
);
// /jenkins/descriptor/hudson.model.FreeStyleProject/help/concurrentBuild
}
}
@Override
@Override
...
...
src/main/java/hudson/plugins/localization/LocalizationFacet.java
浏览文件 @
41e3a130
...
@@ -17,7 +17,12 @@ public class LocalizationFacet extends Facet {
...
@@ -17,7 +17,12 @@ public class LocalizationFacet extends Facet {
@Override
@Override
public
RequestDispatcher
createRequestDispatcher
(
RequestImpl
request
,
Klass
<?>
type
,
Object
it
,
String
viewName
)
throws
IOException
{
public
RequestDispatcher
createRequestDispatcher
(
RequestImpl
request
,
Klass
<?>
type
,
Object
it
,
String
viewName
)
throws
IOException
{
return
super
.
createRequestDispatcher
(
request
,
type
,
it
,
viewName
);
RequestDispatcher
dispatcher
=
super
.
createRequestDispatcher
(
request
,
type
,
it
,
viewName
);
if
(
dispatcher
==
null
)
{
// dispatcher = new I18nRequestDispatcher(request, type, it, viewName);
}
return
dispatcher
;
}
}
@Override
@Override
...
...
src/main/java/hudson/plugins/localization/abcDispatcher.java
0 → 100644
浏览文件 @
41e3a130
//package hudson.plugins.localization;
//
//import org.apache.commons.jelly.Script;
//import org.kohsuke.stapler.jelly.JellyRequestDispatcher;
//
//public class abcDispatcher extends JellyRequestDispatcher {
// public abcDispatcher(Object it, Script script) {
// super(it, script);
// }
//}
src/main/resources/hudson/model/AbstractProject/help-concurrentBuild.html
0 → 100644
浏览文件 @
41e3a130
111
<div>
When this option is checked, multiple builds of this project may be executed
in parallel.
<p>
By default, only a single build of a project is executed at a time
—
any
other requests to start building that project will remain in the build queue
until the first build is complete.
<br>
This is a safe default, as projects can often require exclusive access to
certain resources, such as a database, or a piece of hardware.
<p>
But with this option enabled, if there are enough build executors available
that can handle this project, then multiple builds of this project will take
place in parallel. If there are not enough available executors at any point,
any further build requests will be held in the build queue as normal.
<p>
Enabling concurrent builds is useful for projects that execute lengthy test
suites, as it allows each build to contain a smaller number of changes, while
the total turnaround time decreases as subsequent builds do not need to wait
for previous test runs to complete.
<br>
This feature is also useful for parameterized projects, whose individual build
executions
—
depending on the parameters used
—
can be
completely independent from one another.
<p>
Each concurrently executed build occurs in its own build workspace, isolated
from any other builds. By default, Jenkins appends "
<tt>
@
<
num
>
</tt>
" to
the workspace directory name, e.g. "
<tt>
@2
</tt>
".
<br>
The separator "
<tt>
@
</tt>
" can be changed by setting the
<tt>
hudson.slaves.WorkspaceList
</tt>
Java system property when starting
Jenkins. For example, "
<tt>
hudson.slaves.WorkspaceList=-
</tt>
" would change
the separator to a hyphen.
<br>
For more information on setting system properties, see the
<a
href=
"https://jenkins.io/redirect/setting-system-properties"
target=
"_blank"
>
wiki page
</a>
.
<p>
However, if you enable the
<i>
Use custom workspace
</i>
option, all builds will
be executed in the same workspace. Therefore caution is required, as multiple
builds may end up altering the same directory at the same time.
</div>
src/main/resources/hudson/model/FreeStyleProject/help_zh_CN.html
0 → 100644
浏览文件 @
41e3a130
sdfsf
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录