Quantcast

[jira] [Created] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

classic Classic list List threaded Threaded
35 messages Options
12
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Created] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
Dawid Weiss created LUCENE-4092:
-----------------------------------

             Summary: Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
                 Key: LUCENE-4092
                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
             Project: Lucene - Java
          Issue Type: Sub-task
          Components: general/test
            Reporter: Dawid Weiss
            Priority: Trivial




--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13285981#comment-13285981 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

*Editable Email Notification*/*Default Content* configuration for the {{Lucene-Solr-tests-only-trunk}} job:

{noformat}
Build: ${BUILD_URL}

${FAILED_TESTS}

Build Log (for compile errors):
${BUILD_LOG_REGEX,regex="\\[javac\\]\\s+\\d+ error(s*)\\b",linesBefore=100,linesAfter=0}
{noformat}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13285991#comment-13285991 ]

Dawid Weiss commented on LUCENE-4092:
-------------------------------------

Yeah, but what is ${FAILED_TESTS}? I mean -- can we edit it to detect "<<< FAILURES!" and report 100 lines before this string?
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286026#comment-13286026 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

bq. Yeah, but what is $\{FAILED_TESTS}? I mean -- can we edit it to detect "<<< FAILURES!" and report 100 lines before this string?


{panel:title=Jenkins's *Content Token Reference*}
All arguments are optional. Arguments may be given for each token in the form _name="value"_ for strings and in the form _name=value_ for booleans and numbers.  The \{'s and \}'s may be omitted if there are no arguments.

Examples: $TOKEN, $\{TOKEN}, $\{TOKEN, count=100}, $\{ENV, var="PATH"}

*Available Tokens*

* *$\{DEFAULT_SUBJECT}* - This is the default email subject that is configured in Jenkins's system configuration page.
* *$\{DEFAULT_CONTENT}* -  This is the default email content that is configured in Jenkins's system configuration page.
* *$\{PROJECT_DEFAULT_SUBJECT}* -  This is the default email subject for this project.  The result of using this token in the advanced configuration is what is in the Default Subject field above. WARNING: Do not use this token in the Default Subject or Content fields.  Doing this has an undefined result.
* *$\{PROJECT_DEFAULT_CONTENT}* -  This is the default email content for this project.  The result of using this token in the advanced configuration is what is in the Default Content field above. WARNING: Do not use this token in the Default Subject or Content fields.  Doing this has an undefined result.
* *$\{BUILD_LOG, _maxLines_, _escapeHtml_}* - Displays the end of the build log.
** _maxLines_ - display at most this many lines of the log.\\
Defaults to 250.
** _escapeHtml_ - If true, HTML is escaped.\\
Defaults to false.
* *$\{BUILD_LOG_REGEX, _regex_, _linesBefore_, _linesAfter_, _maxMatches_, _showTruncatedLines_, _substText_, _escapeHtml_, _matchedLineHtmlStyle_}* - Displays lines from the build log that match the regular expression.
** _regex_ - Lines that match this regular expression are included. See also _java.util.regex.Pattern_\\
Defaults to "(?i)\b(error|exception|fatal|fail(ed|ure)|un(defined|resolved))\b".
** _linesBefore_ - The number of lines to include before the matching line. Lines that overlap with another match or _linesAfter_ are only included once.\\
Defaults to 0.
** _linesAfter_ - The number of lines to include after the matching line. Lines that overlap with another match or _linesBefore_ are only included once.\\
Defaults to 0.
** _maxMatches_ - The maximum number of matches to include. If 0, all matches will be included.\\
Defaults to 0.
** _showTruncatedLines_ - If _true_, include {{[...truncated ### lines...]}} lines.\\
Defaults to true.
** _substText_ - If non-null, insert this text into the email rather than the entire line.\\
Defaults to null.
** _escapeHtml_ - If true, escape HTML.\\
Defaults to false.
** _matchedLineHtmlStyle_ - If non-null, output HTML. matched lines will become {{<b style="your-style-value">html escaped matched line</b>}}.\\
Defaults to null.
* *$\{BUILD_LOG_EXCERPT, _start_, _end_}* - Displays an excerpt from the build log.
** _start_ - Regular expression to match the excerpt starting line to be included (exluded). See [_java.util.regex.Pattern_|http://download.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html]
** _end_ - Regular expression to match the excerpt ending line to be included (exluded)
* *$\{BUILD_NUMBER}* - Displays the number of the current build.
* *$\{BUILD_STATUS}* - Displays the status of the current build. (failing, success, etc...)
* *$\{BUILD_URL}* - Displays the URL to the current build.
* *$\{CHANGES, _showPaths_, _showDependencies_, _format_, _pathFormat_}* - Displays the changes since the last build.
** _showDependencies_ - if true, changes to projects this build depends on are shown.\\
Defaults to false.
** _showPaths_ - if true, the paths modified by a commit are shown.\\
Defaults to false.
** _format_ - for each commit listed, a string containing %X, where %X is one of %a for author, %d for date, %m for message, %p for paths, or %r for revision.  Not all revision systems support %d and %r.  If specified, _showPaths_ is ignored.\\
Defaults to "[%a] %m\n".
** _pathFormat_ - a string containing %p to indicate how to print paths.\\
Defaults to "\t%p\n".
* *$\{CHANGES_SINCE_LAST_SUCCESS, _reverse_, _format_, _showPaths_, _changesFormat_, _pathFormat_}* - Displays the changes since the last successful build.
<ul>
** _reverse_ - indicates that most recent builds should be at the top.\\
Defaults to false.
** _format_ - for each build listed, a string containing %X, where %X is one of %c for changes, or %n for build number.\\
Defaults to "Changes for Build #%n\n%c\n".
** _showPaths_, _changesFormat_, _pathFormat_ - defined as _showPaths_, _format_, and _pathFormat_ from $\{CHANGES}, respectively.
* *$\{CHANGES_SINCE_LAST_UNSTABLE, _reverse_, _format_, _showPaths_, _changesFormat_, _pathFormat_}* - Displays the changes since the last unstable or successful build.
** _reverse_ - indicates that most recent builds should be at the top.\\
Defaults to false.
** _format_ - for each build listed, a string containing %X, where %X is one of %c for changes, or %n for build number.\\
Defaults to "Changes for Build #%n\n%c\n".
** _showPaths_, _changesFormat_, _pathFormat_ - defined as _showPaths_, _format_, and _pathFormat_ from $\{CHANGES}, respectively.
* *$\{ENV, _var_}* - Displays an environment variable.
** _var_ - the name of the environment variable to display.  If "", show all.\\
Defaults to "".
* *$\{FAILED_TESTS, _showStack_, _maxTests_}* - Displays failing unit test information, if any tests have failed.
** _showStack_ - indicates that most recent builds should be at the top.\\
Defaults to true.
** _maxTests_ - display at most this many failing tests.\\
No limit is set by default.
* *$\{JENKINS_URL}* - Displays the URL to the Jenkins server. (You can change this on the system configuration page.)
* *$\{HUDSON_URL}* - _*deprecated, please use $JENKINS_URL*_
* *$\{PROJECT_NAME}* - Displays the project's name.
* *$\{PROJECT_URL}* - Displays a URL to the project's page.
* *$\{SVN_REVISION}* - Displays the subversion revision number.
* *$\{CAUSE}* - Displays the cause of the build.
* *$\{JELLY_SCRIPT, _template_}* - Custom message content generated from a Jelly script template. There are two templates provided: "html" and "text". Custom Jelly templates should be placed in $JENKINS_HOME/email-templates. When using custom templates, the template filename without ".jelly" should be used for the "template" argument.
** _template_ - the template name.\\
Defaults to "html".
* *$\{FILE, _path_}* - Includes the content of a specified file.
** _path_ - The path to the file. Relative to the workspace root.
* *$\{TEST_COUNTS, _var_}* - Displays the number of tests.
** _var_ - Defaults to "total".
*** total - the number of all tests.
*** fail - the number of failed tests.
*** skip - the number of skipped tests.
* *$\{SCRIPT, _script_, _template_, _init_}* - Custom message content generated from a script using JSR 223. Custom scripts should be placed in $JENKINS_HOME/email-templates. When using custom scripts, the script filename WITH .py/.rb/etc should be used for the "script" argument.\\
templates and other items may be loaded using the host.readFile(String fileName) function\\
the function will look in the resources for the email-ext plugin first, and then in the $JENKINS_HOME/email-templates directory. No other directories will be searched.
** _script_ - the script name.\\
Defaults to "email-ext.groovy".
** _template_ - the template filename.\\
Defaults to "groovy-html.template"
** _init_ - true to run the language's init script.\\
Defaults to true
** Available Script Engines
*** _ECMAScript_ - 1.8 (js)
*** _Groovy_ - 1.8.5 (groovy)
{panel}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286042#comment-13286042 ]

Dawid Weiss commented on LUCENE-4092:
-------------------------------------

Ok, so BUILD_LOG_REGEX should do! I don't know Jenkins but any failed test (suite) will have the "<<< FAILURES!" marker attached -- feel free to experiment ;)
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286064#comment-13286064 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

I'll switch it to the following - hopefully it will capture everything (any length multiline) between the suite header and "<<< FAILURES!"

{noformat}
Build: ${BUILD_URL}

${FAILED_TESTS}

Build Log (for compile errors):
${BUILD_LOG_REGEX,regex="(?s:\\[java4\\]\\s*Suite:.*?<<<\\s*FAILURES!)"}
{noformat}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286075#comment-13286075 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

bq. regex="(?s:\\[java4\\]\\s*Suite:.*?<<<\\s*FAILURES!)"

Hmm, that won't work - it'll grab everything from the first "Suite:" to "<<< FAILURES!", including any number of (non-failing) Suite mentions inbetween.

I guess "<<< FAILURES!" and 100 previous lines will work, but I'd rather get the exact region.  I'll work on it.

               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286078#comment-13286078 ]

Dawid Weiss commented on LUCENE-4092:
-------------------------------------

This will be a killer regexp, I can feel it ;)
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286086#comment-13286086 ]

Robert Muir commented on LUCENE-4092:
-------------------------------------

Is there also a way we could improve the output of other checks (e.g. the javadocs warnings task, two javadocs checkers in javadocs-lint, and the rat-checker)
so that if it causes a build failure its included as well, rather than just "No tests ran" or "All tests passed" or whatever it does today?
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286088#comment-13286088 ]

Robert Muir commented on LUCENE-4092:
-------------------------------------

By the way: I'm not suggesting to make the regex even more hairy, i'm just wondering if we can modify these tasks
so that when they fail, they can include certain symbols/stuff to ensure they are included in the summary...

               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286106#comment-13286106 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

This one seems to work (from Perl against a recent Jenkins log with a failure):

{noformat}
[^\r\n]*\[junit4\]\s*Suite:.*[\r\n]+[^\r\n]*\[junit4\]\s*(?!Completed)(?!IGNOR)\S(?s:.*?)<<<\s*FAILURES!
{noformat}

I'll change the {{Lucene-Solr-tests-only-trunk}} job configuration to use it (after escaping backslashes).
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286116#comment-13286116 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

{quote}
Is there also a way we could improve the output of other checks (e.g. the javadocs warnings task, two javadocs checkers in javadocs-lint, and the rat-checker)
so that if it causes a build failure its included as well, rather than just "No tests ran" or "All tests passed" or whatever it does today?
{quote}

It may be that alternates can be added to the BUILD_LOG_REGEX - I'll look at the output and see if any changes need to be made to enable that.
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286744#comment-13286744 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

I plan on adding the following (as suggested by Robert) as alternations to the BUILD_LOG_REGEX for all non-Maven Jenkins jobs (some of these things don't run under the Maven jobs, and Maven's output is different enough that it'll require separate treatment):

bq. the javadocs warnings task

{noformat}
(?:[^\r\n]*\[javadoc\].*\r?\n)*[^\r\n]*\[javadoc\]\s*[1-9]\d*\s+warnings.*\r?\n
{noformat}

bq. two javadocs checkers in javadocs-lint

Output from javadocs-lint seems to show up only when there's a problem, so any output from it will always be extracted by the following regex:

{noformat}
[^\r\n]*javadocs-lint:.*\r?\n(?:[^\r\n]*\[echo\].*\r?\n)*
{noformat}

bq. and the rat-checker

{noformat}
[^\r\n]*rat-sources:\s+\[echo\].*(?:\r?\n[^\r\n]*\[echo\].*)*\s*[1-9]\d*\s+Unknown\s+Licenses.*\r?\n(?:[^\r\n]*\[echo\].*\r?\n)*
{noformat}

Along with two others:

# Compilation failures:
{noformat}
(?:[^\r\n]*\[javac\].*\r?\n)*[^\r\n]*\[javac\]\s*[1-9]\d*\s*error.*\r?\n
{noformat}
# Jenkins FATAL errors:
{noformat}
[^\r\n]*FATAL:(?s:.*)
{noformat}

               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286757#comment-13286757 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

bq. I plan on adding the following (as suggested by Robert) as alternations to the BUILD_LOG_REGEX for all non-Maven Jenkins jobs

Done.  Here's the full *Editable Email Notification*/*Default Content* configuration:

