forked from ConsoleCatzirl/jenkins-logstash-plugin
-
Notifications
You must be signed in to change notification settings - Fork 108
[JENKINS-38381] Pipeline remote build logging #18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from 32 commits
Commits
Show all changes
53 commits
Select commit
Hold shift + click to select a range
664bd6b
Upgrade the plugin to the latest Parent POM and to 1.625.3 baseline.
oleg-nenashev 3aa94a1
Fix incorrect Javadoc
oleg-nenashev 68a2d1e
Restore injected tests and escape forms by default
oleg-nenashev 8ccd669
Very first prototype of Remote logging from slaves
oleg-nenashev 849c9cd
Workaround JENKINS-38291 - Do not report vars with dots to Elasticsearch
oleg-nenashev bbf3310
Attach unique Job IDs to the reports
oleg-nenashev 679d53e
Hide secret in Logstash.
a7ee24a
Merge branch 'jw-hackaton-remote-logging' of https://github.com/oleg-…
73fed23
Save the progress.
oleg-nenashev 969a7ae
Fix duplicated log messages.
8b23ae2
Pipeline support - Adapt BuildData and LogstashBuildWrapper
oleg-nenashev c0db1ca
KibanaEmbeddedLogAction: Fix symbols in the search query
oleg-nenashev 7511154
Update the core to a Pipeline-compatible version
oleg-nenashev fe66fec
Semi-working Elastic-search based propagation
oleg-nenashev 32db954
Fix the glitch with ArrayOutOfBounds in output
oleg-nenashev abbaadf
Remove debug output
oleg-nenashev 2659d46
Merge branch 'pipeline-support' into jw-hackaton-remote-logging
oleg-nenashev 2168eb0
Merge branch 'web-ui-log-viewer' into jw-hackaton-remote-logging
oleg-nenashev 577d137
BuildData constructor should not fail with NPE when Jenkins instance …
oleg-nenashev b489e23
Ignore BuildData tests broken by Pipeline integration
oleg-nenashev f455aff
Add skeleton implementation for the External logging extension point
oleg-nenashev c301636
Basic support of Console log reporting for Pipeline
oleg-nenashev fe18d32
Fix printing of logs in Elasicsearch-based console
oleg-nenashev a61a7be
Elasticsearch-based console: Also display timestamp
oleg-nenashev 8529515
Elasticsearch-based log: Report real data from the job (via query par…
oleg-nenashev 8b75c99
Restore ConsoleAnnotator code
oleg-nenashev 13bbfab
Add runtime build status balls to External Console Log actions.
oleg-nenashev 2a5f92a
Allow posting logs at same second as the build start
oleg-nenashev 0e502ed
Some fixes for progressive logs in Elasticsearch browser
oleg-nenashev 4bcbe7b
use new LoggingMethod extension point.
2541097
Merge pull request #1 from xyan0607/jw-hackaton-remote-logging
oleg-nenashev 7d92624
[JENKINS-38381] Prototype of using Logstash for a complete Pipeline b…
jglick bd5c9a2
Going back to 2.24 baseline. 2.19.2 would be fine when it comes out.
jglick fcb709f
jitpack, and linking to https://github.com/jenkinsci/maven-hpi-plugin…
jglick e886ea2
Demo sort of working.
jglick 4a089e2
Work even in UTC.
jglick 4d6b55e
Using millisecond granularity in messages, and sorting.
jglick 9b8212f
Make sure source_host is sent.
jglick 977bf05
TODO comment.
jglick 7feaf75
Record the host sending each message, so it is clear which are logged…
jglick e168c03
Finally tracked down the missing-record bug.
jglick 3f66386
Demonstrating password masking.
jglick b5fa447
Showing parallel work.
jglick 9619531
hpi-plugin.version=1.121
jglick 74e4379
Recording demo protocol.
jglick 4f22bd3
getLog should take a long start argument.
jglick 5c4d441
Refresh demo plugins.
jglick 5888222
Giving up on jitpack for now.
jglick d00e7f5
Merge branch 'master' into logs-JENKINS-38381
jglick 40008c9
Updated demo.
jglick 5bb3486
Using updated dependencies, without merging _this_ with master.
jglick b75f573
Updated.
jglick 3b11233
Updating Pipeline deps.
jglick File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
src/main/java/jenkins/plugins/logstash/kibana/AbstractConsoleAction.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/* | ||
* To change this license header, choose License Headers in Project Properties. | ||
* To change this template file, choose Tools | Templates | ||
* and open the template in the editor. | ||
*/ | ||
package jenkins.plugins.logstash.kibana; | ||
|
||
import hudson.model.Action; | ||
import hudson.model.Run; | ||
import jenkins.plugins.logstash.util.UniqueIdHelper; | ||
|
||
/** | ||
* Wrapper base, which is required to nest {@code buildCaption.jelly}. | ||
* @author Oleg Nenashev | ||
*/ | ||
public abstract class AbstractConsoleAction implements Action { | ||
private final String jobId; | ||
private final Run run; | ||
|
||
public AbstractConsoleAction(Run run) { | ||
this.run = run; | ||
this.jobId = UniqueIdHelper.getOrCreateId(run); | ||
} | ||
|
||
@Override | ||
public String getDisplayName() { | ||
return "External log (" + getDataSourceDisplayName() + ")"; | ||
} | ||
|
||
public Run getRun() { | ||
return run; | ||
} | ||
|
||
public String getJobId() { | ||
return jobId; | ||
} | ||
|
||
public boolean isLogUpdated() { | ||
return run.isLogUpdated(); | ||
} | ||
|
||
public abstract String getDataSourceDisplayName(); | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did not care to use a patched core in my case. But, 2.19.1 suffered from JENKINS-35184, making it impossible to connect an agent. Was fixed as of 2.24, I just happened to have 2.26-SNAPSHOT locally.