ScalaDays
June 16th - 18th, Berlin
Ivan Yatskevich
Sergey Krauchenia
Scala: The Simple Parts
"Martin Odersky created Scala, a language that unifies constructs from both object oriented and functional
languages. This pisses off both groups and each promptly declares jihad."
- ~14 simple parts of Scala which Martin uses and is happy about
- Addressed several issues like CanBuildFrom
- Abstractions
- dotty
The Lost Art of Denotational Semantics
- Learning it will help you become better functional programmer
- Executable spec - converts syntax to semantics, semantics to almost executable
code. Written interpreter and compiler in 40 minutes
-
Teasing us, would be happy if 10-20 out of 800 people will understand the talk and learn more later.
Quote or be quoted
- Joy language implemented using quasiquotes
- A lot of code examples
Slick in the field, learning to forget ORM
- Generic DAO for slick
- Separate model from tables
- Separate queries from tables
- Id vs Object in relations
- In-Memory DB - bad choice for testing
Reactive Streams: And why you should care.
Video
Reactive Streams: And why you should care.
- Motivation behind reactive streams initiative
- Code examples, live coding
- Backpressure
- Streams are not collections - "like a river"
Without Past and Present
Video
Learn you an sbt for fun and profit!
- Intro to sbt
- Functional style - immutable, transformations
- keys, task keys, settings, autoplugins
- sbt-git, sbt-revolver
Play Framework - from 2.2 to 2.3 and Beyond
Video
Play Framework - from 2.2 to 2.3 and Beyond
- Performance improvements
- Last version in 2.x will be 2.4
- Play 3: DI, more Akka stuff inside, modularization
Resilient Applications with Akka Persistence
Video
Slides
Resilient Applications with Akka Persistence
- Event Sourcing
- CQRS
- Clustering problem solving
Lightning-Fast Standard Collections With ScalaBlitz
Video
Slides
Lightning-Fast Standard Collections With ScalaBlitz
- Standard collections with primitive types perf boost
- par.view != view.par
- foldLeft, foldRight cannot be truly parallel
- Operation fusion
- Deforestation
Simplifying Scala — The Past, Present and Future
Video
Slides
Simplifying Scala — The Past, Present and Future
- Deprecations of procedure syntax, view bounds
- Unit value insertion deprecated, will be removed
- Proposed to simplify partial function syntax, remove braces and case
- Avian VM - http://oss.readytalk.com/avian/
-
Idea from audience - experimental features can be implemented in Avian, and then proposed to
Oracle
Easy Metaprogramming For Everyone!
- scala.reflect: AST, Types, Symbols, Annotations and so on.
- New scala.meta, everything is represented with a tree
- No desugaring
- No need to place macro definition in another project
- IDE support for in-place macro expansion
- Store the whole program AST with bytecode, 20% overhead in size
- Better compilation support, more rigid
- Live coding, just quasiqoutes, easy as 1-2-3
- Coming this fall!
The no-framework Scala Dependency Injection Framework
Video
The no-framework Scala Dependency Injection Framework
- MacWire by example
- Play example
- Play team will work together with Adam on DI features in Play
DOT calculus
- Dependent Object Types
- Simplify Scala type system
- Simplify Scala type inference
- Type parameters => type members
- DRY
Building a Reactive Application
- DDD / CQRS / ES
- Immutable domain model
- Book promotion
Futures and Async: When to Use Which?
- Future vs Promise -> Use Future (most of the time)
- Futures in for-comprehension (sequential execution)
- Better control flow - async/await
- async/await limitations (Q&A)
RESTTest: exploring DSL design in Scala
- Start with a narration of a sentence
- Do not overuse syntactic extensions
-
Techniques
- Implicit conversions
- Implicit parameters
- Custom extractors
- Documentation is essential
Effective APIs
- Use meaningful types, not Long, Double, etc.
-
Error handling
- Null-object
- Either/Validation/Custom error
- Try/Future, Actors, System.exit()
- Binary-compatibility, backward-compatibility
- Java interop
Monitoring Akka
- Don't wait until 500 errors appear
- Typesafe Console failed under load :(
- "Reactive" Monitor
- AOP-based
- Various outputs