{noformat}
Build: ${BUILD_URL}

${FAILED_TESTS}

Build Log:
${BUILD_LOG_REGEX,regex="(?x:
# Compilation failures
(?:[^\\r\\n]*\\[javac\\].*\\r?\\n)*[^\\r\\n]*\\[javac\\]\\s*[1-9]\\d*\\s*error.*\\r?\\n
# Test failures
|[^\\r\\n]*\\[junit4\\]\\s*Suite:.*[\\r\\n]+[^\\r\\n]*\\[junit4\\]\\s*(?!Completed)(?!IGNOR)\\S(?s:.*?)<<<\\s*FAILURES!
# License problems
|[^\\r\\n]*rat-sources:\\s+\\[echo\\].*(?:\\r?\\n[^\\r\\n]*\\[echo\\].*)*\\s*[1-9]\\d*\\s+Unknown\\s+Licenses.*\\r?\\n(?:[^\\r\\n]*\\[echo\\].*\\r?\\n)*
# Javadocs warnings
|(?:[^\\r\\n]*\\[javadoc\\].*\\r?\\n)*[^\\r\\n]*\\[javadoc\\]\\s*[1-9]\\d*\\s+warnings.*\\r?\\n
# Other javadocs problems (broken links and missing javadocs)
|[^\\r\\n]*javadocs-lint:.*\\r?\\n(?:[^\\r\\n]*\\[echo\\].*\\r?\\n)*
# Jenkins problems
|[^\\r\\n]*FATAL:(?s:.*)
)"}
{noformat}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286771#comment-13286771 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

