We aren't sure about you, but working with Java 8 made one of the speakers lose all of his hair and the other lose his sleep (or was it the jetlag?). If you still haven't reached the level of Brian Goetz in mastering lambdas and strings, this talk is for you. And if you think you have, we have some bad news for you, you should attend as well.
This document provides examples of refactoring Java code to use Guava libraries and utilities. It shows code snippets before and after refactoring to use Guava's Objects, Preconditions, Collections, Splitter, Joiner, Ranges and other utilities to clean up code and make it more readable and robust. Refactoring includes using Guava to validate arguments, create immutable collections, handle nulls safely, join/split strings, and represent ranges.
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
This document provides an overview and examples of using Google Guava, an open-source Java library that includes common libraries useful for writing Java code. It highlights some key classes and methods in Guava, including annotations, strings, collections, I/O, and more. Code samples demonstrate using Guava features like predicates, sets, files, and InetAddress utilities.
This document provides an overview of Guava, a common libraries project from Google that includes utilities for collections, caching, predicates and functions, I/O, and more. It highlights features like Optional for avoiding null checks, immutable collections, filtering collections, transforming collections, caching, and string/object utilities. The document also discusses when and where Guava can be used, such as for temporary collections, avoiding null checks, and leveraging a popular library maintained by others.
The document outlines an agenda for a Clojure meetup, including introductions to Clojure, incremental development with Clojure, Emacs and SLIME, Clojure STM, and a talk on optimization titled "Eratosthenes' Sieve: An Adventure in Optimization". It then provides examples of Clojure literals, collections, functions, macros, and interoperability with Java.
The core libraries you always wanted - Google GuavaMite Mitreski
Google Guava is a set of core Java libraries that includes collections, caching, predicates and functions, primitives support, and other utilities. It aims to fill in gaps in the Java class library and improve on Java SE classes. Some key features include optional types, immutable collections, caching utilities, character matching, and functional interfaces like predicates and functions. Guava provides utilities to avoid null checks, filter collections, transform values, and load resources. It also includes hashing, bloom filters, and other utilities. Using Guava can make code cleaner and safer by leveraging well-tested utilities rather than reimplementing functionality.
We aren't sure about you, but working with Java 8 made one of the speakers lose all of his hair and the other lose his sleep (or was it the jetlag?). If you still haven't reached the level of Brian Goetz in mastering lambdas and strings, this talk is for you. And if you think you have, we have some bad news for you, you should attend as well.
This document provides examples of refactoring Java code to use Guava libraries and utilities. It shows code snippets before and after refactoring to use Guava's Objects, Preconditions, Collections, Splitter, Joiner, Ranges and other utilities to clean up code and make it more readable and robust. Refactoring includes using Guava to validate arguments, create immutable collections, handle nulls safely, join/split strings, and represent ranges.
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
This document provides an overview and examples of using Google Guava, an open-source Java library that includes common libraries useful for writing Java code. It highlights some key classes and methods in Guava, including annotations, strings, collections, I/O, and more. Code samples demonstrate using Guava features like predicates, sets, files, and InetAddress utilities.
This document provides an overview of Guava, a common libraries project from Google that includes utilities for collections, caching, predicates and functions, I/O, and more. It highlights features like Optional for avoiding null checks, immutable collections, filtering collections, transforming collections, caching, and string/object utilities. The document also discusses when and where Guava can be used, such as for temporary collections, avoiding null checks, and leveraging a popular library maintained by others.
The document outlines an agenda for a Clojure meetup, including introductions to Clojure, incremental development with Clojure, Emacs and SLIME, Clojure STM, and a talk on optimization titled "Eratosthenes' Sieve: An Adventure in Optimization". It then provides examples of Clojure literals, collections, functions, macros, and interoperability with Java.
The core libraries you always wanted - Google GuavaMite Mitreski
Google Guava is a set of core Java libraries that includes collections, caching, predicates and functions, primitives support, and other utilities. It aims to fill in gaps in the Java class library and improve on Java SE classes. Some key features include optional types, immutable collections, caching utilities, character matching, and functional interfaces like predicates and functions. Guava provides utilities to avoid null checks, filter collections, transform values, and load resources. It also includes hashing, bloom filters, and other utilities. Using Guava can make code cleaner and safer by leveraging well-tested utilities rather than reimplementing functionality.
The document discusses Scala as a potential replacement for Java on the JVM. It provides quotes from several influential Java developers who express their view that Scala is the most capable replacement for Java currently available on the JVM, and the momentum behind Scala is growing. The document also briefly outlines an agenda for introducing Scala, covering basic syntax, patterns, functions, classes and traits.
The document discusses Kotlin collections and aggregate operations on collections. It explains that Kotlin collections can be mutable or immutable, and by default collections are immutable unless specified as mutable. It then covers various aggregate operations that can be performed on collections like any, all, count, fold, foldRight, forEach, max, min, none etc and provides code examples for each operation.
This document discusses ways to optimize Clojure code for performance. It shows examples of using primitive types, avoiding reflection, leveraging immutability, and minimizing comparisons and type checks. The author advocates understanding how Clojure code compiles and runs, and creating domain-specific abstractions when Clojure's general solutions are too pessimistic. Overall, the document explores techniques for writing Clojure programs that are predictably fast by avoiding overhead and making assumptions explicit.
The document discusses how monads can be used to prevent bugs and handle side effects like missing data in code. It provides examples of using Optional to represent missing values and chaining operations with flatMap to avoid nested if-checks. Monads allow sequencing computations in a declarative way while handling problems in the data or failures transparently.
The document discusses features of the Kotlin programming language. It provides examples of how Kotlin simplifies object-oriented programming tasks like data classes and property access compared to Java. Data classes in Kotlin can auto-generate getters, setters, equals(), hashCode() and toString() methods. Kotlin also allows functional-style programming with properties like immutable state and avoiding null references.
The document summarizes various functions in the Kotlin standard library including let, with, apply, run, also, takeIf, takeUnless, use, and repeat. It provides code examples to demonstrate how each function works and what it is commonly used for. let, with, apply, and also allow passing a receiver object to a lambda and accessing it as "it". takeIf and takeUnless return the receiver if a predicate is true or false, respectively. use automatically closes resources. repeat runs an action a specified number of times.
Курс "Программирование на Java". Лекция 07 "Бонус - Головоломки".
Java Puzzlers. Синхронизация и многопоточность. Примитивы. Объекты и классы. Исключения и финализация.
МФТИ, 2016 год. Лектор - Лаврентьев Федор Сергеевич
Помните легендарные Java Puzzlers? Да-да, те самые, с Джошом Блохом и Нилом Гафтером? Ну, по которым ещё книжку написали? Так вот, в Groovy всё ещё веселее.
В смысле — задачки ещё более странные, и ответы ещё более поразительные. Этот доклад для вас, Groovy-разработчики, мы покажем вам настоящие, большие и красивые подводные камни! И для вас, Java-разработчики, потому что таких вещей на Java-подобном синтакисе вы точно никогда не видели! И для вас, PHP-разработчики… хотя, нет, не для вас :)
Всем точно будет весело — ваши ведущие Женя и Барух будут зажигать, шутить, спорить, бросаться футболками в публику, и самое главное — заставят вас офигевать от Groovy.
Java Universal super class java.lang.Object is discussed comprehensively with code snippets.
Also covers:
a) Why we need inheritance and dynamic method dispatch
b) Need of a universal parent
c) Delegation and proxies
d) toString(), clone(), equals(), notify()
The document discusses using ES6 features in real-world applications. It provides examples of using arrow functions, classes, destructuring, template literals, and default parameters to write cleaner code. It also discusses tools for enabling ES6 features that are not yet fully supported, such as transpilers, and flags in Node.js and Chrome to enable more experimental features. Overall, the document advocates adopting ES6 features that make code more concise and readable.
Kotlin is a statically typed language that runs on the JVM, Android and browsers. It was developed by JetBrains and had its first stable release in February 2016. Some key features of Kotlin include null safety, lambdas, extension functions, and delegation which allow avoiding null checks and reducing boilerplate code compared to Java. It also integrates well with Android by reducing the need for findViewById and providing libraries like Anko that simplify common tasks. Performance tests have shown Kotlin to be as fast as Java.
Async code on kotlin: rx java or/and coroutines - Kotlin Night TurinFabio Collini
It’s never easy to write async code but luckily there are many libraries to manage asynchronicity without adding too much complexity. In the last years RxJava and the other ReactiveX libraries have been very popular but lately there is a new way to manage async code in Kotlin: the coroutines. In this talk we’ll pros and cons of there two approaches and how to leverage them to simplify asynchronous code on Android.
Do they solve the same problem? Can we use them together? Which one can be used to write functional code? How can we use them effectively in Android development?
Spoiler alert: They are both great!
In this talk we’ll see how to solve common problems using RxJava or Coroutines, starting from basic concepts (for example the Retrofit support and how to cancel a task) to some more advanced (like threading, error management and how to combine multiple tasks).
All example of the talk are available on this repository:
https://github.com/fabioCollini/RxJavaVsCoroutines
Continuation Passing Style and Macros in Clojure - Jan 2012Leonardo Borges
The document discusses continuation-passing style (CPS) in Clojure, where control is passed explicitly as a continuation argument to each function, and provides examples of implementing the Pythagorean theorem and Fibonacci sequence in CPS; it also explains how macros can be used to avoid deep nesting when accessing nested values and demonstrates a macro for this use case.
The Guava project contains several of Google’s core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth. There will be the slides presenting most useful and interesting features of Guava (v.12) that makes stuff simpler, better and code cleaner. We will cover most of the com.google.common.base.* classes and basic use of functions in collection and Google collections and few other features that are part of Guava and I find them very useful. Some of you will think that there is an overlap with Apache commons – and it’s true, but Guava is built with expectation that there is a Function and a Predicate class as well as various builders which makes it really cool and simple for many use cases.
Slides for presentation on Google Guava I gave at the Near Infinity (www.nearinfinity.com) 2013 spring conference.
The associated sample code is on GitHub at https://github.com/sleberknight/google-guava-samples
This presentation was given online in July 2017 and will be given at the NY Java SIG later this year. It progressively builds on Java 8 concepts using puzzles and coding to give students confidence in their Java 8 stream/lambda skills. Handouts and code in https://github.com/boyarsky/java-8-streams-by-puzzles
The document provides examples of Kotlin classes and properties compared to Java classes. Some key points summarized:
1. Kotlin classes can define properties directly rather than private fields with getters/setters like in Java. Properties are accessed directly rather than through getter methods.
2. Data classes provide equals(), hashCode(), toString() by default and allow destructuring declarations. Regular classes do not have these features by default.
3. Default values can be defined for properties in Kotlin classes, unlike Java where default values require a builder pattern.
The document appears to be a series of tips for writing clean, readable code in Groovy. Some of the key points mentioned include:
1. Write readable code and comment any tricks or non-obvious parts of the code.
2. Be aware that some clever code may actually be a bug.
3. Use static code analysis tools like IntelliJ IDEA to inspect code quality.
4. Refer to documentation when unsure rather than relying on tricks.
5. Avoid writing code in an overly clever or obfuscated way.
The groovy puzzlers (as Presented at JavaOne 2014)GroovyPuzzlers
Two guys are on stage asking funny and puzzling questions. The audience thinks about the questions and votes on the answers while T-shirts are thrown into the air. They provide their Twitter handle for people to follow.
The document discusses Scala as a potential replacement for Java on the JVM. It provides quotes from several influential Java developers who express their view that Scala is the most capable replacement for Java currently available on the JVM, and the momentum behind Scala is growing. The document also briefly outlines an agenda for introducing Scala, covering basic syntax, patterns, functions, classes and traits.
The document discusses Kotlin collections and aggregate operations on collections. It explains that Kotlin collections can be mutable or immutable, and by default collections are immutable unless specified as mutable. It then covers various aggregate operations that can be performed on collections like any, all, count, fold, foldRight, forEach, max, min, none etc and provides code examples for each operation.
This document discusses ways to optimize Clojure code for performance. It shows examples of using primitive types, avoiding reflection, leveraging immutability, and minimizing comparisons and type checks. The author advocates understanding how Clojure code compiles and runs, and creating domain-specific abstractions when Clojure's general solutions are too pessimistic. Overall, the document explores techniques for writing Clojure programs that are predictably fast by avoiding overhead and making assumptions explicit.
The document discusses how monads can be used to prevent bugs and handle side effects like missing data in code. It provides examples of using Optional to represent missing values and chaining operations with flatMap to avoid nested if-checks. Monads allow sequencing computations in a declarative way while handling problems in the data or failures transparently.
The document discusses features of the Kotlin programming language. It provides examples of how Kotlin simplifies object-oriented programming tasks like data classes and property access compared to Java. Data classes in Kotlin can auto-generate getters, setters, equals(), hashCode() and toString() methods. Kotlin also allows functional-style programming with properties like immutable state and avoiding null references.
The document summarizes various functions in the Kotlin standard library including let, with, apply, run, also, takeIf, takeUnless, use, and repeat. It provides code examples to demonstrate how each function works and what it is commonly used for. let, with, apply, and also allow passing a receiver object to a lambda and accessing it as "it". takeIf and takeUnless return the receiver if a predicate is true or false, respectively. use automatically closes resources. repeat runs an action a specified number of times.
Курс "Программирование на Java". Лекция 07 "Бонус - Головоломки".
Java Puzzlers. Синхронизация и многопоточность. Примитивы. Объекты и классы. Исключения и финализация.
МФТИ, 2016 год. Лектор - Лаврентьев Федор Сергеевич
Помните легендарные Java Puzzlers? Да-да, те самые, с Джошом Блохом и Нилом Гафтером? Ну, по которым ещё книжку написали? Так вот, в Groovy всё ещё веселее.
В смысле — задачки ещё более странные, и ответы ещё более поразительные. Этот доклад для вас, Groovy-разработчики, мы покажем вам настоящие, большие и красивые подводные камни! И для вас, Java-разработчики, потому что таких вещей на Java-подобном синтакисе вы точно никогда не видели! И для вас, PHP-разработчики… хотя, нет, не для вас :)
Всем точно будет весело — ваши ведущие Женя и Барух будут зажигать, шутить, спорить, бросаться футболками в публику, и самое главное — заставят вас офигевать от Groovy.
Java Universal super class java.lang.Object is discussed comprehensively with code snippets.
Also covers:
a) Why we need inheritance and dynamic method dispatch
b) Need of a universal parent
c) Delegation and proxies
d) toString(), clone(), equals(), notify()
The document discusses using ES6 features in real-world applications. It provides examples of using arrow functions, classes, destructuring, template literals, and default parameters to write cleaner code. It also discusses tools for enabling ES6 features that are not yet fully supported, such as transpilers, and flags in Node.js and Chrome to enable more experimental features. Overall, the document advocates adopting ES6 features that make code more concise and readable.
Kotlin is a statically typed language that runs on the JVM, Android and browsers. It was developed by JetBrains and had its first stable release in February 2016. Some key features of Kotlin include null safety, lambdas, extension functions, and delegation which allow avoiding null checks and reducing boilerplate code compared to Java. It also integrates well with Android by reducing the need for findViewById and providing libraries like Anko that simplify common tasks. Performance tests have shown Kotlin to be as fast as Java.
Async code on kotlin: rx java or/and coroutines - Kotlin Night TurinFabio Collini
It’s never easy to write async code but luckily there are many libraries to manage asynchronicity without adding too much complexity. In the last years RxJava and the other ReactiveX libraries have been very popular but lately there is a new way to manage async code in Kotlin: the coroutines. In this talk we’ll pros and cons of there two approaches and how to leverage them to simplify asynchronous code on Android.
Do they solve the same problem? Can we use them together? Which one can be used to write functional code? How can we use them effectively in Android development?
Spoiler alert: They are both great!
In this talk we’ll see how to solve common problems using RxJava or Coroutines, starting from basic concepts (for example the Retrofit support and how to cancel a task) to some more advanced (like threading, error management and how to combine multiple tasks).
All example of the talk are available on this repository:
https://github.com/fabioCollini/RxJavaVsCoroutines
Continuation Passing Style and Macros in Clojure - Jan 2012Leonardo Borges
The document discusses continuation-passing style (CPS) in Clojure, where control is passed explicitly as a continuation argument to each function, and provides examples of implementing the Pythagorean theorem and Fibonacci sequence in CPS; it also explains how macros can be used to avoid deep nesting when accessing nested values and demonstrates a macro for this use case.
The Guava project contains several of Google’s core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth. There will be the slides presenting most useful and interesting features of Guava (v.12) that makes stuff simpler, better and code cleaner. We will cover most of the com.google.common.base.* classes and basic use of functions in collection and Google collections and few other features that are part of Guava and I find them very useful. Some of you will think that there is an overlap with Apache commons – and it’s true, but Guava is built with expectation that there is a Function and a Predicate class as well as various builders which makes it really cool and simple for many use cases.
Slides for presentation on Google Guava I gave at the Near Infinity (www.nearinfinity.com) 2013 spring conference.
The associated sample code is on GitHub at https://github.com/sleberknight/google-guava-samples
This presentation was given online in July 2017 and will be given at the NY Java SIG later this year. It progressively builds on Java 8 concepts using puzzles and coding to give students confidence in their Java 8 stream/lambda skills. Handouts and code in https://github.com/boyarsky/java-8-streams-by-puzzles
The document provides examples of Kotlin classes and properties compared to Java classes. Some key points summarized:
1. Kotlin classes can define properties directly rather than private fields with getters/setters like in Java. Properties are accessed directly rather than through getter methods.
2. Data classes provide equals(), hashCode(), toString() by default and allow destructuring declarations. Regular classes do not have these features by default.
3. Default values can be defined for properties in Kotlin classes, unlike Java where default values require a builder pattern.
The document appears to be a series of tips for writing clean, readable code in Groovy. Some of the key points mentioned include:
1. Write readable code and comment any tricks or non-obvious parts of the code.
2. Be aware that some clever code may actually be a bug.
3. Use static code analysis tools like IntelliJ IDEA to inspect code quality.
4. Refer to documentation when unsure rather than relying on tricks.
5. Avoid writing code in an overly clever or obfuscated way.
The groovy puzzlers (as Presented at JavaOne 2014)GroovyPuzzlers
Two guys are on stage asking funny and puzzling questions. The audience thinks about the questions and votes on the answers while T-shirts are thrown into the air. They provide their Twitter handle for people to follow.
Highlights a bunch of different Python tricks and tips - from the stupid to the awesome (and a bit of both).
See how to register a 'str'.decode('hail_mary') codec, call_functions[1, 2, 3] instead of call_functions(1, 2, 3), creating a "Clojure-like" threading syntax by overloading the pipe operator, create useful equality mocks by overloading the equality operator, ditch JSON for pySON and put together a tiny lisp based on Norvig's awesome article.
The document discusses Groovy concepts including types, operators, objects, structures, closures, control structures, and methods for strings, lists, and maps. It covers topics such as optional syntax, imports, type checking, numbers, strings, GStrings, lists, maps, enums, operators, date/time operations, and closure usage including delegation and implicit parameters. Groovy allows for optional syntax elements, dynamic typing, closures, and methods to operate on common data types like strings, lists, and maps.
The groovy puzzlers (as Presented at Gr8Conf US 2014)GroovyPuzzlers
Remember the epic Java Puzzlers? Here’s the Groovy version, and we have some neat ones! Even though we are totally a Grails shop here at JFrog, some of these had us scratching our heads for days trying to figure them out.
And there is more! Contributions from the truly Groovy senseis, including @glaforge, @aalmiray, @tim_yates, @kenkousen make this talk an unforgettable journey to Groovy's O_O.
In this talk you’ll have the expected dose of fun and enlightenment hearing about our mistakes and failures, great and small, in hard core Groovy/Grails development.
Groovy is a dynamic language for the Java platform that provides features inspired by languages like Python, Ruby and Smalltalk. It allows Java developers to use these features with a syntax that is very similar to Java. Groovy code can be compiled to Java bytecode and integrated with Java applications and libraries. It supports features like closures, metaprogramming, builders and templates to improve developer productivity.
En esta charla veremos con detalle algunas de las construcciones más pythonicas y las posibilidades de expresar de forma clara, concisa y elegante cosas que en otros lenguajes nos obligarían a dar muchos rodeos.
A veces es fácil olvidar algunos recursos como que una función puede devolver varios valores, cómo manipular listas y diccionarios de forma sencilla, contextos, generadores... En esta charla veremos de forma entretenida y práctica cómo mejorar nuestro nivel de Python "nativo".
This document provides examples of Python code snippets covering various topics like Python basics (print, variables, data types), conditional statements (if-else), loops (for, while), functions, object oriented programming (classes, inheritance), file handling, modules, database connectivity (MySQL, Redis), XML/HTML parsing and web scraping. It also shows code for installing and importing various third party Python libraries and modules.
Ever wonder what this "new" Kotlin thing is? Curious what the syntax looks like? Unsure how to implement this at your own company? Or do you just want to know what Nick and Cody's favorite things are about this language?
All that and (maybe) more are revealed in Privet Kotlin.
The document provides examples of functions in Swift including:
1. A greet function that returns a personalized greeting string.
2. Functions that take closures or callbacks as parameters including examples of passing named closures and trailing closures.
3. Examples of functions that return tuples, optionals, and functions as their return type.
The document demonstrates various Swift function features like default parameters, inout parameters, variadic parameters, and functions as first-class citizens.
The document introduces Scala and provides an overview of Scala basics including variables, functions, objects, classes, traits, pattern matching, for-comprehensions and more. It also discusses Scala's capabilities for generic programming, lazy evaluation, and integration with Java. Examples are provided throughout to demonstrate Scala concepts.
This document discusses monads and continuations in functional programming. It provides examples of using monads like Option and List to handle failure in sequences of operations. It also discusses delimited continuations as a low-level control flow primitive that can implement exceptions, concurrency, and suspensions. The document proposes using monads to pass implicit state through programs by wrapping computations in a state transformer (ST) monad.
This document provides an introduction to jRuby, which allows Ruby code to be run on the Java Virtual Machine. It discusses the history and creator of Ruby, Yukihiro "Matz" Matsumoto, and his goals for the language. It then provides a primer on Ruby syntax including booleans, strings, numbers, arrays, hashes, symbols, and classes. It demonstrates how Ruby code can interact with Java code when using jRuby, such as calling Java classes and methods from Ruby. It also discusses metaprogramming in Ruby and how jRuby enables cross-platform GUI development using Java libraries.
This document provides an overview and introduction to CoffeeScript, a programming language that compiles to JavaScript. It shows how CoffeeScript code compiles to equivalent JavaScript code, and demonstrates CoffeeScript features like functions, classes, and object-oriented programming. The document introduces CoffeeScript syntax for arrays, objects, loops, and functions, and compares syntax to JavaScript. It also covers CoffeeScript concepts like scoping, context, and class-based object-oriented programming using prototypes.
The document discusses ES6 patterns used in Redux code. It explains how Redux uses functional programming patterns like higher-order functions, pure functions, and immutable data structures. Specifically, it analyzes code from Redux that uses arrow functions, rest/spread syntax, and avoids mutations to create middleware and handle state updates immutably. Reading wild code helps improve the skill of code comprehension and builds intuition about how to apply new patterns.
The document discusses functional programming concepts like pure functions, immutable data, and avoiding side effects. It compares imperative programming constructs like loops and mutable state to functional alternatives like map, filter, reduce. It argues that a functional style enables better reasoning about programs by avoiding side effects and complex control flow. Specific examples show transforming an imperative loop into a functional map and handling asynchronous code through chained promises or futures. Overall it advocates for a functional programming approach.
Similar to The Groovy Puzzlers – The Complete 01 and 02 Seasons (20)
DevOps Patterns & Antipatterns for Continuous Software Updates @ NADOG April ...Baruch Sadogursky
The document discusses patterns and antipatterns for continuous software updates. It describes challenges with continuous updates including things that can go wrong with updates and solutions like local rollbacks, over-the-air updates, continuous rather than batch updates, automated deployments, frequent updates, state awareness, progressive delivery, observability, rollbacks, and feature flags. The goal is to transition to extremely tiny and frequent updates, called Liquid Software, to provide an illusion of software flowing continuously from development to the target.
So, you want to update the software for your user, be it the nodes in your K8s cluster, a browser on user’s desktop, an app in user’s smartphone or even a user’s car. What can possibly go wrong?
In this talk, we’ll analyze real-world software update fails and how multiple DevOps patterns, that fit a variety of scenarios, could have saved the developers. Manually making sure that everything works before sending an update and expecting the user to do acceptance tests before they update is most definitely not on the list of such patterns.
Join us for some awesome and scary continuous update horror stories and some obvious (and some not so obvious) proven ideas for improvement and best practices you can start following tomorrow.
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Oracle Code NY...Baruch Sadogursky
In this talk, we’ll take you to a scaling journey, from 3 developers to a 100. We’ll talk about the challenges each milestone in this growth brings, both technological and methodological, and how to solve those challenges using the right mix of people, the right selection of tools and the correctly crafted process. The speakers excel in the different aspects of this triangle and went through this journey (more than once) themselves. And the fun and entertaining presentation as a Greek tragedy can’t hurt, can it?
Data driven devops as presented at QCon London 2018Baruch Sadogursky
Devops is usually viewed from a traditional perspective of a collaboration of Dev, Ops, and QA, driven by the change in Culture, People, and Process. But how do you know where you stand and where to move? As in almost any field, data and metrics give you the gauges and instruments. In this talk, we’ll talk about the key measurements for the DevOps transformation process and provide you with 3 metrics you can start measuring tomorrow.
A Research Study Into DevOps Bottlenecks as presented at Oracle Code LA 2018Baruch Sadogursky
We asked the Fortune 500 software delivery leaders what holds them back. This talk is the analysis of their insights on what bottlenecks they encountered in their DevOps journey.
You know what to expect by now: funny and puzzling questions about Java 8 and Java 9, JFrog t-shirts are airborne, the usual combo of learning and fun ahead!
Where the Helm are your binaries? as presented at Canada Kubernetes MeetupsBaruch Sadogursky
Do you always know what’s going on with your product artifacts since the moment they are built by the CI server from Git sources all the way to being deployed by Helm into Kuberenetes?
In this talk, we will show how to build a reliable and transparent pipeline from code to cluster using Git, Artifactory, Docker, Kubernetes, and Helm. We’ll show how you such a pipeline can help you answer the big questions: What to deploy, What is deployed, and what is this artifact that I am looking for. This kind of transparency is critical for today’s environments, and Kubernetes with Helm shouldn’t be an exception.
By Baruch Sadogursky
Devops is usually viewed from a traditional perspective of a collaboration of Dev, Ops and QA, driven by the change in Culture, People and Process. But how do you know where you stand and were to move? As in almost any field, data and metrics give you the gauges and instruments. In this talk we’ll talk about the key measurements for the DevOps transformation process and provide you with 3 metrics you can start measuring tomorrow.
A Research Study into DevOps Bottlenecks as presented at Codemash 2018Baruch Sadogursky
By Baruch Sadogursky
We asked the Fortune 500 software delivery leaders what holds them back. This talk is the analysis of their insights on what bottlenecks they encountered in their DevOps journey.
Best Practices for Managing Docker Versions as presented at JavaOne 2017Baruch Sadogursky
By Baruch Sadogursky
There are three hard things in computer science: cache invalidation, naming things, and off-by-one errors. This session tackles naming, especially Docker version naming. Labels, tags, checksums...how should you use them to keep track of Docker versions? What about dev versus prod images—how best to distinguish those? What about the “latest” tag? What about cleanup? Could we do more? Versioning often seems like a simple problem, but when you have a tool that gives you as much power and flexibility as Docker does, it often helps to develop guidelines. The presentation examines the tools available for managing Docker images and some simple patterns you can employ in various use cases for CI/CD to keep track of your containers.
Troubleshooting & Debugging Production Microservices in Kubernetes as present...Baruch Sadogursky
Debugging applications in production is like being the detective in a crime movie. Especially with microservices. Especially with containers. Especially in the cloud. Trying to see what’s going on in a production deployment at scale is impossible without proper tools! Google has spent over a decade deploying containerized Java applications at unprecedented scale and the infrastructure and tools developed by Google have made it uniquely possible to manage, troubleshoot, and debug, at scale.
Join this session to see how you can diagnose and troubleshoot production issues w/ out of the box Kubernetes tools, as well as getting insight from the ecosystem with Weave Scope, JFrog Artifactory & Stackdriver tools.
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Devoxx 2017Baruch Sadogursky
As in a good Greek Tragedy, scaling devops to big teams has 3 stages and usually end badly. In this play (it’s more than a talk!) we’ll present you with Pentagon Inc, and their way to scaling devops from a team of 3 engineers to a team of 100 (spoiler – it’s painful!)
Amazon Alexa Skills vs Google Home Actions, the Big Java VUI Faceoff as prese...Baruch Sadogursky
In this session we will compare and contrast the experience of implementing voice user interface for the two market leader voice activated assistants. Both are extendable, both have Java APIs, but which is better? Two speakers, two laptops, two IDEs writing Java code to implement the same Alexa Skill and Google Home Action and you pick the winner!
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at DevOps Days Be...Baruch Sadogursky
As in a good Greek Tragedy, scaling devops to big teams has 3 stages and usually end badly. In this play (it’s more than a talk!) we’ll present you with Pentagon Inc, and their way to scaling devops from a team of 3 engineers to a team of 100 (spoiler – it’s painful!)
Java Puzzlers NG S02: Down the Rabbit Hole as it was presented at The Pittsbu...Baruch Sadogursky
Moar puzzlers! The more we work with Java 8, the more we go into the rabbit hole. Did they add all those streams, lambdas, monads, Optionals and CompletableFutures only to confuse us? It surely looks so! And Java 9 that heads our way brings even more of what we like the most, more puzzlers, of course! In this season we as usual have a great batch of the best Java WTF, great jokes to present them and great prizes for the winners!
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at The Pittsburgh...Baruch Sadogursky
As in a good Greek Tragedy, scaling devops to big teams has 3 stages and usually end badly. In this play (it’s more than a talk!) we’ll present you with Pentagon Inc, and their way to scaling devops from a team of 3 engineers to a team of 100 (spoiler – it’s painful!)
Developer relations strategy is often an afterthought. This session’s speaker asks whether that’s OK and gets the opinion of DevRel leaders from companies large and small.
In this talk, Baruch Sadogursky presents the challenges of a high demand SaaS product incident triage at scale, as well as discuss the sources of log items, including the platform, tenants and other types of log sources. He will show practical examples of collector and filters configuration and will take you through a number of real world examples of problems investigations using Artifactory and Sumo Logic.
[Webinar] The Frog And The Butler: CI Pipelines For Modern DevOpsBaruch Sadogursky
No relationship in DevOps is more important than that between your CI/CD server and your Binary Repository. Jenkins has long been the go-to server for CI/CD, and JFrog Artifactory has long been one of the most popular integrations with it. This webinar focuses on the new features of the integration, leveraging the Jenkins Pipeline DSL for infrastructure-as-code of your favorite artifactory features whether it be generic, maven, gradle or Docker, and will show an end-to-end example of pipelines across multiple technologies and how powerful these new capabilities are.
Patterns and antipatterns in Docker image lifecycle as was presented at DC Do...Baruch Sadogursky
While Docker has enabled an unprecedented velocity of software production, it is all too easy to spin out of control. A promotion-based model is required to control and track the flow of Docker images as much as it is required for a traditional software development lifecycle. New tools often introduce new paradigms. We will examine the patterns and the antipatterns for Docker image management, and what impact the new tools have on the battle-proven paradigms of the software development lifecycle.
GraphSummit Paris - The art of the possible with Graph TechnologyNeo4j
Sudhir Hasbe, Chief Product Officer, Neo4j
Join us as we explore breakthrough innovations enabled by interconnected data and AI. Discover firsthand how organizations use relationships in data to uncover contextual insights and solve our most pressing challenges – from optimizing supply chains, detecting fraud, and improving customer experiences to accelerating drug discoveries.
SOCRadar's Aviation Industry Q1 Incident Report is out now!
The aviation industry has always been a prime target for cybercriminals due to its critical infrastructure and high stakes. In the first quarter of 2024, the sector faced an alarming surge in cybersecurity threats, revealing its vulnerabilities and the relentless sophistication of cyber attackers.
SOCRadar’s Aviation Industry, Quarterly Incident Report, provides an in-depth analysis of these threats, detected and examined through our extensive monitoring of hacker forums, Telegram channels, and dark web platforms.
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Łukasz Chruściel
No one wants their application to drag like a car stuck in the slow lane! Yet it’s all too common to encounter bumpy, pothole-filled solutions that slow the speed of any application. Symfony apps are not an exception.
In this talk, I will take you for a spin around the performance racetrack. We’ll explore common pitfalls - those hidden potholes on your application that can cause unexpected slowdowns. Learn how to spot these performance bumps early, and more importantly, how to navigate around them to keep your application running at top speed.
We will focus in particular on tuning your engine at the application level, making the right adjustments to ensure that your system responds like a well-oiled, high-performance race car.
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsPeter Muessig
The UI5 tooling is the development and build tooling of UI5. It is built in a modular and extensible way so that it can be easily extended by your needs. This session will showcase various tooling extensions which can boost your development experience by far so that you can really work offline, transpile your code in your project to use even newer versions of EcmaScript (than 2022 which is supported right now by the UI5 tooling), consume any npm package of your choice in your project, using different kind of proxies, and even stitching UI5 projects during development together to mimic your target environment.
Graspan: A Big Data System for Big Code AnalysisAftab Hussain
We built a disk-based parallel graph system, Graspan, that uses a novel edge-pair centric computation model to compute dynamic transitive closures on very large program graphs.
We implement context-sensitive pointer/alias and dataflow analyses on Graspan. An evaluation of these analyses on large codebases such as Linux shows that their Graspan implementations scale to millions of lines of code and are much simpler than their original implementations.
These analyses were used to augment the existing checkers; these augmented checkers found 132 new NULL pointer bugs and 1308 unnecessary NULL tests in Linux 4.4.0-rc5, PostgreSQL 8.3.9, and Apache httpd 2.2.18.
- Accepted in ASPLOS ‘17, Xi’an, China.
- Featured in the tutorial, Systemized Program Analyses: A Big Data Perspective on Static Analysis Scalability, ASPLOS ‘17.
- Invited for presentation at SoCal PLS ‘16.
- Invited for poster presentation at PLDI SRC ‘16.
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j
Dr. Jesús Barrasa, Head of Solutions Architecture for EMEA, Neo4j
Découvrez les dernières innovations de Neo4j, et notamment les dernières intégrations cloud et les améliorations produits qui font de Neo4j un choix essentiel pour les développeurs qui créent des applications avec des données interconnectées et de l’IA générative.
SMS API Integration in Saudi Arabia| Best SMS API ServiceYara Milbes
Discover the benefits and implementation of SMS API integration in the UAE and Middle East. This comprehensive guide covers the importance of SMS messaging APIs, the advantages of bulk SMS APIs, and real-world case studies. Learn how CEQUENS, a leader in communication solutions, can help your business enhance customer engagement and streamline operations with innovative CPaaS, reliable SMS APIs, and omnichannel solutions, including WhatsApp Business. Perfect for businesses seeking to optimize their communication strategies in the digital age.
Atelier - Innover avec l’IA Générative et les graphes de connaissancesNeo4j
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Allez au-delà du battage médiatique autour de l’IA et découvrez des techniques pratiques pour utiliser l’IA de manière responsable à travers les données de votre organisation. Explorez comment utiliser les graphes de connaissances pour augmenter la précision, la transparence et la capacité d’explication dans les systèmes d’IA générative. Vous partirez avec une expérience pratique combinant les relations entre les données et les LLM pour apporter du contexte spécifique à votre domaine et améliorer votre raisonnement.
Amenez votre ordinateur portable et nous vous guiderons sur la mise en place de votre propre pile d’IA générative, en vous fournissant des exemples pratiques et codés pour démarrer en quelques minutes.
Takashi Kobayashi and Hironori Washizaki, "SWEBOK Guide and Future of SE Education," First International Symposium on the Future of Software Engineering (FUSE), June 3-6, 2024, Okinawa, Japan
What is Augmented Reality Image Trackingpavan998932
Augmented Reality (AR) Image Tracking is a technology that enables AR applications to recognize and track images in the real world, overlaying digital content onto them. This enhances the user's interaction with their environment by providing additional information and interactive elements directly tied to physical images.
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j
Dr. Jesús Barrasa, Head of Solutions Architecture for EMEA, Neo4j
Découvrez les dernières innovations de Neo4j, et notamment les dernières intégrations cloud et les améliorations produits qui font de Neo4j un choix essentiel pour les développeurs qui créent des applications avec des données interconnectées et de l’IA générative.
UI5con 2024 - Keynote: Latest News about UI5 and it’s EcosystemPeter Muessig
Learn about the latest innovations in and around OpenUI5/SAPUI5: UI5 Tooling, UI5 linter, UI5 Web Components, Web Components Integration, UI5 2.x, UI5 GenAI.
Recording:
https://www.youtube.com/live/MSdGLG2zLy8?si=INxBHTqkwHhxV5Ta&t=0
Most important New features of Oracle 23c for DBAs and Developers. You can get more idea from my youtube channel video from https://youtu.be/XvL5WtaC20A
Hand Rolled Applicative User ValidationCode KataPhilip Schwarz
Could you use a simple piece of Scala validation code (granted, a very simplistic one too!) that you can rewrite, now and again, to refresh your basic understanding of Applicative operators <*>, <*, *>?
The goal is not to write perfect code showcasing validation, but rather, to provide a small, rough-and ready exercise to reinforce your muscle-memory.
Despite its grandiose-sounding title, this deck consists of just three slides showing the Scala 3 code to be rewritten whenever the details of the operators begin to fade away.
The code is my rough and ready translation of a Haskell user-validation program found in a book called Finding Success (and Failure) in Haskell - Fall in love with applicative functors.
18. 1. Two entertaining guys on stage
2. Funny Puzzling questions
3. You think and vote
4. Lots of T-shirts flying in the air
5. Official twitter handle!
groovypuzzlers
81. TreaayeMap a = [5]
@groovy.transform.InheritConstructors
class TreaayeMap extends HashMap {
}
82. TreaayeMap a = [5]
@groovy.transform.InheritConstructors
class TreaayeMap extends HashMap {
}
/**
* Constructs an empty <tt>HashMap</tt> with the specified initial
* capacity and the default load factor (0.75).
*
* @param initialCapacity the initial capacity.
* @throws IllegalArgumentException if the initial capacity is negative.
*/
public HashMap(int initialCapacity)
83.
84.
85.
86.
87. A. def beast = '6' * Math.PI
B. def beast = '6' * '3'
C. def beast = '667' – 1
D. def beast = '6' + '6' + 0 + 6
92. /**
* Repeat a String a certain number of times.
*
* @param self a String to be repeated
* @param factor the number of times the String should be repeated
* @return a String composed of a repetition
* @throws IllegalArgumentException if the number of repetitions is < 0
* @since 1.0
*/
public static String multiply(String self, Number factor) {
int size = factor.intValue();
…
}
95. B. def beast = '6' * '3'
C. def beast = '667' – 1
D. def beast = '6' + '6' + 0 + 6
96. B. def beast = '6' * '3'
C. def beast = '667' – 1
D. def beast = '6' + '6' + (0 + 6)
97. B. def beast = '6' * '3'
C. def beast = '667' – 1
D. def beast = '6' + '6' + (0 + 6)
Yup, I am
watching you!
98.
99.
100. class THERE_CAN_BE_ONLY_ONE { }
class MacLeod {
THERE_CAN_BE_ONLY_ONE getTHERE_CAN_BE_ONLY_ONE() {
Class clazz = THERE_CAN_BE_ONLY_ONE
return clazz.newInstance()
}
}
println new MacLeod().THERE_CAN_BE_ONLY_ONE
101. class THERE_CAN_BE_ONLY_ONE { }
class MacLeod {
THERE_CAN_BE_ONLY_ONE
getTHERE_CAN_BE_ONLY_ONE() {
Class clazz = THERE_CAN_BE_ONLY_ONE
return clazz.newInstance()
}
}
println new MacLeod().THERE_CAN_BE_ONLY_ONE
A. Won't start
B. No such property: THERE_CAN_BE_ONLY_ONE for class:
MacLeod
C. THERE_CAN_BE_ONLY_ONE@3d74bf60
D. Another Exception
132. ArrayList<String> expendables = ['Arnold', 'Chuck', 'Sylvester']
def expendable = //someone from the list
for(String hero in expendables) {
if(hero == expendable){
expendables.remove(hero)
}
}
println expendables
133. ArrayList<String> expendables = ['Arnold', 'Chuck', 'Sylvester']
def expendable = //someone from the list
for(String hero in expendables) {
if(hero == expendable){
expendables.remove(hero)
}
}
println expendables
A.Can't avoid CME
B.Arnold
C.Chuck
D.Sylvester
Which one won’t cause a
ConcurrentModificationException?
139. while(iterator.hasNext()) {
String hero = (String)iterator.next();
if(hero.equals(expendable)) {
// expendables.remove(hero);
}
}
public E next() {
checkForComodification();
…
cursor = i + 1;
}
Modifications are only
checked in the next
cycle
Getting ready for
hasNext() check in the
next cyclepublic boolean hasNext() {
return cursor != size();
}
Exit on last element +1 ==
size()
140. while(iterator.hasNext()) {
String hero = (String)iterator.next();
if(hero.equals(expendable)) {
// expendables.remove(hero);
}
}
public E next() {
checkForComodification();
…
cursor = i + 1;
}
public boolean hasNext() {
return cursor != size();
}
After Sylvester cursor is 3
And size is 3 as well
All good. Now let’s mess with it.
141. while(iterator.hasNext()) {
String hero = (String)iterator.next();
if(hero.equals(expendable)) {
expendables.remove(hero);
}
}
public E next() {
checkForComodification();
…
cursor = i + 1;
}
public boolean hasNext() {
return cursor != size();
}
After Chuck the cursor is 2
And now the size now is 2!
It won’t get to the next() to run checkForComodification!
Then we remove the element
142.
143. while(iterator.hasNext()) {
String hero = (String)iterator.next();
if(hero.equals(expendable)) {
expendables.remove(hero);
}
}
public E next() {
checkForComodification();
…
cursor = i + 1;
}
public boolean hasNext() {
return cursor != size();
}
After Sylvester the cursor is
3
But the size now is 2!
It will go to another loop and fail on checkForComodification!
Then we remove the element
211. List<Long> list = [1,2,3]
def now = new Date()
list << now
println list
212. List<Long> list = [1,2,3]
def now = new Date()
list << now
println list
213.
214.
215.
216.
217. List<Long> list = [1,2,3]
def now = new Date()
list << now
list << 'foo'
println list*.class.name
[java.lang.Long, java.lang.Long,
java.lang.Long, java.util.Date,
java.lang.String]
218.
219.
220. class VanHalen {
public static jump() {
"Here are the ${lyrics()}"
}
def methodMissing(String name, def args) {
'lyrics'
}
}
println VanHalen.jump()
221. class VanHalen {
public static jump()
{
"Here are the
${lyrics()}"
}
def
methodMissing(String
name, def args) {
'lyrics'
}
}
222.
223.
224.
225.
226. class VanHalen {
public static jump() {
"Here are the ${lyrics()}"
}
static $static_methodMissing(String name, def args) {
'lyrics'
}
}
println VanHalen.jump()
227. class VanHalen {
public jump() {
"Here are the ${lyrics()}"
}
def methodMissing(String name, def args) {
'lyrics'
}
}
println new VanHalen().jump()
228.
229. class Invite {
int attending = 1
}
def invite = new Invite()
def attendees = (invite.attending) +1
println attendees
230. class Invite {
int attending = 1
}
def invite = new Invite()
def attendees = (invite.attending) +1
println attendees
231.
232.
233.
234.
235.
236. def attendees = (new Invite().attending) + 1
println attendees
def invite = new Invite()
println (invite.attending +1)
237.
238.
239. def back = 'back'
def quotes = ["I'll be $back",
"I'll be ${-> back}",
"I'll be ${back}",
"I'll be "+back]
println quotes
back = 'Bach'
println quotes
240.
241.
242. def back = 'back'
def quotes = ["I'll be $back",
"I'll be ${-> back}",
"I'll be ${back}",
"I'll be "+back]
243. def back = 'back'
def quotes = ["I'll be $back",
"I'll be ${-> back}",
"I'll be ${back}",
"I'll be "+back]
That is the only closure
244.
245.
246. String truth = 'false'
boolean groovyTruth = truth
println groovyTruth
247. String truth = 'false'
boolean groovyTruth = truth
println groovyTruth
274. 1. Write readable code
2. Comment neat tricks
3. Sometimes it is just a bug
4. Use static code analysis (intellij IDEA!)
5. Rtfm
6. Don’t code like my brother
275. We have just started!
(may end up in proper uniform)
Puzzlers? Gotchas? Fetal position inducing behavior?
- puzzlers jfrog.com
- Groovypuzzlers
276.
277. Positive feedback?
Praise us on twitter
groovypuzzlers
- Groovypuzzlers
- ryanvanderwerf
- jbaruch
Negative feeback?
/dev/null
Editor's Notes
CURRENT – JB
NEXT - FRED
2001 OracleWorld: Joshua Bloch, Neal Gafter
CURRENT – JB
NEXT - FRED
The Car Show (1977-2012) Click and Clack, the Tappet Brothers - Tom and Ray Magliozzi
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – FRED
NEXT - FRED
CURRENT – FRED
NEXT - FRED
CURRENT – FRED
NEXT - FRED
CURRENT – FRED
NEXT - FRED
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – FRED
NEXT - JB
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
CURRENT – JB
NEXT - FRED
https://github.com/SerCeMan
@tolkv
@tolkv
@tolkv
@tolkv
@tolkv
@tolkv
@tolkv
Normal operation: exists after element 2, when cursor is already 3 and size is 3
With deletion exits after 2, because cursor is on 2 and size became 2!
With deletion exits after 2, because cursor is on 2 and size became 2!