SlideShare una empresa de Scribd logo
1 de 28
Descargar para leer sin conexión
27 au 29 mars 2013Vincent Massol, Nov 2017
Creating your own project’s
Quality Dashboard
Agenda
• Why XWiki?
• Quality metrics to monitor
• Storing data in the wiki
• Caching to improve performance
• Send email on conditions
• Custom skin
• Q&A
Let’s do this live!
Why XWiki?
• A wiki but more importantly a web dev platform
• Reusing existing building blocks instead of starting from scratch
• Live site and thus easy to test
• Will use the following features of XWiki
• Scripting (especially Groovy)
• Graph Macro
• Dashboard Macro
• Scheduler feature
• JIRA Macro
• GitHub Stats Application
• L&F customisation
• And more (authentication,
permissions, etc)
Quality metrics to monitor
• Context: Java development project
• Goal: Create a dashboard to monitor the following metrics
• Number of tests (from Jenkins)
• Number of code bugs (from SonarQube)
• Open Blocker issues from the issue tracker (from JIRA)
• (for fun) Committer stats (from GitHub)
27 au 29 mars 2013
Number of Tests
Jenkins Integration
Number of tests - Retrieval
• Using Jenkins REST API
{{groovy}}
def url = 'http://ci.xwiki.org/job/xwiki-commons/
lastSuccessfulBuild/testReport/api/xml?
pretty=true&depth=-1'.toURL().text
def root = new XmlSlurper().parseText(url)
println "Tests for XWiki Commons: ${root.totalCount}"
{{/groovy}}
Demo
Storing Data locally
• Why?
• Performance reasons for viewing collected data
• Ability to graph evolution of metrics
• How?
• Create data structure (XClass)
• Script to import data from remote sites and store them in wiki pages
(XObjects = instances of XClass)
• Scheduler job to run it every day (for example)
Number of tests - Our goal
Number of tests - Class & Objects
Number of tests - Storing code
{{groovy}}
def url = 'http://ci.xwiki.org/job/xwiki-commons/lastSuccessfulBuild/testReport/api/xml?
pretty=true&depth=-1'.toURL().text
def root = new XmlSlurper().parseText(url)
def count = root.totalCount
// Compute new doc name
def countQuery = 'from doc.object(Quality.Jenkins.TestNumberClass) as record'
def recordCount = services.query.xwql(countQuery).count()
def newRecordReference = "Quality.Jenkins.Data.Count${recordCount + 1}"
// Only create a new record if none exist for today's date
def date = new Date()
date.clearTime()
def existQuery = 'from doc.object(Quality.Jenkins.TestNumberClass) as record where record.date
= :date'
def todayCount = services.query.xwql(existQuery).bindValue('date', date).count()
if (todayCount == 0) {
def recordDoc = xwiki.getDocument(newRecordReference)
def object = recordDoc.newObject('Quality.Jenkins.TestNumberClass')
object.set('date', date.format('dd/MM/yyyy'))
object.set('count', count.text())
recordDoc.save()
}
{{/groovy}}
Demo
Graph Macro
Number of tests - Graphing
{{groovy}}
def labels = []
def values = []
def records = services.query.xwql('select record.date, record.count, doc.fullName from Document
doc, doc.object(Quality.Jenkins.TestNumberClass) as record order by record.date').execute()
records.each() {
labels.add(it[0].toString().split(' ')[0])
values.add(it[1])
}
println '{{chartjs type="line"}}'
println '{'
println " "labels": [${labels.collect{'"' + it + '"'}.join(',')}],"
println " "datasets": [{"data": [${values.join(',')}]}]"
println '}'
println '{{/chartjs}}'
{{/groovy}}
Demo
Number of tests - Scheduler Demo
Dashboard
• Dashboard Macro
{{dashboard/}}
Demo
27 au 29 mars 2013
Code bugs
SonarQube Integration
Code bugs - Retrieval
• Using SonarQube REST API
{{groovy}}
import groovy.json.JsonSlurper
def url = 'https://sonarcloud.io/api/issues/search?
componentRoots=org.xwiki.commons%3Axwiki-
commons&types=BUG&statuses=OPEN'.toURL().text
def root = new JsonSlurper().parseText(url)
println '|=Severity|=Component|=Message|=Line'
root.issues.each() { issue ->
println "|${issue.severity}|${issue.project} - $
{issue.subProject} - $
{StringUtils.substringAfterLast(issue.component, '/')}|$
{issue.message}|${issue.line}"
}
{{/groovy}}
Demo
Code bugs - Results
Cache Macro
{{cache id="bugs" timeToLive="86400"}}
{{groovy}}
...
{{/groovy}}
{{/cache}}
• Example: cache of one day
Demo
Code bugs - Dashboard Demo
Send mail on condition
• Example: Send mail when # bugs > 10
• Using a Scheduler job for example or when fetching data
{{groovy}}
[…]
if (root.issues.size() >= 10) {
def message = services.mailsender.createMessage(
"vincent@massol.net", "Alert: too many bugs!")
message.addPart("text/plain", "text content")
services.mailsender.send([message], 'database')
}
{{/groovy}}
27 au 29 mars 2013
Tracker Issues
JIRA Integration
Tracker Issues - JIRA Macro
• Using XWiki’s JIRA Macro
{{jira id="xwikiorg" style="table" source="jql"}}
category = 10000 AND priority = blocker AND resolution = open
{{/jira}}
Tracker Issues - Dashboard
27 au 29 mars 2013
Commit Stats
GitHub Integration
Commit Stats
• Using XWiki’s GitHub Stats
Application
{{committers since="365" repositories="xwiki/*"
contributors="true" inactives="false" type="list"/}}
Full Dashboard
Custom Skin
Q&A
• Going further: http://xwiki.org
Me

Más contenido relacionado

La actualidad más candente

Ciklum net sat12112011-roman bugaev-windows azure technology cocktail
Ciklum net sat12112011-roman bugaev-windows azure technology cocktailCiklum net sat12112011-roman bugaev-windows azure technology cocktail
Ciklum net sat12112011-roman bugaev-windows azure technology cocktail
Ciklum Ukraine
 
Google apps script database abstraction exposed version
Google apps script database abstraction   exposed versionGoogle apps script database abstraction   exposed version
Google apps script database abstraction exposed version
Bruce McPherson
 

La actualidad más candente (11)

Linq
LinqLinq
Linq
 
BizSpark SF Lightning Talk: "Automated Testing (Unit, Integration and Systems...
BizSpark SF Lightning Talk: "Automated Testing (Unit, Integration and Systems...BizSpark SF Lightning Talk: "Automated Testing (Unit, Integration and Systems...
BizSpark SF Lightning Talk: "Automated Testing (Unit, Integration and Systems...
 
Icinga2 api use cases
Icinga2 api use casesIcinga2 api use cases
Icinga2 api use cases
 
final
finalfinal
final
 
Ciklum net sat12112011-roman bugaev-windows azure technology cocktail
Ciklum net sat12112011-roman bugaev-windows azure technology cocktailCiklum net sat12112011-roman bugaev-windows azure technology cocktail
Ciklum net sat12112011-roman bugaev-windows azure technology cocktail
 
Docker & Azure
Docker & AzureDocker & Azure
Docker & Azure
 
Cloud Abstraction Libraries: Implementation and Comparison
Cloud Abstraction Libraries: Implementation and ComparisonCloud Abstraction Libraries: Implementation and Comparison
Cloud Abstraction Libraries: Implementation and Comparison
 
Liquid Stream Processing Across Web Browsers and Web Servers
Liquid Stream Processing Across Web Browsers and Web ServersLiquid Stream Processing Across Web Browsers and Web Servers
Liquid Stream Processing Across Web Browsers and Web Servers
 
Google apps script database abstraction exposed version
Google apps script database abstraction   exposed versionGoogle apps script database abstraction   exposed version
Google apps script database abstraction exposed version
 
BigQuery JavaScript User-Defined Functions by THOMAS PARK and FELIPE HOFFA at...
BigQuery JavaScript User-Defined Functions by THOMAS PARK and FELIPE HOFFA at...BigQuery JavaScript User-Defined Functions by THOMAS PARK and FELIPE HOFFA at...
BigQuery JavaScript User-Defined Functions by THOMAS PARK and FELIPE HOFFA at...
 
Sprint 85
Sprint 85Sprint 85
Sprint 85
 

Similar a Creating your own project's Quality Dashboard

Similar a Creating your own project's Quality Dashboard (20)

Intellias CQRS Framework
Intellias CQRS FrameworkIntellias CQRS Framework
Intellias CQRS Framework
 
Improving Your Selenium WebDriver Tests - Belgium testing days_2016
Improving Your Selenium WebDriver Tests - Belgium testing days_2016Improving Your Selenium WebDriver Tests - Belgium testing days_2016
Improving Your Selenium WebDriver Tests - Belgium testing days_2016
 
Surviving UI Automation Armageddon with BELLATRIX.pptx
Surviving UI Automation Armageddon with BELLATRIX.pptxSurviving UI Automation Armageddon with BELLATRIX.pptx
Surviving UI Automation Armageddon with BELLATRIX.pptx
 
Docker & ECS: Secure Nearline Execution
Docker & ECS: Secure Nearline ExecutionDocker & ECS: Secure Nearline Execution
Docker & ECS: Secure Nearline Execution
 
How to use the new Domino Query Language
How to use the new Domino Query LanguageHow to use the new Domino Query Language
How to use the new Domino Query Language
 
Quick start with AngularJS
Quick start with AngularJSQuick start with AngularJS
Quick start with AngularJS
 
Web based automation testing on Node.js environment
Web based automation testing on Node.js environmentWeb based automation testing on Node.js environment
Web based automation testing on Node.js environment
 
Interactive Kafka Streams
Interactive Kafka StreamsInteractive Kafka Streams
Interactive Kafka Streams
 
Building XWiki
Building XWikiBuilding XWiki
Building XWiki
 
Learning with F#
Learning with F#Learning with F#
Learning with F#
 
Exploring an API with Blocks
Exploring an API with BlocksExploring an API with Blocks
Exploring an API with Blocks
 
Take Control of your Integration Testing with TestContainers
Take Control of your Integration Testing with TestContainersTake Control of your Integration Testing with TestContainers
Take Control of your Integration Testing with TestContainers
 
Geek Sync I Learn to Troubleshoot Query Performance in Analysis Services
Geek Sync I Learn to Troubleshoot Query Performance in Analysis ServicesGeek Sync I Learn to Troubleshoot Query Performance in Analysis Services
Geek Sync I Learn to Troubleshoot Query Performance in Analysis Services
 
jQuery On Rails
jQuery On RailsjQuery On Rails
jQuery On Rails
 
WinAppDriver Development
WinAppDriver DevelopmentWinAppDriver Development
WinAppDriver Development
 
Introduction to Django
Introduction to DjangoIntroduction to Django
Introduction to Django
 
Protractor Tutorial Quality in Agile 2015
Protractor Tutorial Quality in Agile 2015Protractor Tutorial Quality in Agile 2015
Protractor Tutorial Quality in Agile 2015
 
J query module1
J query module1J query module1
J query module1
 
MSFT Dumaguete 061616 - Building High Performance Apps
MSFT Dumaguete 061616 - Building High Performance AppsMSFT Dumaguete 061616 - Building High Performance Apps
MSFT Dumaguete 061616 - Building High Performance Apps
 
What's new in the July 2017 Update for Dynamics 365 - Developer features
What's new in the July 2017 Update for Dynamics 365 - Developer featuresWhat's new in the July 2017 Update for Dynamics 365 - Developer features
What's new in the July 2017 Update for Dynamics 365 - Developer features
 

Más de Vincent Massol

XWiki: wiki collaboration as an alternative to Confluence and Sharepoint
XWiki: wiki collaboration as an alternative to Confluence and SharepointXWiki: wiki collaboration as an alternative to Confluence and Sharepoint
XWiki: wiki collaboration as an alternative to Confluence and Sharepoint
Vincent Massol
 

Más de Vincent Massol (20)

XWiki Testing with TestContainers
XWiki Testing with TestContainersXWiki Testing with TestContainers
XWiki Testing with TestContainers
 
Advanced Java Testing @ POSS 2019
Advanced Java Testing @ POSS 2019Advanced Java Testing @ POSS 2019
Advanced Java Testing @ POSS 2019
 
New types of tests for Java projects
New types of tests for Java projectsNew types of tests for Java projects
New types of tests for Java projects
 
Configuration Testing with Docker & TestContainers
Configuration Testing with Docker & TestContainersConfiguration Testing with Docker & TestContainers
Configuration Testing with Docker & TestContainers
 
New types of tests for Java projects
New types of tests for Java projectsNew types of tests for Java projects
New types of tests for Java projects
 
What's new in XWiki 9.x and 10.x
What's new in XWiki 9.x and 10.xWhat's new in XWiki 9.x and 10.x
What's new in XWiki 9.x and 10.x
 
QDashboard 1.2
QDashboard 1.2QDashboard 1.2
QDashboard 1.2
 
XWiki: wiki collaboration as an alternative to Confluence and Sharepoint
XWiki: wiki collaboration as an alternative to Confluence and SharepointXWiki: wiki collaboration as an alternative to Confluence and Sharepoint
XWiki: wiki collaboration as an alternative to Confluence and Sharepoint
 
Leading a Community-Driven Open Source Project
Leading a Community-Driven Open Source ProjectLeading a Community-Driven Open Source Project
Leading a Community-Driven Open Source Project
 
Developing XWiki
Developing XWikiDeveloping XWiki
Developing XWiki
 
XWiki Status - July 2015
XWiki Status - July 2015XWiki Status - July 2015
XWiki Status - July 2015
 
XWiki SAS development practices
XWiki SAS development practicesXWiki SAS development practices
XWiki SAS development practices
 
XWiki SAS: An open source company
XWiki SAS: An open source companyXWiki SAS: An open source company
XWiki SAS: An open source company
 
XWiki: A web dev runtime for writing web apps @ FOSDEM 2014
XWiki: A web dev runtime for writing web apps @ FOSDEM 2014XWiki: A web dev runtime for writing web apps @ FOSDEM 2014
XWiki: A web dev runtime for writing web apps @ FOSDEM 2014
 
XWiki Rendering @ FOSDEM 2014
XWiki Rendering @ FOSDEM 2014XWiki Rendering @ FOSDEM 2014
XWiki Rendering @ FOSDEM 2014
 
Implementing Quality on a Java Project
Implementing Quality on a Java ProjectImplementing Quality on a Java Project
Implementing Quality on a Java Project
 
Implementing Quality on Java projects (Short version)
Implementing Quality on Java projects (Short version)Implementing Quality on Java projects (Short version)
Implementing Quality on Java projects (Short version)
 
Implementing quality in Java projects
Implementing quality in Java projectsImplementing quality in Java projects
Implementing quality in Java projects
 
Implementing Quality on Java projects
Implementing Quality on Java projectsImplementing Quality on Java projects
Implementing Quality on Java projects
 
Combining open source ethics with private interests
Combining open source ethics with private interestsCombining open source ethics with private interests
Combining open source ethics with private interests
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Último (20)

Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 

Creating your own project's Quality Dashboard

  • 1. 27 au 29 mars 2013Vincent Massol, Nov 2017 Creating your own project’s Quality Dashboard
  • 2. Agenda • Why XWiki? • Quality metrics to monitor • Storing data in the wiki • Caching to improve performance • Send email on conditions • Custom skin • Q&A Let’s do this live!
  • 3. Why XWiki? • A wiki but more importantly a web dev platform • Reusing existing building blocks instead of starting from scratch • Live site and thus easy to test • Will use the following features of XWiki • Scripting (especially Groovy) • Graph Macro • Dashboard Macro • Scheduler feature • JIRA Macro • GitHub Stats Application • L&F customisation • And more (authentication, permissions, etc)
  • 4. Quality metrics to monitor • Context: Java development project • Goal: Create a dashboard to monitor the following metrics • Number of tests (from Jenkins) • Number of code bugs (from SonarQube) • Open Blocker issues from the issue tracker (from JIRA) • (for fun) Committer stats (from GitHub)
  • 5. 27 au 29 mars 2013 Number of Tests Jenkins Integration
  • 6. Number of tests - Retrieval • Using Jenkins REST API {{groovy}} def url = 'http://ci.xwiki.org/job/xwiki-commons/ lastSuccessfulBuild/testReport/api/xml? pretty=true&depth=-1'.toURL().text def root = new XmlSlurper().parseText(url) println "Tests for XWiki Commons: ${root.totalCount}" {{/groovy}} Demo
  • 7. Storing Data locally • Why? • Performance reasons for viewing collected data • Ability to graph evolution of metrics • How? • Create data structure (XClass) • Script to import data from remote sites and store them in wiki pages (XObjects = instances of XClass) • Scheduler job to run it every day (for example)
  • 8. Number of tests - Our goal
  • 9. Number of tests - Class & Objects
  • 10. Number of tests - Storing code {{groovy}} def url = 'http://ci.xwiki.org/job/xwiki-commons/lastSuccessfulBuild/testReport/api/xml? pretty=true&depth=-1'.toURL().text def root = new XmlSlurper().parseText(url) def count = root.totalCount // Compute new doc name def countQuery = 'from doc.object(Quality.Jenkins.TestNumberClass) as record' def recordCount = services.query.xwql(countQuery).count() def newRecordReference = "Quality.Jenkins.Data.Count${recordCount + 1}" // Only create a new record if none exist for today's date def date = new Date() date.clearTime() def existQuery = 'from doc.object(Quality.Jenkins.TestNumberClass) as record where record.date = :date' def todayCount = services.query.xwql(existQuery).bindValue('date', date).count() if (todayCount == 0) { def recordDoc = xwiki.getDocument(newRecordReference) def object = recordDoc.newObject('Quality.Jenkins.TestNumberClass') object.set('date', date.format('dd/MM/yyyy')) object.set('count', count.text()) recordDoc.save() } {{/groovy}} Demo
  • 12. Number of tests - Graphing {{groovy}} def labels = [] def values = [] def records = services.query.xwql('select record.date, record.count, doc.fullName from Document doc, doc.object(Quality.Jenkins.TestNumberClass) as record order by record.date').execute() records.each() { labels.add(it[0].toString().split(' ')[0]) values.add(it[1]) } println '{{chartjs type="line"}}' println '{' println " "labels": [${labels.collect{'"' + it + '"'}.join(',')}]," println " "datasets": [{"data": [${values.join(',')}]}]" println '}' println '{{/chartjs}}' {{/groovy}} Demo
  • 13. Number of tests - Scheduler Demo
  • 15. 27 au 29 mars 2013 Code bugs SonarQube Integration
  • 16. Code bugs - Retrieval • Using SonarQube REST API {{groovy}} import groovy.json.JsonSlurper def url = 'https://sonarcloud.io/api/issues/search? componentRoots=org.xwiki.commons%3Axwiki- commons&types=BUG&statuses=OPEN'.toURL().text def root = new JsonSlurper().parseText(url) println '|=Severity|=Component|=Message|=Line' root.issues.each() { issue -> println "|${issue.severity}|${issue.project} - $ {issue.subProject} - $ {StringUtils.substringAfterLast(issue.component, '/')}|$ {issue.message}|${issue.line}" } {{/groovy}} Demo
  • 17. Code bugs - Results
  • 18. Cache Macro {{cache id="bugs" timeToLive="86400"}} {{groovy}} ... {{/groovy}} {{/cache}} • Example: cache of one day Demo
  • 19. Code bugs - Dashboard Demo
  • 20. Send mail on condition • Example: Send mail when # bugs > 10 • Using a Scheduler job for example or when fetching data {{groovy}} […] if (root.issues.size() >= 10) { def message = services.mailsender.createMessage( "vincent@massol.net", "Alert: too many bugs!") message.addPart("text/plain", "text content") services.mailsender.send([message], 'database') } {{/groovy}}
  • 21. 27 au 29 mars 2013 Tracker Issues JIRA Integration
  • 22. Tracker Issues - JIRA Macro • Using XWiki’s JIRA Macro {{jira id="xwikiorg" style="table" source="jql"}} category = 10000 AND priority = blocker AND resolution = open {{/jira}}
  • 23. Tracker Issues - Dashboard
  • 24. 27 au 29 mars 2013 Commit Stats GitHub Integration
  • 25. Commit Stats • Using XWiki’s GitHub Stats Application {{committers since="365" repositories="xwiki/*" contributors="true" inactives="false" type="list"/}}
  • 28. Q&A • Going further: http://xwiki.org Me