I'm going to add one more to the regex:

{noformat}
# Third-party dependency license/notice problems
|[^\\r\\n]*validate:.*\\r?\\n[^\\r\\n]*\\[echo\\].*\\r?\\n(?:[^\\r\\n]*\\[licenses\\].*\\r?\\n)*[^\\r\\n]*\\[licenses\\].*[1-9]\\d*\\s+error.*\\r?\\n
{noformat}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286774#comment-13286774 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

bq. I'm going to add one more to the regex

Done - added to the configuration on all non-Maven Jenkins jobs
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286794#comment-13286794 ]

Robert Muir commented on LUCENE-4092:
-------------------------------------

awesome! thank you!
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286887#comment-13286887 ]

Dawid Weiss commented on LUCENE-4092:
-------------------------------------

Thanks for working on this, Steve. It'll really be useful.
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286994#comment-13286994 ]

Steven Rowe commented on LUCENE-4092:
-------------------------------------

Two problems:

# Spreading the BUILD_LOG_REGEX regex value over multiple lines is not supported by Jenkins's email templating functionality, which is provided by the Jenkins Email Extension Plugin (email-ext) [https://wiki.jenkins-ci.org/display/JENKINS/Email-ext+plugin].  See [the configuration token parsing regexes in ContentBuilder.Tokenizer|https://github.com/jenkinsci/email-ext-plugin/blob/master/src/main/java/hudson/plugins/emailext/plugins/ContentBuilder.java#L134], in particular the comment over the {{stringRegex}} field:{code:java}// Sequence of (1) not \ " CR LF and (2) \ followed by non line terminator
private static final String stringRegex = "\"([^\\\\\"\\r\\n]|(\\\\.))*\"";{code}
This could be fixed by allowing line terminators to be escaped:{code:java}// Sequence of (1) not \ " CR LF and (2) \ followed by any non-CR/LF character or (CR)LF
private static final String stringRegex = "\"([^\\\\\"\\r\\n]|(\\\\(?:.|\r?\n)))*\"";{code}
I submitted a Jenkins JIRA issue for this: [https://issues.jenkins-ci.org/browse/JENKINS-13976].
# [BuildLogRegexContent, the content parser for BUILD_LOG_REGEX, matches line-by-line|https://github.com/jenkinsci/email-ext-plugin/blob/master/src/main/java/hudson/plugins/emailext/plugins/content/BuildLogRegexContent.java#L213], so regexes targeting multiple lines will fail.  I can see two possible routes to address this:
## The BUILD_LOG_EXCERPT token allows specification of begin/end line regexes, and includes everything inbetween matches.  I'm doubtful this will enable capture of the stuff we want, though.
## I'll try to add an argument to BUILD_LOG_REGEX to enable multi-line content matching, and make a pull request/JIRA issue to get it included in the next release of the plugin.

In the mean time, I'll switch the configuration in our Jenkins jobs to the following:

{noformat}
Build: ${BUILD_URL}

${FAILED_TESTS}

Build Log:
${BUILD_LOG_REGEX,regex="[ \\t]*(?:\\[javac\\]\\s+[1-9]\\d*\\s+error|\\[junit4\\].*<<<\\s+FAILURES!|\\[javadoc\\]\\s+[1-9]\\d*\\s+warning).*",linesBefore=100}
${BUILD_LOG_REGEX,regex="[ \\t]*\\[echo\\].*)*\\s*[1-9]\\d*\\s+Unknown\\s+Licenses.*",linesBefore=17,linesAfter=20}
${BUILD_LOG_REGEX,regex="[ \\t]*javadocs-lint:.*",linesBefore=0,linesAfter=75}
${BUILD_LOG_REGEX,regex=".*FATAL:.*",linesBefore=0,linesAfter=100}
{noformat}
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Commented] (LUCENE-4092) Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/LUCENE-4092?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13287026#comment-13287026 ]

Michael McCandless commented on LUCENE-4092:
--------------------------------------------

Steve you are a regexp God.
               

> Check what's Jenkins pattern for e-mailing log fragments (so that it includes failures).
> ----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-4092
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4092
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

12
Loading...