[Cruisecontrol] Build result JSP

Source: Internet
Author: User
Tags xsl checkstyle


One build result JSP

The build result JSP is designed to present the result of the build loop of the cruisecontrol. The left side of the page is about whether or not cruisecontrol is building your project, and the link to the previous build is also provided. On the right side of the page is the build result, including compilation errors, test results, and the list of files modified after the previous build.

Build result JSP, for example:


Ii. How does build result JSP work?

JSP uses custom tags to process most of the processes. This separates code from content. Developers only need to modify code without having to care about page design. Designers can concentrate on page layout without having to know any Java code. All fonts and colors are controlled using CSS files, so that all styles can be easily configured in a centralized manner.

The build detail section on the Right of JSP is the HTML generated after the XML log of the cruisecontrol build loop is converted using XSL. The left part of JSP is the HTML generated by the list of log files under the log directory of cruisecontrol. JSP distinguishes the project to which a log belongs based on certain naming rules. JSP generates a specific text file at the start and end of build loop to determine that the current build is running.


Configuration of three build result JSP

1) Build parameters (fromSource codeDuring installation)

We know that the build result JSP page requires the build loop result to be generated.CodeWhen generating JSP, you must specify the following parameters:User. log. dir,User. Build. Status. File, AndCruise. Build. Artifacts. dir.

2) system attributes

The system attribute is used to pass command line parameters between the cruisecontrol process and the report application. The following attributes are: ccname, cruisecontrol. jmxport, cruisecontrol. jmxhost, and cruisecontrol. rmiport.

3) Configure web. xml

JSP reportingProgramUse the context parameter and Servlet initialization parameter to configure and customize. These parameters can be directly modified in Web. xml.

Context parameter:

Cacheroot specifies the directory as the cache for XSL conversion. web context must have the write permission for this directory. If it is not specified, the cache will be saved in the logdir subdirectory called_cache. However, this value is not specified for Binary installation.

Logdir specifies the log directory of the cruisecontrol. In single project mode, logs are directly stored in this directory. If the multi-project mode is used, a subdirectory is created for each project. The default value is the build parameter user. log. dir, but logs is used for Binary installation.

Singleproject specifies whether the cruisecontrol instance processes only one project. The default value is false.

Currentbuildstatusfile specifies the name of the current build status file generated by currentbuildstatuslistener, and the file is located in the log directory of projects. By default, this value is the value specified by the build parameter user. Build. Status. File. But the value for binaryinstallation is status.txt.

Fileservlet. welcomefiles: The indexpage used when the servletcommand displays the viewed contents. You can specify multiple indexpages separated by spaces, for example, index.htmand index.html.

Cruisecontrol. jmxhost specifies the host of JMX httpadaptor.

Cruisecontrol. jmxport specifies the port of JMX httpadaptor.

XSLT. * any parameters starting with XSLT are passed to XSL stylesheets as XSLT parameters.
Servlet parameters:

Rootdir specifies the absolute path of the build binary/Master storage. Logdir is used if no logdir is specified. The default value is the build parameter, which is Cruise. Build. Artifacts. dir. However, artifacts is used when binary is installed.


4) XSLT Parameters

Some XSL stylesheets can be configured using XSLT parameters. These parameters are passed as context parameters, but are prefixed with XSLT. For example, the parameter XSLT. viewcvs. url is used to configure viewcvs. URL.

The top priority of PMD. Warning. threshold is higher than threshod. It will be considered as a warning and the number of reports will be made on the build result page.
Viewcvs. url specifies the URL of viewcvs, which will be used by cvstagdiff. XSL, checkstyle-details.xsl and pmd-details.xsl, not specified by default.
Cvstagdiff. Success. Show specifies whether different viewcvs reports are displayed when build is successful. By default, only the change Report of broken build is displayed.
Checkstyle. Hide. Warnings specifies whether checkstyle errors or all checkstyle errors and warnings should be displayed on the build results page. If it is set to true, no warning is displayed. All errors and warnings are displayed by default. This parameter is not specified by default.




Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.