]> git.donarmstrong.com Git - debbugs-presentations.git/blob - debbugs.Rnw
make the open logo smaller
[debbugs-presentations.git] / debbugs.Rnw
1
2 \usepackage{fontspec}
3 \setmainfont{FreeSerif}
4 \setsansfont{FreeSans}
5 \setmonofont{FreeMono}
6 \usepackage{url}
7 \usepackage{fancyhdr}
8 \usepackage{graphicx}
9 \usepackage[bf]{caption}
10 \usepackage{rotating}
11 \usepackage{wrapfig}
12 \usepackage{fancybox}
13 \usepackage{booktabs}
14 % \usepackage{multirow}
15 \usepackage{acronym}
16 \usepackage{qrcode}
17 \usepackage[backend=biber,natbib=true,hyperref=true,style=nature]{biblatex}
18 \addbibresource{references.bib}
19 % \usepackage[nomargin,inline,draft]{fixme}
20 % \newcommand{\DLA}[1]{\textcolor{red}{\fxnote{DLA: #1}}}
21 % \usepackage[hyperfigures,bookmarks,colorlinks,citecolor=black,filecolor=black,linkcolor=black,urlcolor=black]{hyperref}
22 \usepackage{texshade}
23 \usepackage{tikz}
24 \usepackage{nameref}
25 \usepackage{zref-xr,zref-user}
26 \renewcommand*{\bibfont}{\tiny}
27 \usepackage[absolute,overlay]{textpos}
28
29 \mode<presentation>
30 {
31   \usetheme{Montpellier}
32   %\useoutertheme[hideallsubsections]{debiansidebar}
33 %  \setbeamercovered{transparent}  
34 }
35
36
37 \usepackage[nomargin,inline,draft]{fixme}
38 \usepackage{listings}
39
40
41 \logo{\begin{tikzpicture}% Pale figure
42     {\node[opacity=0.3] {\includegraphics[width=2cm,keepaspectratio]{figures/openlogo-crop.pdf}};}%
43     \end{tikzpicture}}
44 \author{Don Armstrong}
45 \title{Debbugs}
46 \subtitle{Database Ho!}
47 %\date{August 11th, 2008}
48 \titlegraphic{\includegraphics[height=0.2\textheight,keepaspectratio]{figures/openlogo-crop.pdf}}
49 \subject{BTS}
50
51 % State of the BTS: new features, changes and tips
52
53 % The bug tracking system is where all bugs that affect Debian are
54 % filed. New features, including the affects, summary, and local debbugs
55 % mirror will be presented and demonstrated. Some of the underlying
56 % architectural changes to the codebase in debbugs to make it more
57 % maintainable and deployable are also outlined. Finally, a set of tips
58 % and tricks that can be used to make the BTS easier to use are
59 % presented.
60
61 %  - New Features
62 %    - affects
63 %    - summary
64 %    - local debbugs mirror for offline work
65 %    - New SOAP
66 %      - full text search
67 %      - filtering bugs
68 %    - multi-distribution/arch status
69 %    - control changes at submit@ time
70 %  - Code Architecture Changes
71 %    - Modularization
72 %    - Control abstraction
73 %    - release to experimental
74
75
76 <<load.libraries,echo=FALSE,results="hide",error=FALSE,message=FALSE>>=
77 library(lattice)
78 library(xtable)
79 library(ggplot2)
80 library("scales")
81 library(reshape2)
82 library("data.table")
83 opts_chunk$set(dev="cairo_pdf",out.width="\\textwidth",out.height="0.8\\textheight",out.extra="keepaspectratio",fig.width=6,fig.height=4)
84 opts_chunk$set(cache=TRUE, autodep=TRUE)
85 options(device = function(file, width = 6, height = 4, ...) {
86   cairo_pdf(tempfile(), width = width, height = height, ...)
87 })
88
89
90
91 <<scientific_format,echo=FALSE>>=
92 scientific_10 <- function(x) {
93   parse(text=gsub("e", " %*% 10^", scientific_format()(x)))
94 }
95
96
97 \begin{document}
98
99 %\setbeamercolor{frametitle}[bg=-red!90!green!10,fg=black]
100
101 \frame[plain]{\titlepage
102   Source available at \url{http://git.donarmstrong.com/debbugs-presentations.git}
103 }
104
105 % \begin{frame}{Debbugs}
106 %   \tableofcontents[subsectionstyle=hide]
107 % \end{frame}
108
109 \section{Introduction to Debbugs}
110
111 \subsection{Introduction}
112 \begin{frame}{Goals of this talk}
113   \begin{columns}
114     \column{0.5\textwidth}
115     \begin{itemize}
116     \item Bug Statitics
117     \item Introduction to Debbugs
118     \item New features
119     \item Planned features
120     \item Places you can help
121     \end{itemize}
122     \column{0.5\textwidth}
123     \includegraphics[width=\textwidth,keepaspectratio]{images/rc_buggy}
124   \end{columns}
125 \end{frame}
126 \begin{frame}{Goals of the BTS}
127   \begin{columns}
128   \column{0.4\textwidth}
129     \includegraphics[width=\textwidth,keepaspectratio]{images/not_a_bug}
130   \column{0.6\textwidth}
131   \begin{itemize}
132   \item Reporting of \only<1>{Features}\only<2>{Bugs}
133   \item Evolution of \only<1>{Features}\only<2>{Bugs}
134   \item Fixing of \only<1>{Features}\only<2>{Bugs}
135   \item Reducing impact of \only<1>{Features}\only<2>{Bugs}
136   \end{itemize}
137 \end{columns}
138 \end{frame}
139
140 \section{Bugs in Debian}
141 \subsection{Bug Reporting Rate}
142 \begin{frame}{How many bugs do we have?}
143   \begin{center}
144 <<bug.growth,fig=TRUE,echo=FALSE,cache.extra=file.info("data/sorted_bug_growth_for_r_every_500.txt")[,"mtime"]>>=
145 bug.growth <- fread("data/sorted_bug_growth_for_r_every_500.txt")
146 colnames(bug.growth) <- c("time","bugs")
147 bug.growth <- bug.growth[pmax(bugs) <= as.numeric(bugs),]
148 bug.growth[,date:=
149                 as.POSIXct(ISOdatetime(1970,1,1,0,0,0)+
150                            as.numeric(bug.growth$time))]
151 print(ggplot(bug.growth[date > as.POSIXct(ISOdatetime(2005,1,1,0,0,0)),],
152              aes(x=date,y=bugs))+
153       xlab("Time")+ylab("Bugs filed in Debian")+
154       scale_y_continuous(labels = scientific_10)+
155       geom_point()+stat_smooth(method="lm"))
156
157 \end{center}
158 \end{frame}
159
160 \begin{frame}
161   \begin{columns}
162     \column{0.5\textwidth}
163   \begin{center}
164 <<bugs.filed,fig=TRUE,echo=FALSE,warning=FALSE,fig.width=3,fig.height=3>>=
165 print(ggplot(bug.growth[date > as.POSIXct(ISOdatetime(2015,1,1,0,0,0)),],
166              aes(x=date,y=bugs))+
167       xlab("Time")+ylab("Bugs filed in Debian")+
168       scale_y_continuous(labels = scientific_10)+
169       geom_point()+stat_smooth(method="lm"))
170 bugs.filed.per.day <-
171   lm(bugs~date,bug.growth)$coeff[2]*3600*24
172 temp.lm <- lm(date~bugs,bug.growth[date > as.POSIXct(ISOdatetime(2015,1,1,0,0,0)),])
173 bug.880000 <- 
174     as.POSIXct(ISOdatetime(1970,1,1,0,0,0)+as.numeric(predict(temp.lm,data.frame(bugs=880000,date=NA))))
175 bug.900000 <- 
176     as.POSIXct(ISOdatetime(1970,1,1,0,0,0)+as.numeric(predict(temp.lm,data.frame(bugs=900000,date=NA))))
177 bug.1000000 <- 
178     as.POSIXct(ISOdatetime(1970,1,1,0,0,0)+as.numeric(predict(temp.lm,data.frame(bugs=1000000,date=NA))))
179
180 \end{center}
181 \column{0.5\textwidth}
182 Roughly \Sexpr{format(bugs.filed.per.day,digits=1)} bugs are filed per
183 day. The 880000th bug will be filed at \Sexpr{bug.880000}, the
184 900000th bug will be filed at \Sexpr{bug.900000}, and bug one million will be filled 
185 \Sexpr{bug.1000000}.
186 \end{columns}
187 \end{frame}
188
189
190 \subsection{Bug Fixing Rate}
191 \begin{frame}
192   \begin{center}
193 <<bugs.closed,fig=TRUE,echo=FALSE,width=7,height=5,warning=FALSE,error=FALSE,cache.extra=file.info("data/bug_closed_time_series.txt")[,"mtime"]>>=
194 bug.closed.series <- fread(file="data/bug_closed_time_series.txt")
195 colnames(bug.closed.series) <- c("archived.bugs","year.week")
196 bug.closed.series[,week:=
197     gsub("(\\d+)-(\\d+)","\\2",year.week)]
198 bug.closed.series[,year:=
199     gsub("(\\d+)-(\\d+)","\\1",year.week)]
200 bug.closed.series[,doy:= as.numeric(week)*7]
201 bug.closed.series[,year.doy:=
202                        paste(sep="-",year,doy)]
203 bug.closed.series[,date:=
204                        as.POSIXct(strptime(year.doy,
205                                            format="%Y-%j"))]
206
207 # bug.closed.ts <- ts(bug.closed.series[,1],start=1,frequency=7)
208
209 print(ggplot(bug.closed.series[date > as.POSIXct(ISOdatetime(2008,1,1,0,0,0)),],
210              aes(x=date,y=archived.bugs/7))+geom_line()+stat_smooth(method="lm")+
211       ylab("Bugs archived Per Day")+xlab("Time"))
212 bugs.closed.per.day <-
213     bug.closed.series[,sum(archived.bugs)]/
214     as.numeric(bug.closed.series[nrow(bug.closed.series),date]-
215                bug.closed.series[1,date])
216
217   \end{center}
218 Roughly \Sexpr{format(bugs.closed.per.day,digits=1)} bugs are closed per day.
219 \end{frame}
220
221 \subsection{RC Bugs}
222 \begin{frame}{RC Bugs in the Past Year}
223   \begin{center}
224 <<rc.bugs,fig=TRUE,echo=FALSE,warning=FALSE,cache.extra=file.info("data/rc_bugs.txt")[,"mtime"]>>=
225 rc.bugs <-
226     data.table(read.table(file="data/rc_bugs.txt",
227                           header=TRUE,fill=TRUE))
228 rc.bugs[,date:=
229              as.POSIXct(strptime(date,
230                                  format="%Y%m%d%H%M"))]
231 rc.bugs[,unknown:=NULL]
232 rc.bugs[,unknown.1:=NULL]
233 for (i in 1:10) {
234     rc.bugs <- rc.bugs[c(0,diff(total)) > -1000,]
235 }
236 rc.bugs.long <-
237     data.table(melt(rc.bugs,id="date"))
238 print(ggplot(rc.bugs.long[date > 
239                           as.POSIXct(ISOdatetime(2016,08,1,0,0,0)),]
240             ,aes(x=date,y=value,color=variable))+
241       geom_line()+
242       ylab("# of Release Critical Bugs")+xlab("Time")+
243       theme(legend.position="top")+
244       scale_color_discrete("Measure"))
245
246 \end{center}
247   \setbeamercolor{postit}{fg=black,bg=yellow}
248   \begin{textblock}{4}(6,4)
249     \begin{onlyenv}<2>
250       \begin{beamercolorbox}[sep=1em,wd=5cm]{postit}
251         \centering \huge Too many RC bugs!
252       \end{beamercolorbox}
253     \end{onlyenv}
254   \end{textblock}
255
256 \end{frame}
257
258 \section{Debbugs Structure and Infrastructure}
259
260 \subsection{BTS System Diagram}
261 \begin{frame}{BTS system Diagram}
262   \begin{center}
263     \includegraphics[width=\textwidth,height=\textheight,keepaspectratio]{figures/bug_global_layout}
264   \end{center}
265 \end{frame}
266
267 \subsection{Debbugs Box Diagram}
268 \begin{frame}{Debbugs Box Diagram}
269   \begin{center}
270     \input{debbugs_layout}
271   \end{center}
272 \end{frame}
273
274 \section{Database Ho!}
275
276 \subsection{Overall Database Design}
277
278 \begin{frame}{Overall Database Design}
279   \begin{center}
280     \input{debbugs_layout_db}
281   \end{center}
282 \end{frame}
283
284 \subsection{Perl Database Infrastucture}
285 \begin{frame}{Perl Database Infrastructure}
286   \begin{itemize}
287   \item DBIx::Class
288   \item DBIx::Class::Schema::Loader -- SQL schema to DBIx::Class
289   \item DBIx::Class::DeploymentHandler -- Upgrades of Schema
290   \item Debbugs::DB -- Debbugs SQL Module
291   \end{itemize}
292 \end{frame}
293
294
295 \subsection{SQL Design}
296 \begin{frame}{SQL Schema}
297   \includegraphics[width=\textwidth,keepaspectratio]{figures/schema.png}
298   \begin{itemize}
299   \item Current Debbugs SQL Schema
300   \end{itemize}
301 \end{frame}
302
303 \subsubsection{dak SQL Design}
304 \begin{frame}{dak SQL Schema}
305   \includegraphics[width=\textwidth,keepaspectratio]{figures/dak_schema.png}
306   \begin{itemize}
307   \item Inspiration taken from dak SQL Schema where appropriate
308   \end{itemize}
309 \end{frame}
310
311 \subsection{SQL Loading}
312 \begin{frame}[fragile]{SQL Loading}
313   % SQL loading
314   \begin{itemize}
315   \item Load bugs
316 \begin{lstlisting}[language=sh]
317 debbugs-loadsql bugs;
318 debbugs-loadsql bugs archive;
319 \end{lstlisting}
320   \item Load Versioning information
321 \begin{lstlisting}[language=sh]
322 debbugs-loadsql versions;
323 debbugs-loadsql debinfo;
324 \end{lstlisting}
325   \end{itemize}
326 \end{frame}
327
328 \subsection{SQL Working}
329 \begin{frame}[fragile]{SQL Working}
330   % example SQL query
331 \begin{lstlisting}[language=SQL]
332 SELECT count(*) FROM bug
333 WHERE last_modified > '2014-07-01'
334 AND done IS NOT NULL
335 AND owner IS NOT NULL;
336 \end{lstlisting}
337 \begin{visibleenv}<2>
338 \begin{lstlisting}
339  count 
340 -------
341    521
342 \end{lstlisting}
343 \end{visibleenv}
344 \end{frame}
345
346 \subsection{Work still needed for SQL}
347 \begin{frame}{Work Still needed for SQL}
348 \begin{itemize}
349 \item Logfile loading (for full text searching)
350 \item Status Caching (for faster page loading)
351 \item Testing
352 \item Deployment
353 \end{itemize}
354 \end{frame}
355
356 \section{New(ish) Features}
357
358 \subsection{New Changes}
359 \begin{frame}{New Changes}
360   \begin{columns}
361     \column{0.5\textwidth}
362     \begin{itemize}
363   \item mailto links (demo)
364   \item forcemerge does the right thing
365   \item control at submit time
366   \end{itemize}
367     \column{0.5\textwidth}
368     \includegraphics[width=\textwidth,keepaspectratio]{images/telegraph_bug}
369 \end{columns}
370 \end{frame}
371
372 \section{Future features}
373
374 \subsection{Status Caching}
375 \begin{frame}{Status Caching}
376   \begin{itemize}
377   \item Cache status of bugs (presence/absence at all distributions)
378   \item Speed up display of \url{http://bugs.debian.org/src:linux-2.6}
379   \item Allows for reverse status lookup
380     \begin{itemize}
381     \item Enables finding bugs which are present in testing or unstable
382     \end{itemize}
383   \end{itemize}
384 \end{frame}
385
386 \subsection{Statistics}
387 \begin{frame}{Statistics}
388   \begin{columns}
389     \column{0.5\textwidth}
390     \begin{itemize}
391     \item Track status changes over time
392     \item Bugs found/fixed/absent in stable/testing/unstable over time
393     \item Bug submission times
394     \item Bug closure times
395     \item Bug mail rates
396     \item Per package, severity, maintainer tracking of the above
397     \end{itemize}
398     \column{0.5\textwidth}
399     \begin{center}
400       \includegraphics[width=\textwidth,height=0.35\textheight,keepaspectratio]{images/bug}
401     \end{center}
402   \end{columns}
403 \end{frame}
404
405
406 \subsection{Additional Planned Features}
407 \begin{frame}{More planned features}
408   \begin{columns}
409     \column{0.5\textwidth}
410     \begin{itemize}
411     \item HTTP based reporting system with e-mail roundtrip
412     \item Release Debbugs again
413     \item Bug mailing lists in Debbugs
414       \begin{itemize}
415       \item Avoid duplicate mail
416       \item Opt in/out of mail
417       \end{itemize}
418     \item Merging of merged bug reports
419     \item Threading in report
420     \end{itemize}
421     \column{0.5\textwidth}
422     \includegraphics[width=\textwidth,keepaspectratio]{images/fixed_bug}
423   \end{columns}
424 \end{frame}
425
426 \begin{frame}{Even More planned features}
427   \begin{columns}
428     \column{0.5\textwidth}
429     \begin{itemize}
430     \item Usercategory duplication and replay
431     \item Remote Attachments
432     \item New Spool Storage Format
433     \item Usertags visibility
434     \item Smarter CGI options
435     \end{itemize}
436     \column{0.5\textwidth}
437     \includegraphics[width=\textwidth,keepaspectratio]{images/fixed_bug}
438   \end{columns}
439 \end{frame}
440
441
442
443
444
445 \section{Places you can help}
446
447 \begin{frame}{7 tasks seeking contributors}
448   \begin{itemize}
449   \item Documentation of Usercategories
450   \item Implementation of rss feeds for packages and bugs
451   \item CGI options on pkgreport.cgi for usertags et al. \#536378)
452   \item Documentation of multipe-package reassign and when it or
453     affects should be used
454   \item Mailto link with subject, references, etc. all filled in
455   \item Documentation for local-debbugs configuration file (behaves
456     like bts select)
457   \end{itemize}
458 \end{frame}
459
460 \begin{frame}{Getting started on these tasks}
461   \begin{itemize}
462   \item Upstream branches: \url{http://bugs.debian.org/debbugs-source/}
463     \begin{itemize}
464     \item master (upstream debbugs): git clone \url{http://bugs.debian.org/debbugs-source/debbugs.git}
465     \item debian (debian branch): git clone -b debian \url{http://bugs.debian.org/debbugs-source/debbugs.git}
466     \item Checked out branches are also available at
467       \url{http://bugs.debian.org/debbugs-source/master} and
468       \url{http://bugs.debian.org/debbugs-source/debian}
469     \end{itemize}
470   \item My branches: \url{http://git.donarmstrong.com/debbugs.git}
471   \item Mailing list debian-debbugs@lists.debian.org
472   \item IRC \#debbugs or \#debian-bugs on irc.debian.org; I'm dondelelcaro
473   \end{itemize}
474 \end{frame}
475
476 \begin{frame}{The Debbugs Team}
477   \begin{itemize}
478   \item Current team
479     \begin{itemize}
480     \item Don Armstrong
481     \item Blars Blarson
482     \item Colin Watson
483     \end{itemize}
484   \item Emeritus Developers
485     \begin{itemize}
486     \item Steiner Gunderson
487     \item Adam Heath
488     \item Josip Rodin
489     \item Anthony Towns
490     \end{itemize}
491   \item You!
492   \end{itemize}
493 \end{frame}
494
495 \begin{frame}{Questions?}
496   \includegraphics[width=0.8\textwidth,height=0.8\textheight,keepaspectratio]{images/don_at_burning_man.jpg}
497 \end{frame}
498
499 \end{document}
500
501