Allez plus Loin avec CDI
En moins de 5 ans d’existence, Contexts and Dependency Injection (CDI) est devenue l’une des principale spécification de Java EE. Néanmoins, CDI est bien souvent perçu comme une simple solution d’injection de dépendance enrichie alors que cette spécification est bien plus riche que ça. Lors de cette présentation, après un rapide rappel des fonctionnalités de base de CDI, nous montrerons comment son utilisation avancée permet Java EE en intégrant des technologies legacy ou plus récent de manière naturelle. Nous finirons avec le travail en cours sur CDI 2.0 qui a commencé début septembre.
Allez plus Loin avec CDI
En moins de 5 ans d’existence, Contexts and Dependency Injection (CDI) est devenue l’une des principale spécification de Java EE. Néanmoins, CDI est bien souvent perçu comme une simple solution d’injection de dépendance enrichie alors que cette spécification est bien plus riche que ça. Lors de cette présentation, après un rapide rappel des fonctionnalités de base de CDI, nous montrerons comment son utilisation avancée permet Java EE en intégrant des technologies legacy ou plus récent de manière naturelle. Nous finirons avec le travail en cours sur CDI 2.0 qui a commencé début septembre.
3/3 : The path to CDI 2.0 - Antoine Sabot-DurandSOAT
Allez plus Loin avec CDI
En moins de 5 ans d’existence, Contexts and Dependency Injection (CDI) est devenue l’une des principale spécification de Java EE. Néanmoins, CDI est bien souvent perçu comme une simple solution d’injection de dépendance enrichie alors que cette spécification est bien plus riche que ça. Lors de cette présentation, après un rapide rappel des fonctionnalités de base de CDI, nous montrerons comment son utilisation avancée permet Java EE en intégrant des technologies legacy ou plus récent de manière naturelle. Nous finirons avec le travail en cours sur CDI 2.0 qui a commencé début septembre.
Concurrency is the ability to run several programs or several parts of a program in parallel. If a time consuming task can be performed asynchronously or in parallel, this improve the throughput and the interactivity of the program.
Rest-assured is a 100% java-based, BDD style, test library that you can use for testing REST api's in java projects. These are the slides from the presentation and demo I give at the 2017 #JBCNConf Java conference in Barcelona.
This ppt provide basic understanding regarding Spring Boot. And how to configure Spring Boot application with Hibernate and mysql by using eclipse IDE. Also provides understanding about how to configure Spring Tool Suit (STS) in Eclipse.
Allez plus Loin avec CDI
En moins de 5 ans d’existence, Contexts and Dependency Injection (CDI) est devenue l’une des principale spécification de Java EE. Néanmoins, CDI est bien souvent perçu comme une simple solution d’injection de dépendance enrichie alors que cette spécification est bien plus riche que ça. Lors de cette présentation, après un rapide rappel des fonctionnalités de base de CDI, nous montrerons comment son utilisation avancée permet Java EE en intégrant des technologies legacy ou plus récent de manière naturelle. Nous finirons avec le travail en cours sur CDI 2.0 qui a commencé début septembre.
3/3 : The path to CDI 2.0 - Antoine Sabot-DurandSOAT
Allez plus Loin avec CDI
En moins de 5 ans d’existence, Contexts and Dependency Injection (CDI) est devenue l’une des principale spécification de Java EE. Néanmoins, CDI est bien souvent perçu comme une simple solution d’injection de dépendance enrichie alors que cette spécification est bien plus riche que ça. Lors de cette présentation, après un rapide rappel des fonctionnalités de base de CDI, nous montrerons comment son utilisation avancée permet Java EE en intégrant des technologies legacy ou plus récent de manière naturelle. Nous finirons avec le travail en cours sur CDI 2.0 qui a commencé début septembre.
Concurrency is the ability to run several programs or several parts of a program in parallel. If a time consuming task can be performed asynchronously or in parallel, this improve the throughput and the interactivity of the program.
Rest-assured is a 100% java-based, BDD style, test library that you can use for testing REST api's in java projects. These are the slides from the presentation and demo I give at the 2017 #JBCNConf Java conference in Barcelona.
This ppt provide basic understanding regarding Spring Boot. And how to configure Spring Boot application with Hibernate and mysql by using eclipse IDE. Also provides understanding about how to configure Spring Tool Suit (STS) in Eclipse.
Angular is the best open source front end web application framework that helps you to build fast apps. These best practices are followed to run apps much faster and smoother.
JUnit 5 — New Opportunities for Testing on the JVMVMware Tanzu
SpringOne Platform 2017
Sam Brannen, Switfmind
"Take a Deep Dive into JUnit 5 with core committer Sam Brannen!
Over the last decade a lot has happened in the world of Java and testing, but JUnit 4 hasn't kept up. Now JUnit 5 is here to help shape the future of testing on the JVM with a focus on Java 8 language features, extensibility, and a modern programming API for testing in Java. Moreover, JUnit isn't just a Java testing framework anymore. Third parties are already developing test engines for Scala, Groovy, Kotlin, etc. that run on the new JUnit Platform.
This session starts off with an overview of the inspiration for & architecture of JUnit 5, from launchers to test engines. Sam will then take the audience on a live coding tour, highlighting support for tagging, custom display names, dependency injection, repeated tests, parameterized tests, conditional test execution, lambda expressions for assertions, assumptions, & dynamic tests, and implementing tests via interface default methods (a.k.a., testing traits).
Next, Sam will present the new extension model in JUnit Jupiter, discussing how to author and register extensions for conditional tests, parameter resolution (a.k.a., dependency injection), lifecycle callbacks, & more.
To round off the session, Sam will quickly showcase the new JUnit Jupiter support in Spring Framework 5.0."
Building a Spring Boot Application - Ask the Audience! (from JavaLand 2017)🎤 Hanno Embregts 🎸
Spring Boot makes it easy to create stand-alone Spring-based application that you can 'just run'. It uses a 'convention over configuration' approach to get you up and running in no-time, while offering all Spring features that you have grown fond of in the past years. In this session this is demonstrated by live-coding a Spring Boot application that will just work.
But audience beware, this is not your standard live-coding session'. Attendees will have a vital say in the session's content by defining the applications requ irements. Should it be an app to track your kitchen cupboard contents or do you want a simple task planner? It's up to you! Should it use MongoDB or Couchbase? You decide! Do you want an AngularJS front-end with a RESTful backend or do you prefer a classic web app with Thymeleaf templates? It's your call! Seriously.
During the session you get to make these decisions by participating in an online vote. And you will discover that Spring Boot is up to the task no matter what choices you make.
So what are you waiting for? Bring your own device, help shape the application that we're building and learn lots about Spring Boot in the process.
This session is intended for Java software engineers with an interest in Spring Boot. Some Spring experience could come in handy, but is not strictly necessary. After this session, you will know enough to start your own Spring Boot project.
One of my presentations in DevOps training session at Higgsup. This presentation is an introduction to Continuous Integration and best practices to apply Continuous Integration to your project.
Topics covered in this session are:
1. Prerequisites for Continuous Integration
2. Problems with traditional software integration
3. What is Continuous Integration?
4. Why Continuous Integration?
5. How does Continuous Integration works?
6. Best practices of Continuous Integration
7. Summary
As Atlassian Connect is the way forward for building add-ons on Atlassian Cloud, Spring Boot is the way forward for building Spring web applications. Now you can combine the best of both worlds with the new open source library: Atlassian Connect Starter for Spring Boot. This will get you bootstrapped with an Atlassian Connect add-on in just a few minutes. In this talk you will learn:
What is Spring Boot
What is a Spring Boot Starter and how they benefit you
How to use the Atlassian Connect Starter to easily build Atlassian Connect add-ons
The Atlassian Connect architecture and how it interacts with your add-ons
We will write a simple macro for Confluence and show how much time Spring Boot can save you.
Spring has long become more than just a framework for application writing. Now there is a whole ecosystem of frameworks under Spring umbrella. This presentation is dedicated to automated testing of applications written in Spring, and more.
The respective talk was held by Kostyantyn Baranov (Senior Software Engineer, Consultant, GlobalLogic) at GlobalLogic Mykolaiv Java TechTalk #1 on July 26, 2018.
Durable Functions vs Logic App : la guerra dei workflow!!Massimo Bonanni
Hai la necessità di implementare un workflow o un integrazione tra servizi?
Ti serve scalabilità e non vuoi preoccuparti degli aspetti infrastrutturali?
Non sai da dove iniziare?
Inizia da questa sessione! Il serverless è la risposta per la scalabilità e l'astrazione infrastrutturale, ma per l'aspetto tecnologico puoi scegliere tra Durable Functions e Logic App. Questa sessione ti mostrerà pro e contro di entrambe le tecnologie fornendoti gli strumenti necessari per una scelta oculata.
Sessione del meetup #PitchOnline di #Coding del 21/07/2021
The Spring Framework has undergone a lot of innovation in the 4.0 and 4.1 releases, and so has its testing support. Join Spring Test component lead Sam Brannen in this talk to discover what's new in Spring's testing support in 4.0 through 4.1.
This talk will provide attendees an overview of what's been deprecated, what's changed, and what's been introduced in Spring's testing support over the last two years, with real life examples and tips for best practices. Highlights include using SocketUtils to scan for free TCP & UDP server ports, the ActiveProfilesResolver API, meta-annotation support for test annotations including attribute overrides, best practices with TestNG, using Groovy scripts to configure an ApplicationContext for integration tests, improvements to SQL script execution and embedded databases, the new TestContext framework bootstrap strategy, programmatic transaction management in tests, and more.
Replicating production on your laptop using the magic of containersJamie Coleman
Containers are an amazing technology that is revolutionising how we do computing in the modern age. 5 years ago, people were starting to use Docker and realising the potential that container technology could offer. Now every major cloud provider offers a container service with the addition of container orchestrator like Kubernetes that millions of developers around the world are starting to use. Now many of our applications are running in containers why not use that magical portable configuration that containers offer to replicate our production environments locally on our laptops… enter MicroShed and the Testcontainers frameworks. Testcontainers run and test with true-to-production environments in development with minimal re-writing of your test code giving you more time as a developer to write your application. This talk will give you a great overview of the technology and will demo how simple it is to create and run a MicroShed test in Maven.
Replicating production on your laptop using the magic of containers v2Jamie Coleman
Containers are an amazing technology that is revolutionising how we do computing in the modern age. 5 years ago, people were starting to use Docker and realising the potential that container technology could offer. Now every major cloud provider offers a container service with the addition of container orchestrator like Kubernetes that millions of developers around the world are starting to use. Now many of our applications are running in containers why not use that magical portable configuration that containers offer to replicate our production environments locally on our laptops… enter MicroShed and the Testcontainers frameworks. Testcontainers run and test with true-to-production environments in development with minimal re-writing of your test code giving you more time as a developer to write your application. This talk will give you a great overview of the technology and will demo how simple it is to create and run a MicroShed test in Maven.
Create Your Own Framework by Fabien PotencierHimel Nag Rana
This is a combined form of series of articles by Fabien Potencier - the author of Symfony Framework. I have collected and converted them as this ebook for storing and sharing purpose.
Angular is the best open source front end web application framework that helps you to build fast apps. These best practices are followed to run apps much faster and smoother.
JUnit 5 — New Opportunities for Testing on the JVMVMware Tanzu
SpringOne Platform 2017
Sam Brannen, Switfmind
"Take a Deep Dive into JUnit 5 with core committer Sam Brannen!
Over the last decade a lot has happened in the world of Java and testing, but JUnit 4 hasn't kept up. Now JUnit 5 is here to help shape the future of testing on the JVM with a focus on Java 8 language features, extensibility, and a modern programming API for testing in Java. Moreover, JUnit isn't just a Java testing framework anymore. Third parties are already developing test engines for Scala, Groovy, Kotlin, etc. that run on the new JUnit Platform.
This session starts off with an overview of the inspiration for & architecture of JUnit 5, from launchers to test engines. Sam will then take the audience on a live coding tour, highlighting support for tagging, custom display names, dependency injection, repeated tests, parameterized tests, conditional test execution, lambda expressions for assertions, assumptions, & dynamic tests, and implementing tests via interface default methods (a.k.a., testing traits).
Next, Sam will present the new extension model in JUnit Jupiter, discussing how to author and register extensions for conditional tests, parameter resolution (a.k.a., dependency injection), lifecycle callbacks, & more.
To round off the session, Sam will quickly showcase the new JUnit Jupiter support in Spring Framework 5.0."
Building a Spring Boot Application - Ask the Audience! (from JavaLand 2017)🎤 Hanno Embregts 🎸
Spring Boot makes it easy to create stand-alone Spring-based application that you can 'just run'. It uses a 'convention over configuration' approach to get you up and running in no-time, while offering all Spring features that you have grown fond of in the past years. In this session this is demonstrated by live-coding a Spring Boot application that will just work.
But audience beware, this is not your standard live-coding session'. Attendees will have a vital say in the session's content by defining the applications requ irements. Should it be an app to track your kitchen cupboard contents or do you want a simple task planner? It's up to you! Should it use MongoDB or Couchbase? You decide! Do you want an AngularJS front-end with a RESTful backend or do you prefer a classic web app with Thymeleaf templates? It's your call! Seriously.
During the session you get to make these decisions by participating in an online vote. And you will discover that Spring Boot is up to the task no matter what choices you make.
So what are you waiting for? Bring your own device, help shape the application that we're building and learn lots about Spring Boot in the process.
This session is intended for Java software engineers with an interest in Spring Boot. Some Spring experience could come in handy, but is not strictly necessary. After this session, you will know enough to start your own Spring Boot project.
One of my presentations in DevOps training session at Higgsup. This presentation is an introduction to Continuous Integration and best practices to apply Continuous Integration to your project.
Topics covered in this session are:
1. Prerequisites for Continuous Integration
2. Problems with traditional software integration
3. What is Continuous Integration?
4. Why Continuous Integration?
5. How does Continuous Integration works?
6. Best practices of Continuous Integration
7. Summary
As Atlassian Connect is the way forward for building add-ons on Atlassian Cloud, Spring Boot is the way forward for building Spring web applications. Now you can combine the best of both worlds with the new open source library: Atlassian Connect Starter for Spring Boot. This will get you bootstrapped with an Atlassian Connect add-on in just a few minutes. In this talk you will learn:
What is Spring Boot
What is a Spring Boot Starter and how they benefit you
How to use the Atlassian Connect Starter to easily build Atlassian Connect add-ons
The Atlassian Connect architecture and how it interacts with your add-ons
We will write a simple macro for Confluence and show how much time Spring Boot can save you.
Spring has long become more than just a framework for application writing. Now there is a whole ecosystem of frameworks under Spring umbrella. This presentation is dedicated to automated testing of applications written in Spring, and more.
The respective talk was held by Kostyantyn Baranov (Senior Software Engineer, Consultant, GlobalLogic) at GlobalLogic Mykolaiv Java TechTalk #1 on July 26, 2018.
Durable Functions vs Logic App : la guerra dei workflow!!Massimo Bonanni
Hai la necessità di implementare un workflow o un integrazione tra servizi?
Ti serve scalabilità e non vuoi preoccuparti degli aspetti infrastrutturali?
Non sai da dove iniziare?
Inizia da questa sessione! Il serverless è la risposta per la scalabilità e l'astrazione infrastrutturale, ma per l'aspetto tecnologico puoi scegliere tra Durable Functions e Logic App. Questa sessione ti mostrerà pro e contro di entrambe le tecnologie fornendoti gli strumenti necessari per una scelta oculata.
Sessione del meetup #PitchOnline di #Coding del 21/07/2021
The Spring Framework has undergone a lot of innovation in the 4.0 and 4.1 releases, and so has its testing support. Join Spring Test component lead Sam Brannen in this talk to discover what's new in Spring's testing support in 4.0 through 4.1.
This talk will provide attendees an overview of what's been deprecated, what's changed, and what's been introduced in Spring's testing support over the last two years, with real life examples and tips for best practices. Highlights include using SocketUtils to scan for free TCP & UDP server ports, the ActiveProfilesResolver API, meta-annotation support for test annotations including attribute overrides, best practices with TestNG, using Groovy scripts to configure an ApplicationContext for integration tests, improvements to SQL script execution and embedded databases, the new TestContext framework bootstrap strategy, programmatic transaction management in tests, and more.
Replicating production on your laptop using the magic of containersJamie Coleman
Containers are an amazing technology that is revolutionising how we do computing in the modern age. 5 years ago, people were starting to use Docker and realising the potential that container technology could offer. Now every major cloud provider offers a container service with the addition of container orchestrator like Kubernetes that millions of developers around the world are starting to use. Now many of our applications are running in containers why not use that magical portable configuration that containers offer to replicate our production environments locally on our laptops… enter MicroShed and the Testcontainers frameworks. Testcontainers run and test with true-to-production environments in development with minimal re-writing of your test code giving you more time as a developer to write your application. This talk will give you a great overview of the technology and will demo how simple it is to create and run a MicroShed test in Maven.
Replicating production on your laptop using the magic of containers v2Jamie Coleman
Containers are an amazing technology that is revolutionising how we do computing in the modern age. 5 years ago, people were starting to use Docker and realising the potential that container technology could offer. Now every major cloud provider offers a container service with the addition of container orchestrator like Kubernetes that millions of developers around the world are starting to use. Now many of our applications are running in containers why not use that magical portable configuration that containers offer to replicate our production environments locally on our laptops… enter MicroShed and the Testcontainers frameworks. Testcontainers run and test with true-to-production environments in development with minimal re-writing of your test code giving you more time as a developer to write your application. This talk will give you a great overview of the technology and will demo how simple it is to create and run a MicroShed test in Maven.
Create Your Own Framework by Fabien PotencierHimel Nag Rana
This is a combined form of series of articles by Fabien Potencier - the author of Symfony Framework. I have collected and converted them as this ebook for storing and sharing purpose.
Slides of Java One 2015 session "Advanced CDI in live coding"
In this session we explained how portable extensions work and shown third party framework integration with Metrics and Camel integration into CDI programming model
Play! Framework at GenevaJUG by Guillaume BortGenevaJUG
La présentation de Play! framework au GenevaJUG le 26 janvier 2010 par Guillaume Bort et Habib Guergachi.
http://www.playframework.org/
http://www.genevajug.ch/
Les EIPs (Enterprise Integration Patterns) sont devenues un standard de fait pour décrire les scénarios d’intégration et de messaging.
Apache Camel a été conçu en vue de supporter complètement ces modèle.
Grâce a ses langages dédiés (DSL Java, Xml, Scala ..), Camel rends les scénarios d’intégration les plus complexes très simples a implémenter.
Cette présentation vous donnera un aperçu de Camel et beaucoup de raisons d’ajouter ce projet dans votre boîte à outils.
New features coming in CDI 2.0, talk given during Java One 2016
- Java SE support
- Async events
- Ordered events
- Meta data configurators
- Interceptors on producers
Slides of my tutorial I gave to Java One 2016 on advanced CDI 1.2 stuff.
Introducing CDI 1.2 SPI, Portable extension and then show how to develop fat JPA entities, asynchronous events and integration of a 3rd party framework (Dropwizard Metrics) with CDI 1.2 to enhance Java EE 7 platform.
Typesafe trainer and consultant Will Sargent describes just how Play Framework is so "fast" for Java and Scala production apps.
More Play, Akka, Scala and Apache Spark webinars, presentations, and videos:
http://typesafe.com/resources/videos
Video: https://www.youtube.com/watch?v=b6yLwvNSDck
Here's the showdown you've been waiting for: Node.js vs Play Framework. Both are popular open source web frameworks that are built for developer productivity, asynchronous I/O, and the real time web. But which one is easier to learn, test, deploy, debug, and scale? Should you pick Javascript or Scala? The Google v8 engine or the JVM? NPM or Ivy? Grunt or SBT? Two frameworks enter, one framework leaves.
This is the English version of the presentation. For the version with Japanese subtitles, see http://www.slideshare.net/brikis98/nodejs-vs-play-framework-with-japanese-subtitles
Cette présentation, réalisée dans le cadre de Devoxx France 2012, propose une exploration pratique des fonctionnalités de CDI et de quelques extensions Seam 3 à travers le module Seam Social (solution d'interconnexion aux réseaux sociaux).
Cette présentation est le support d'une Université faite à Devoxx par Mathieu Ancelin (Serli) et moi même. Elle propose une exploration pratique des fonctionnalités de CDI et de quelques extensions Seam 3 à travers le module Seam Social (solution d'interconnexion aux réseaux sociaux).
Les sujets suivants seront abordés :
Retour rapide sur la spécification CDI
Création et manipulation de Bean CDI
Création d'extension CDI
Utilisation d'événements CDI
Création de décorateurs et intercepteurs CDI
Extension de CDI pour une approche modulaire grace à Weld OSGI
Création d'une appli web cliente se connectant à plusieurs services (Twitter, Facebook LinkedIn)
Présentation sur Java EE / Wildfly faite au JUG SummerCamp 2015.
Venez revisiter les idées reçues sur Java EE. Cette présentation revisite les mythes autour de Java EE pour voir si ils sont toujours vrais ou faux.
This presentation provides an introduction to CDI (Contexts and Dependency Injection), covering the basic and intermediate features. It was authored by Antoine Sabot-Durand, the co-spec lead for CDI.
Le temps est révolu où Java EE ne serait qu’à développer des applications de mise à jour de données, avec JSF / EJB / JPA. Aujourd’hui Java EE s’est assoupli et s’est ouvert sur le monde, avec CDI comme clé de voûte et a repoussé nos limites grâce à des capacités d’extension puissantes et faciles d’utilisation comme JCA.
Dans un premier temps, nous reviendrons rapidement sur la place de CDI dans JavaEE 7 et sur ses mécanismes d’extension. Dans un deuxième temps, nous verrons les techniques de connecteurs JCA et comment ils peuvent aussi constituer une possibilité d’ouverture simple à mettre en œuvre. JCA fournit des techniques pour gérer des connexions sortantes ou entrantes, sur des formats ou protocoles variés.
The easy way to develop Java applications has always been the standard stack (Spring, JEE, SQL) that confirms the LAMP equivalent in Java-speak. This presentation compares this model with a real use case based on Guice, Jersey and AppEngine.
Writing Kotlin Multiplatform libraries that your iOS teammates are gonna loveAndré Oriani
Kotlin Multiplatform Mobile (KMM) is awesome for us Android developers. Writing multiplatform code with it doesn't diverge much from our usual routine, and now with Compose Multiplatform, we can write an entire iOS app without knowing a thing about iOS development.
But to truly conquer the world of mobile development, we need to bring the iOS developers over to our side. Join us in this exciting presentation where we unravel the secrets of crafting Kotlin Multiplatform libraries that your iOS teammates won’t believe weren’t written in Swift.
- Discover how Kotlin constructs are translated into Objective-C/Swift and explore effective strategies for addressing any translation problems.
- Learn tricks that ensure iOS developers will enjoy a frictionless experience while consuming KMM APIs.
By using KMM one can significantly reduce development time and bug count.
Similar to 1/3 : introduction to CDI - Antoine Sabot-Durand (20)
Du 7 au 9 mai aura lieu la conférence Microsoft //Build, LA conférence des développeurs Microsoft.
A peine le temps de digérer les nombreuses sessions proposées par Microsoft que nos MVP vous présentent une synthèse des principales annonces.
L’« entreprise libérée », buzzword du moment, fait couler beaucoup d’encre ces dernières années. Libérée ? De qui, de quoi ? Mais que cache cette expression ?
Nous retracerons l’évolution de l’organisation des hommes et du management, pour s’intéresser à cette nouvelle forme d’organisation qui remet l’humain au centre de l’entreprise.
Quelles sont les caractéristiques de celle-ci ? Quelles pratiques diffèrent des entreprises classiques ? Et surtout comment faire pour devenir une entreprise libérée et pour quels bénéfices ?
Que vous soyez développeurs, managers, chefs de projet, Scrum Master, RH, commerciaux ou dirigeants, je vous invite à découvrir ce nouveau paradigme d’organisation et de management, qui veut réconcilier deux concepts a priori incompatibles : Bonheur et Travail. Alors, info ou intox ?
Amélioration continue, c'est l'affaire de tous !SOAT
Popularisée par Toyota dans les années 50, est au cœur du processus Agile. L’idée majeure est de se dire qu’il y a toujours moyen, quel que soit le processus utilisé, de le rendre plus performant. Tout processus, aussi optimal soit-il, s’inscrit dans un contexte évolutif et perd donc de son efficacité avec le temps s’il n’est pas continuellement revu ou amélioré.
Reste que dans l’univers informatique, on a trop souvent tendance à cantonner cette démarche aux seules équipes de développement alors qu’elle peut être élargie à toutes les fonctions stratégiques d’une organisation. Nous allons voir lors de cette conférence, comment élargir cette approche en y impliquant toutes les étapes d’un projet et en travaillant sur les interactions entre ses différents acteurs.
L’amélioration continue ne pouvant se réduire à une maîtrise optimisée des processus, nous verrons dans quelle mesure elle induit également une nouvelle politique de partage des connaissances pour faire émerger une véritable « intelligence collective ».
JAVA 8 : Migration et enjeux stratégiques en entrepriseSOAT
La sortie de Java 8 est une véritable révolution dont l’enjeu dépasse de loin la simple évolution d’un langage et de ses APIs. Rdv sur notre chaîne Youtube pour revoir la conférence :
Après une version 7 peu convaincante, la version 8 replace Java au premier rang des langages objets actuels.
En parfaite adéquation avec les besoins des projets et les possibilités offertes par les environnements matériels actuels, cette nouvelle version apporte une modernisation du langage et de ses API, un suivi des performances des processeurs et des améliorations de la JVM.
Quels sont les nouveaux concepts introduits par Java 8 ? En quoi les expressions lambdas et l’API Stream représentent une avancée majeure de la plateforme ? Quelle stratégie adopter pour migrer vers Java 8 en toute sécurité et en diminuant au maximum sa dette technique ?
ARCHITECTURE MICROSERVICE : TOUR D’HORIZON DU CONCEPT ET BONNES PRATIQUESSOAT
Les systèmes distribués ont largement évolués ces 10 dernières années, passant d’énormes applications monolithiques à de petits containers de services, apportant plus de souplesse et d’agilité au sein des systèmes d’information.
Le terme « Architecture microservice » a vu le jour pour décrire cette manière particulière de concevoir des applications logicielles.
Bien qu’il n’y ait pas de définition précise de ce style d’architecture, elles ont un certain nombre de caractéristiques communes basées autour de l’organisation de l’entreprise, du déploiement automatisé et de la décentralisation du contrôle du langage et des données.
Seulement, développer ces systèmes peut tourner au véritable casse-tête. Je vous propose donc un tour des concepts et différentes caractéristiques de ce type d’architecture, des bonnes et mauvaises pratiques, de la création jusqu’au déploiement des applications.
Javascript s’est depuis longtemps imposé comme le principal langage pour développer des écrans web dynamiques. L'émergence des SPA (Single Page Application) est en fait l'aboutissement logique du succès de ces outils au premier rang desquels on compte jQuery et AJAX.
AngularJS fait partie d’une nouvelle génération de frameworks qui propose d’aller plus loin afin d’avoir non seulement des SPA améliorant l’expérience utilisateur mais aussi un code mieux organisé, plus modulaire et donc facilement testable.
Au cours de cette soirée, vous verrez d’abord la manière dont AngularJS étend le HTML à travers les directives puis le binding bidirectionnel, ensuite, la programmation asynchrone avec AngularJS. Enfin pour finir, nous allons voir ces petits plus qui expliquent la popularité du framework : les filtres, l’injection de dépendance et les tests.
RxJava, Getting Started - David Wursteisen - 16 Octobre 2014SOAT
Les applications sont de plus en plus interconnectées. Une architecture type WOA (Web Oriented Archiecture) et l’utilisation des micros-services nécessitent de faire de plus en plus appel à différents services web.
Comment composer un résultat à partir de ces différents services, sans avoir à ce soucier de l’ordre dans lequel les serveurs vont répondre ?
RxJava offre une manière élégante de faire de l’asynchrone et de la composition au sein de son application. David vous exposera les concepts de Rx (Reactive eXtension) avant de vous montrer une mise en application avec des exemples de code venant d’une application Android.
L'impact du Responsive Web Design sur vos équipes projet - Mathieu Parisot - ...SOAT
Plus de 50% des internautes français utilisent un support mobile pour naviguer sur le web. Il est donc temps de repenser votre stratégie mobile et le Responsive Web Design, consistant à ne faire qu’un seul site adapté au périphérique qui l’affiche, constitue une approche possible.
Après une introduction à ses principes, nous verrons qu’au-delà des défis techniques, le RWD suppose de revoir entièrement le processus de développement d’un site web et les méthodes de travail des équipes, que ce soit en phase de conception ou lors des tests.
Cette conférence sera l’occasion de découvrir les nouveaux challenges à relever par vos équipes lors de la conception de vos prochains sites internet.
Nio sur Netty par Mouhcine Moulou - 3 avril 2014SOAT
La vidéo de cette conférence est visible ici : http://youtu.be/T7r7UlSoe7k
La croissance continue du Web a accru la nécessité pour les applications Client/serveur de gérer la monté en charge et la performance. Heureusement, Java est livré avec les outils nécessaires pour créer des applications performantes, et scalables ! Les premières versions de Java incluent le support des communications réseau avec la jdk 1.4 qui a introduit l'API NIO. La nouvelle version, NIO 2, introduite dans Java 7, a été conçue pour permettre l'écriture asynchrone en réseau, Aujourd'hui, encore peu de gens s'intéressent au développement d'applications réseaux, car l'API Jdk reste complexe.
Netty est une bibliothèque Java pour l'écriture d'applications et de services réseau hautement concurrent et scalable. Netty est une API complétement asynchrone : l'Api vous propose une nouvelle façon de développer vos applications réseau en assurant un découplage entre votre logique métier et les traitements réseau grâce à son modèle basé sur une architecture "event-driven".
Dans cette conférence, vous comprendrez l'architecture de Netty, et comment des entreprises comme Twitter, Facebook, RedHat et autres l'utilisent pour répondre à leurs problématiques de communication réseau.
- le niveau : développeurs Java débutants et expérimentés
- la durée : 2h
Développer des applications iOS et Android avec c# grâce à Xamarin par Cyril ...SOAT
Développer des applications iOS et Android avec C# grâce à Xamarin par Cyril Cathala
A l’ère des smartphones et tablettes, le développement multiplateforme se révèle être un challenge : quelle solution choisir et comment minimiser les coûts, tout en optimisant l’expérience utilisateur ?
Parmi les solutions disponibles sur le marché, Xamarin s’adresse aux développeurs C# pour la création d’applications compatibles avec Windows 8, iOS et Android. Son approche multiplateforme permet de développer des applications natives de qualité en mutualisant jusqu’à 75% de code entre les différents OS.
Ce petit déjeuner sera l’occasion de faire un tour d’horizon des outils du marché, d’apprécier toutes les possibilités offertes par Xamarin et d’en explorer les pistes pour aller plus loin.
Amazon Web Service par Bertrand Lehurt - 11 mars 2014SOAT
Attention, soirée spécial cloud computing!
IAAS, PASS, SAAS... Perdu avec autant d'acronyme qui représente des types de cloud computing?
Ça tombe bien, Bertrand Lehurt vous propose une soirée d'introduction à l'IAAS (Infrastructure As A Service) avec Amazon Web Services, suivi d'une séance les mains dans le cambouis.
Vous allez apprendre à déployer une petite application en utilisant les services nécessaires dans la jungle de ceux proposés (plus de 37). Au cours de la soirée, nous aborderons donc l'utilisation d'EC2, S3, ELB, EBS, Cloudfront et Auto scaling et les architectures types qui sont utilisées dans le cloud computing.
La vidéo de la présentation est visible ici : http://youtu.be/0AUJ_hcMNhQ
ASP.Net Web API - Léonard Labat (18 février 2014)SOAT
HTTP est un protocole simple à comprendre, simple à utiliser et c’est cette simplicité qui le rend disponible sur un grand nombre de plate-forme. REST, de son côté, est un style d’architecture qui permet d’exposer facilement une API en utilisant HTTP et différents types de représentations de données tels que JSON ou XML.
ASP.NET Web API est une évolution de WCF pour écrire une couche d’API REST, en utilisant un modèle de programmation proche d’ASP.NET MVC. Cette soirée 3T sera l’occasion pour vous de découvrir les fonctionnalités offertes par ASP.NET Web API qui font que c’est une technologie qu’il faut envisager d’utiliser lorsque vous devez créer une API REST.
Xamarin et le développement natif d’applications Android, iOS et Windows en C#SOAT
Une mise à jour de cette présentation est disponible ici : http://fr.slideshare.net/soatexpert/dvelopper-des-applications-i-os-et-android-avec-c-grce-xamarin
*********************
Les slides de la conférence présentée par Cyril Cathala chez Soat le 04/03/2014 sur le thème : Xamarin et le développement natif d’applications Android, iOS et Windows en C#
La vidéo de la présentation est visible ici : http://youtu.be/0BF9NqLYNvQ
Ricardo Minhoto vous propose une conférence sur "Je suis agile tout seul : GTD & Personal Kanban"
Axe : Méthode GTD (Getting things done) au quotidien combiné à Personal Kanban
A cette occasion vous aurez
- - Résumé rapide du GTD
- - Présentation du Personal Kanban
- - Comment se combinent les 2
- Apprendre à mieux s’organiser, profiter du pouvoir kinesthesique et du management visuel
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Jeffrey Haguewood
Sidekick Solutions uses Bonterra Impact Management (fka Social Solutions Apricot) and automation solutions to integrate data for business workflows.
We believe integration and automation are essential to user experience and the promise of efficient work through technology. Automation is the critical ingredient to realizing that full vision. We develop integration products and services for Bonterra Case Management software to support the deployment of automations for a variety of use cases.
This video focuses on the notifications, alerts, and approval requests using Slack for Bonterra Impact Management. The solutions covered in this webinar can also be deployed for Microsoft Teams.
Interested in deploying notification automations for Bonterra Impact Management? Contact us at sales@sidekicksolutionsllc.com to discuss next steps.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Securing your Kubernetes cluster_ a step-by-step guide to success !KatiaHIMEUR1
Today, after several years of existence, an extremely active community and an ultra-dynamic ecosystem, Kubernetes has established itself as the de facto standard in container orchestration. Thanks to a wide range of managed services, it has never been so easy to set up a ready-to-use Kubernetes cluster.
However, this ease of use means that the subject of security in Kubernetes is often left for later, or even neglected. This exposes companies to significant risks.
In this talk, I'll show you step-by-step how to secure your Kubernetes cluster for greater peace of mind and reliability.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
GraphRAG is All You need? LLM & Knowledge GraphGuy Korland
Guy Korland, CEO and Co-founder of FalkorDB, will review two articles on the integration of language models with knowledge graphs.
1. Unifying Large Language Models and Knowledge Graphs: A Roadmap.
https://arxiv.org/abs/2306.08302
2. Microsoft Research's GraphRAG paper and a review paper on various uses of knowledge graphs:
https://www.microsoft.com/en-us/research/blog/graphrag-unlocking-llm-discovery-on-narrative-private-data/
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
2. ANTOINE SABOT-DURAND
• Senior Software Engineer @Red Hat
• Java & OSS :
• CDI co-spec lead
• CDI community development
• Tech Lead on Agorava
• @antoine_sd
3. WHAT IS CDI ?
• Java EE dependency injection standard
• Strong typed and type safe
• Context management
• Observer pattern included (Event bus)
• Highly extensible
5. A BIT OF HISTORY
CDI 1.0 (Java EE 6)
CDI 1.1 (Java EE 7)
CDI 1.2 (1.1 MR)
CDI 2.0 Starts
Dec 2009 June 2013 Apr 2014 Sep 2014
CDI 2.0 released
Q1 2016
7. CDI ACTIVATION
• In CDI 1.0, you must add a beans.xml file to your archive
• Since CDI 1.1, it’s activated by default:
• All classes having a “bean defining annotation” become a bean
• You can still use beans.xml file to activate CDI explicitly or
deactivate it
8. THE CDI BEAN
• In Java EE 6 and 7 everything is a Managed Bean
• Managed beans are basic components
• They are managed by the container
• They all have a lifecycle
• They can be intercepted (AOP)
• They can be injected
• Accessible from outside CDI code.
10. THIS IS A BEAN
public class HelloService {
public String hello() {
return "Hello World!";
}
}
11. DI IN CONSTRUCTOR
public class MyBean {
private HelloService service;
@Inject
public MyBean(HelloService service) {
this.service = service;
}
}
12. DI IN SETTER
public class MyBean {
private HelloService service;
@Inject
public void setService(HelloService service) {
this.service = service;
}
}
13. DI IN FIELD
public class MyBean {
@Inject
private HelloService service;
public void displayHello() {
display(service.hello();
}
}
14. NO TYPE ERASURE IN CDI
public class MyBean {
@Inject Service<User> userService;
@Inject Service<Staff> staffService;
}
15. NO TYPE ERASURE IN CDI
public class MyBean {
@Inject Service<User> userService;
@Inject Service<Staff> staffService;
}
This works
17. 2 SERVICE IMPLEMENTATIONS…
public interface HelloService {
public String hello();
}
public class FrenchHelloService implements HelloService {
public String hello() {
return "Bonjour tout le monde!";
}
}
public class EnglishHelloService implements HelloService {
public String hello() {
return "Hello World!";
}
}
18. …NEED QUALIFIERS…
@Qualifier
@Retention(RUNTIME)
@Target({FIELD, TYPE, METHOD, PARAMETER})
public @interface French {}
@Qualifier
@Retention(RUNTIME)
@Target({FIELD, TYPE, METHOD, PARAMETER})
public @interface English {}
19. …TO BE DISTINGUISHED.
@French
public class FrenchHelloService implements HelloService {
public String hello() {
return "Bonjour tout le monde!";
}
}
@English
public class EnglishHelloService implements HelloService {
public String hello() {
return "Hello World!";
}
}
20. QUALIFIED INJECTION POINTS
public class MyBean {
@Inject @French HelloService service;
public void displayHello() {
display( service.hello();
}
}
public class MyBean {
@Inject @English HelloService service;
public void displayHello() {
display( service.hello();
}
}
21. QUALIFIERS CAN HAVE MEMBERS
@Qualifier
@Retention(RUNTIME)
@Target({FIELD, TYPE, METHOD, PARAMETER})
public @interface Language {
Languages value();
@Nonbinding String description() default "";
public enum Languages {
FRENCH, ENGLISH
}
}
22. QUALIFIERS WITH MEMBERS 1/2
@Language(FRENCH)
public class FrenchHelloService implements HelloService {
public String hello() {
return "Bonjour tout le monde!";
}
}
@Language(ENGLISH)
public class EnglishHelloService implements HelloService {
public String hello() {
return "Hello World!";
}
}
23. QUALIFIERS WITH MEMBERS 2/2
public class MyBean {
@Inject @Language(ENGLISH) HelloService service;
public void displayHello() {
display( service.hello();
}
}
public class MyBean {
@Inject @Language(FRENCH) HelloService service;
public void displayHello() {
display( service.hello();
}
}
24. MULTIPLE QUALIFIERS
public class MyBean {
@Inject @French
HelloService service;
}
@French @Console @Secured
public class FrenchHelloService implements HelloService {
}
25. MULTIPLE QUALIFIERS
public class MyBean {
@Inject @French @Console
HelloService service;
}
@French @Console @Secured
public class FrenchHelloService implements HelloService {
}
26. MULTIPLE QUALIFIERS
public class MyBean {
@Inject @French @Console @Secured
HelloService service;
}
@French @Console @Secured
public class FrenchHelloService implements HelloService {
}
27. MULTIPLE QUALIFIERS
public class MyBean {
@Inject @French @Console @Secured
HelloService service;
}
@French @Secured
public class FrenchHelloService implements HelloService {
}
28. MULTIPLE QUALIFIERS
public class MyBean {
@Inject @French @Console @Secured
HelloService service;
}
@French @Secured
public class FrenchHelloService implements HelloService {
}
31. SOMETIMES CALLED “LAZY INJECTION”
public class MyBean {
@Inject Instance<HelloService> service;
public void displayHello() {
display( service.get().hello() );
}
}
32. CHECK BEAN EXISTENCE AT RUNTIME
public class MyBean {
@Inject Instance<HelloService> service;
public void displayHello() {
if (!service.isUnsatisfied()) {
display( service.get().hello() );
}
}
}
33. INSTANCE<T> IS ITERABLE
public interface Instance<T> extends Iterable<T>, Provider<T> {
public Instance<T> select(Annotation... qualifiers);
public <U extends T> Instance<U> select(Class<U> subtype, Annotation... qualifiers);
public <U extends T> Instance<U> select(TypeLiteral<U> subtype, Annotation... qualifiers);
public boolean isUnsatisfied();
public boolean isAmbiguous();
public void destroy(T instance);
}
34. LOOP ON ALL BEANS OF A GIVEN TYPE
public class MyBean {
@Inject @Any Instance<HelloService> services;
public void displayHello() {
for (HelloService service : services) {
display( service.hello() );
}
}
}
35. SELECT A QUALIFIER AT RUNTIME
public class MyBean {
@Inject @Any Instance<HelloService> services;
public void displayHello() {
display(
service.select(
new AnnotationLiteral()<French> {})
.get() );
}
}
37. CONTEXTS MANAGE BEANS LIFECYCLE
• They helps container to choose when a bean should be instantiated and destroyed
• They enforce the fact that a given bean is a singleton for a given context
• Built-in CDI contexts :
• @Dependent (default)
• @ApplicationScoped, @SessionScoped, @RequestScoped
• @ConversationScoped
• @Singleton
• You can create your own scope
38. CHOOSING THE RIGHT CONTEXT
@SessionScoped
public class CartBean {
public void addItem(Item item) {
...
}
}
39. CHOOSING THE RIGHT CONTEXT
@ApplicationScoped
public class CartBean {
public void addItem(Item item) {
...
}
}
40. CHOOSING THE RIGHT CONTEXT
@ApplicationScoped
public class CartBean {
public void addItem(Item item) {
...
}
}
FAIL !!!
41. CONVERSATION IS MANAGE BY DEV
@ConversationScoped
public class CartBean {
public void addItem(Item item) {
...
}
}
42. NEW CONTEXTS CAN BE CREATED
@ThreadScoped
public class CartBean {
public void addItem(Item item) {
...
}
}
44. CREATING BEAN FROM ANY CLASS
@Produces
public MyNonCDIClass myProducer() {
return new MyNonCdiClass();
}
...
@Inject
MyNonCDIClass bean;
45. PRODUCERS MAY HAVE A SCOPE
@Produces
@RequestScoped
public FacesContext produceFacesContext() {
return FacesContext.getCurrentInstance();
}
46. GETTING INFO FROM INJECTION POINT
@Produces
public Logger produceLog(InjectionPoint injectionPoint) {
return Logger.getLogger(injectionPoint.getMember()
.getDeclaringClass().getName());
}
48. A NICE WAY TO ADD DECOUPLING
public class FirstBean {
@Inject Event<Post> postEvent;
public void saveNewPost(Post myPost) {
postEvent.fire(myPost);
}
}
public class SecondBean {
public void listenPost(@Observes Post post) {
System.out.println("Received : " + evt.message());
}
}
49. EVENTS CAN BE QUALIFIED
public class FirstBean {
@Inject Event<Post> postEvent;
public void saveNewPost(Post myPost) {
postEvent.select(
new AnnotationLiteral()<French> {}).fire(myPost);
}
}
public class SecondBean {
// these 3 observers will be called
public void listenFrPost(@Observes @French Post post) {}
public void listenPost(@Observes Post post) {}
public void listenObject(@Observes Object obj) {}
// This one won’t be called
public void listenEnPost(@Observes @English Post post) {}
}
50. AS ALWAYS “NO TYPE ERASURE”
public class SecondBean {
// these observers will be resolved depending
// on parameter in event payload type
public void listenStrPost(@Observes Post<String> post) {}
public void listenNumPost(@Observes Post<Number> post) {}
}
51. SOME BUILT-IN EVENTS
public class SecondBean {
public void beginRequest(@Observes @Initialized(RequestScoped.class)
ServletRequest req) {}
public void endRequest(@Observes @Destroyed(RequestScoped.class)
ServletRequest req) {}
public void beginSession(@Observes @Initialized(SessionScoped.class)
HttpSession session) {}
public void endSession(@Observes @Destroyed(SessionScoped.class)
HttpSession session) {}
}
57. A DECORATOR
@Decorator
@Priority(Interceptor.Priority.APPLICATION)
public abstract class HelloDecorator implements HelloService {
// The decorated service may be restricted with qualifiers
@Inject @Delegate HelloService service;
public String hello() {
return service.hello() + "-decorated";
}
}
59. …IS USED TO BIND AN INTERCEPTOR
@Interceptor @Loggable
@Priority(Interceptor.Priority.APPLICATION)
public class LogInterceptor {
@AroundInvoke
public Object log(InvocationContext ic) throws Exception {
System.out.println("Entering " + ic.getMethod().getName());
try {
return ic.proceed();
} finally {
System.out.println("Exiting " + ic.getMethod().getName());
}
}
}
60. IT CAN BE PUT ON CLASS OR METHOD
@Loggable
public class MyBean {
@Inject HelloService service;
public void displayHello() {
display( service.hello();
}
}
61. THAT’S ALL FOR BASIC CDI
• If you want to learn advanced stuff come to check my over talk : CDI
advanced.
• follow @cdispec and @antoine_sd on twitter
• Questions ?