DSLs or Domain Specific Languages focus on a domain or a particular problem. They serve as an effective human-machine interaction tool as they’re highly expressive. Their scope is fairly focused and that keeps them simple and small from the user’s point of view. However, designing and implementing DSLs is not easy. Typically this involves steep learning curve and difficult parsing techniques. This is where Groovy comes in. You can take advantage of the flexible syntax of Groovy and its metaprogramming capability to create what are called internal DSLs, that is, DSLs hosted using a higher level language. This presentation will help you learn how to design and build internal DSLs in Groovy.
In this fast paced highly interactive presentation you will start out learning the characteristics and types of DSLs. Then you will learn about the challenges in designing DSLs and deep dive into Groovy features that can ease the pain of implementing DSLs. Then, using some live coding, the speaker will show you how to create and implement internal DSLs using Groovy. Along the way you’ll learn some tricks to facilitate desirable syntax for your DSL.
SlidesConcurrency is hard. The Java platform has a rich set of concurrency primitives, but it’s still possible to shoot yourself in the foot. In fact, concurrency makes it substantially more likely that you’ll shoot not just yourself but everyone else in the room. This session covers common concurrency gotchas on the Java platform, such as what NOT to synchronize on, inconsistent or missing locking, dangers of wait/notify, deadlock, safe publication, and visibility problems.
SlidesIn this session, Twitter engineer Alex Payne will explore how the popular social messaging service builds scalable, distributed systems in the Scala programming language. Since 2008, Twitter has moved the development of its most critical systems to Scala, which blends object-oriented and functional programming with the power, robust tooling, and vast library support of the Java Virtual Machine. Find out how to use the Scala components that Twitter has open sourced, and learn the patterns they employ for developing core infrastructure components in this exciting and increasingly popular language.
All functional programming languages emphasize working with immutable data as much as possible. How can that be efficient, and what benefits does it bring? And what happens when you need state, to manage changing values over time? One method is to use mutable references with concurrency semantics, such as transactions, coupled with persistent data structures. This combination makes for easy, lock-free designs, well within the comfort zone of those used to imperative programming. This talk discusses how immutability, state and identity are handled in the Clojure language.
Rails is, famously, “opinionated software.” With the advent of Rails 3, though, the framework is becoming more modular. But in more respects than people sometimes think, it always has been — and by the same token, Rails developers have always had to make choices as to how to handle various segments and components of their applications.
This talk will explore some of the nature of choice-making in Rails development, and will also get into some modularity specifics, including a demo of the ActiveModel API in Rails 3 using a GDBM-based replacement for ActiveRecord.
Have you been itching to try emerging technologies like Clojure, AMQP, Chef, Cucumber or JRuby? We’ll cover what happened to us when we proposed these hot (unproven!) new technologies, management said yes, and we had to deliver by sharing our story of building a message exchange in the financial industry. We think hearing our story will help give you the confidence to take these technologies into your own enterprise.
Even for those of us who are programmers but are not computer scientists, computer science insights and precepts have a lot to do with our bread and butter. Moreover, a small number of precepts seem to get most of the press. That suggests two courses of action: digging deeper for less well-known ideas from computer science, and making sure we’re dealing correctly and productively with the common ones.
This talk is about the second course of action. We’ll look at three familiar principles — the Law of Demeter, the Liskov Substitution Principle, and the less formal but perhaps even more famous “premature optimization” quotation — and, in each case, examine the specific relevance for Ruby. The talk will include comments on how people have applied the three principles to Ruby; whether or not such application has served the best interests of the principle(s) and/or Ruby; and how we can, as needed, take a fresh look at what might be gleaned from the principles.
As the open standard for web applications, HTML5 takes markup to a new level, requiring web developers and designers to re-examine the way they’ve worked in the past, and will be working in days and months to come. Presented by Molly E. Holzschlag, Web Standards advocate, evangelist, and developer relations team member at Opera Software, this talk helps demystify HTML5 as well as provide real-world insight into how to begin using aspects of the language today.