What is Scala
Piyush Katariya
corporate.piyush@gmail.com
About me
 Author

of “jHighFun”
 Visits localhost:8080 everyday
 Love to hate language which does not
support „function’ as first class citizen
 End to end system developer
 Agile practitioner
 Learning Haskell
This is for one who like to






Know(not learn) about Scala Programming Language
Increase software development productivity
Discover alternative, elegant JVM language other than Java
Search for less painful web application development
language
List of major frameworks available in Scala and their purpose
Why another JVM language(s)











Java bloated language specification sucks
Development productivity – Code less Do more
Treating best practices as Feature/Constructs
Higher level constructs
Less painful multithreaded/reactive programming
Choosing paradigm according to problem
Distributed computing with an ease
Less closer to von neumann arch.
More closer to business problem
Cool kids on JVM











Ceylon
Clojure
Groovy
JavaScript(Rhino, Nashorn)
JRuby
Jython
Kotlin
Scala
Xtend
Scala









OO, Functional, Statically typed
Designed by Martin Odersky
Needs JDK/JRE or CLR (.NET ) and its own SDK
Steep learning curve but worth the effort
Can speak and interact with JVM and libraries
Makes data computation fun
Inspired by






Haskell
Python
Ruby
Erlang
C#
Features in brief
















case class - only state, no behavior
trait - work out mixins, decorators and multiple inheritance
object - Singleton, only way to realize “static”
Function/closure/lambda - First class citizen
Tail recursion - recurs as if you are iterating, avoiding stack overflow
Higher Order Functions - Accept and return Function
Operator overloading - operator is actually a method name
Pattern Matching and Extractor - RIP “if” clause
Advanced Collections Library - Eager, Lazy, Born for computation
Co-variance and Contra-variance
XML - first class citizen, Native support for parsing
Actors and Futures - less painful concurrent programming
Implicit - Support the un-supported
Dependency Injection - using traits and self types
Combinator Parser - for DSL guys
SBT – Simple Build Tool
•
•
•
•
•
•

•
•
•
•
•
•

•

Little or no configuration required for simple projects
Scala-based build definition that can use the full flexibility of Scala code
Accurate incremental recompilation using information extracted from the compiler
Continuous compilation and testing with triggered execution
Packages and publishes jars
Generates documentation with scaladoc
Supports mixed Scala/Java projects
Supports testing with JUnit , ScalaCheck, specs, and ScalaTest.
Starts the Scala REPL with project classes and dependencies on the classpath
Modularization supported with sub-projects
External project support (list a git repository as a dependency!)
Parallel task execution, including parallel test execution
Library management support: inline declarations, external Ivy or Maven
configuration files, or manual management
Web App Frameworks









BlueEyes - Web 3.0 framework, purely asynchronous
Bowler - RESTful, Multi-Channel ready
Finagle - fault tolerant, protocol-agnostic network client and server
Lift – Comet support, Secure, Modular
Play – MVC, TypeSafe recommendation
Scalatra – inspired by Sinatra from Ruby
Spray - REST/HTTP-based integration layers on top of Akka
Other Frameworks/Library














Akka - High performance distributed computing
Anorm - smart alternative to JDBC
GridGain – in memory/cloud computing
Hammurabi – rule engine DSL
Kestrel - Tiny queue system based on starling
ReactiveMongo - Async mongodb client
Saddle - optimized data computation
Sandra – for Cassandra databse
Scalaz - extending scala API even further
Scalding - for elephant called Hadoop
Scaloid – simplifying android development
Slick - Scala collections to query your database
Squeryl - ORM and cleaner DSL for SQL database
Thank You

 Think

reactive. Happy coding 

What is scala

  • 1.
    What is Scala PiyushKatariya corporate.piyush@gmail.com
  • 2.
    About me  Author of“jHighFun”  Visits localhost:8080 everyday  Love to hate language which does not support „function’ as first class citizen  End to end system developer  Agile practitioner  Learning Haskell
  • 3.
    This is forone who like to      Know(not learn) about Scala Programming Language Increase software development productivity Discover alternative, elegant JVM language other than Java Search for less painful web application development language List of major frameworks available in Scala and their purpose
  • 4.
    Why another JVMlanguage(s)          Java bloated language specification sucks Development productivity – Code less Do more Treating best practices as Feature/Constructs Higher level constructs Less painful multithreaded/reactive programming Choosing paradigm according to problem Distributed computing with an ease Less closer to von neumann arch. More closer to business problem
  • 5.
    Cool kids onJVM          Ceylon Clojure Groovy JavaScript(Rhino, Nashorn) JRuby Jython Kotlin Scala Xtend
  • 6.
    Scala        OO, Functional, Staticallytyped Designed by Martin Odersky Needs JDK/JRE or CLR (.NET ) and its own SDK Steep learning curve but worth the effort Can speak and interact with JVM and libraries Makes data computation fun Inspired by      Haskell Python Ruby Erlang C#
  • 7.
    Features in brief                caseclass - only state, no behavior trait - work out mixins, decorators and multiple inheritance object - Singleton, only way to realize “static” Function/closure/lambda - First class citizen Tail recursion - recurs as if you are iterating, avoiding stack overflow Higher Order Functions - Accept and return Function Operator overloading - operator is actually a method name Pattern Matching and Extractor - RIP “if” clause Advanced Collections Library - Eager, Lazy, Born for computation Co-variance and Contra-variance XML - first class citizen, Native support for parsing Actors and Futures - less painful concurrent programming Implicit - Support the un-supported Dependency Injection - using traits and self types Combinator Parser - for DSL guys
  • 8.
    SBT – SimpleBuild Tool • • • • • • • • • • • • • Little or no configuration required for simple projects Scala-based build definition that can use the full flexibility of Scala code Accurate incremental recompilation using information extracted from the compiler Continuous compilation and testing with triggered execution Packages and publishes jars Generates documentation with scaladoc Supports mixed Scala/Java projects Supports testing with JUnit , ScalaCheck, specs, and ScalaTest. Starts the Scala REPL with project classes and dependencies on the classpath Modularization supported with sub-projects External project support (list a git repository as a dependency!) Parallel task execution, including parallel test execution Library management support: inline declarations, external Ivy or Maven configuration files, or manual management
  • 9.
    Web App Frameworks        BlueEyes- Web 3.0 framework, purely asynchronous Bowler - RESTful, Multi-Channel ready Finagle - fault tolerant, protocol-agnostic network client and server Lift – Comet support, Secure, Modular Play – MVC, TypeSafe recommendation Scalatra – inspired by Sinatra from Ruby Spray - REST/HTTP-based integration layers on top of Akka
  • 10.
    Other Frameworks/Library              Akka -High performance distributed computing Anorm - smart alternative to JDBC GridGain – in memory/cloud computing Hammurabi – rule engine DSL Kestrel - Tiny queue system based on starling ReactiveMongo - Async mongodb client Saddle - optimized data computation Sandra – for Cassandra databse Scalaz - extending scala API even further Scalding - for elephant called Hadoop Scaloid – simplifying android development Slick - Scala collections to query your database Squeryl - ORM and cleaner DSL for SQL database
  • 11.