add static builder
This commit is contained in:
184
content/talks/jug-event-store/index.html
Normal file
184
content/talks/jug-event-store/index.html
Normal file
@@ -0,0 +1,184 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
|
||||
<title>Event Store − Thibaud Dauce</title>
|
||||
|
||||
<meta name="description" content="A framework for easily creating beautiful presentations using HTML">
|
||||
<meta name="author" content="Hakim El Hattab">
|
||||
|
||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, minimal-ui">
|
||||
|
||||
<link rel="stylesheet" href="css/reveal.css">
|
||||
<link rel="stylesheet" href="css/theme/solarized.css" id="theme">
|
||||
|
||||
<!-- Code syntax highlighting -->
|
||||
<link rel="stylesheet" href="lib/css/zenburn.css">
|
||||
|
||||
<!-- Printing and PDF exports -->
|
||||
<script>
|
||||
Reveal.configure({ slideNumber: true });
|
||||
|
||||
var link = document.createElement( 'link' );
|
||||
link.rel = 'stylesheet';
|
||||
link.type = 'text/css';
|
||||
link.href = window.location.search.match( /print-pdf/gi ) ? 'css/print/pdf.css' : 'css/print/paper.css';
|
||||
document.getElementsByTagName( 'head' )[0].appendChild( link );
|
||||
|
||||
</script>
|
||||
|
||||
<!--[if lt IE 9]>
|
||||
<script src="lib/js/html5shiv.js"></script>
|
||||
<![endif]-->
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="reveal">
|
||||
|
||||
<!-- Any section element inside of this container is displayed as a slide -->
|
||||
<div class="slides">
|
||||
<section>
|
||||
<h1>Event Store</h1>
|
||||
<h3>Java User Group — 23 février 2016</h3>
|
||||
<p>
|
||||
<small><a href="https://thibaud.dauce.fr">Thibaud Dauce</a></small>
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Domain Driven Design</h2>
|
||||
<h4>La conception doit mettre l'accent sur le domaine</h4>
|
||||
<h4>créer un utilisateur != inscription d'un client</h4>
|
||||
|
||||
<p>
|
||||
<small>Conférence de Cyrille Martraire à Codeurs en Seine 2015</small>
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2 style="font-size: 2em;">Command Query Responsibility Segregation</h2>
|
||||
<h4>Séparation des requêtes sur les données et des modifications des données</h4>
|
||||
|
||||
<p>
|
||||
<small>Conférence de Eric et Sébastian Le Merdy à Codeurs en Seine 2015</small>
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Event Sourcing</h2>
|
||||
<h4>Stocker l'état de l'application comme une succession d'événements</h4>
|
||||
|
||||
<p>
|
||||
<small><a href="http://martinfowler.com/eaaDev/EventSourcing.html">Article de Martin Fowler sur l'Event Sourcing</a></small>
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Qu'est-ce qu'un événement ?</h2>
|
||||
<h4>Une simple structure de données</h4>
|
||||
|
||||
<pre><code data-trim data-noescape>
|
||||
public final class ArticleWasPublished {
|
||||
|
||||
private UUID articleId;
|
||||
private UUID publisherId;
|
||||
|
||||
public ArticleWasPublished (UUID articleId, UUID publisherId) {
|
||||
this.articleId = articleId;
|
||||
this.publisherId = publisherId;
|
||||
}
|
||||
|
||||
public UUID getArticleId() { return this.articleId; }
|
||||
|
||||
public UUID getPublisherId() { return this.publisherId; }
|
||||
}
|
||||
</code></pre>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Exemple de modèle évènementiel</h2>
|
||||
<h3>vos comptes en banque</h3>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>Date</th><th>Compte</th><th>Libellé</th><th>Changement</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>20/02/2016</td><td>042</td><td>Remboursement</td><td>+20€</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>12/02/2016</td><td>042</td><td>Facture</td><td>-20€</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>08/02/2016</td><td>042</td><td>Courses</td><td>-12€</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>06/02/2016</td><td>042</td><td>Virement initial</td><td>100€</td>
|
||||
</tr>
|
||||
</table>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Avantages</h2>
|
||||
<ul>
|
||||
<li>Utilisation du langage du domaine pour les évènements</li>
|
||||
<li>Modifications explicites, pas de perte d'information</li>
|
||||
<li>Mise à l'échelle très facile car système en ajout-seulement</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Problème</h2>
|
||||
<h4>Comment connaître le solde à un instant t ?</h4>
|
||||
<h4>Obligation de recalculer à chaque fois = coûteux en temps</h4>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Solution</h2>
|
||||
<h4>Mettre en place du cache ou des snapshots</h4>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Architecture type</h2>
|
||||
<img src="images/architecture.svg" alt="Architecture" style="border: none; box-shadow: none;"/>
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="lib/js/head.min.js"></script>
|
||||
<script src="js/reveal.js"></script>
|
||||
|
||||
<script>
|
||||
|
||||
// Full list of configuration options available at:
|
||||
// https://github.com/hakimel/reveal.js#configuration
|
||||
Reveal.initialize({
|
||||
controls: true,
|
||||
progress: true,
|
||||
history: true,
|
||||
center: true,
|
||||
slideNumber: 'c/t',
|
||||
|
||||
transition: 'slide', // none/fade/slide/convex/concave/zoom
|
||||
|
||||
// Optional reveal.js plugins
|
||||
dependencies: [
|
||||
{ src: 'lib/js/classList.js', condition: function() { return !document.body.classList; } },
|
||||
{ src: 'plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
|
||||
{ src: 'plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
|
||||
{ src: 'plugin/highlight/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } },
|
||||
{ src: 'plugin/zoom-js/zoom.js', async: true },
|
||||
{ src: 'plugin/notes/notes.js', async: true }
|
||||
]
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user