This document discusses Scala adoption in the enterprise. It describes how Scala was used to build OpenGenesis, an open-source deployment orchestration tool that was successfully deployed in a large financial institution. While Scala works well with common J2EE patterns like Spring MVC, Spring, and JPA/Squeryl, there are challenges around hiring Scala developers and establishing coding standards. The greatest challenges are cultural and involve people.
Scala.js is a compiler that compiles Scala source code to equivalent Javascript code. It can be seen as the start of a revolution in developing web application. In this talk, I'll present Scala.js project, common libraries for having a pleasure web development (such as scalatags, autowire and upickle) and integration with well known javascript libraries such as AngularJS and React.js.
Scala.js is a compiler that compiles Scala source code to equivalent Javascript code. That lets you write Scala code that you can run in a web browser, or other environments (Chrome plugins, Node.js, etc.) where Javascript is supported. This presentation is an introduction to ScalaJS.
Game On! (@gameontext – http://game-on.org) is an awesome throwback text-based adventure built with microservices. Completely open source, it enables everyone to choose their own adventure to learn about microservices concepts while extending the game. One of the core services is the Map, which maintains a two-dimensional map containing all the registered rooms. The Map started with a document store as a back end, but as the Map changed over time, tombstones started to accrue. And then people started to ask how to manage three dimensions, and dragons appeared. Come to this session to find out why the decision was made to change the NoSQL back end, how it was done, and the result of the change with a new NoSQL API (http://jnosql.org/).
JNoSQL is a framework and collection of tools that make integration between Java applications and NoSQL quick and easy—for developers as well as vendors. The API is easy to implement, so NoSQL vendors can quickly implement, test, and become compliant by themselves. And with its low learning curve and just a minimal set of artifacts, Java developers can start coding by worrying not about the complexity of specific NoSQL databases but only their core aspects (such as graph or document properties). Built with functional programming in mind, it leverages all the features of Java 8. This session covers how the API is structured, how it relates to the multiple NoSQL database types, and how you can get started and involved in this open source technology.
Scala.js is a compiler that compiles Scala source code to equivalent Javascript code. It can be seen as the start of a revolution in developing web application. In this talk, I'll present Scala.js project, common libraries for having a pleasure web development (such as scalatags, autowire and upickle) and integration with well known javascript libraries such as AngularJS and React.js.
Scala.js is a compiler that compiles Scala source code to equivalent Javascript code. That lets you write Scala code that you can run in a web browser, or other environments (Chrome plugins, Node.js, etc.) where Javascript is supported. This presentation is an introduction to ScalaJS.
Game On! (@gameontext – http://game-on.org) is an awesome throwback text-based adventure built with microservices. Completely open source, it enables everyone to choose their own adventure to learn about microservices concepts while extending the game. One of the core services is the Map, which maintains a two-dimensional map containing all the registered rooms. The Map started with a document store as a back end, but as the Map changed over time, tombstones started to accrue. And then people started to ask how to manage three dimensions, and dragons appeared. Come to this session to find out why the decision was made to change the NoSQL back end, how it was done, and the result of the change with a new NoSQL API (http://jnosql.org/).
JNoSQL is a framework and collection of tools that make integration between Java applications and NoSQL quick and easy—for developers as well as vendors. The API is easy to implement, so NoSQL vendors can quickly implement, test, and become compliant by themselves. And with its low learning curve and just a minimal set of artifacts, Java developers can start coding by worrying not about the complexity of specific NoSQL databases but only their core aspects (such as graph or document properties). Built with functional programming in mind, it leverages all the features of Java 8. This session covers how the API is structured, how it relates to the multiple NoSQL database types, and how you can get started and involved in this open source technology.
Collections are a staple in any programming language: the need to collect, sort, or iterate over values is needed by nearly all developers. The Java language introduced the Collections framework long ago. It has plenty to offer, but many find it lacking: the number of collection libraries as active open source projects demonstrates the need for something else. This session does a holistic comparison of the most-common collections (pun intended!) frameworks, what they have to offer, and what you should consider for your next project. It also shows common programmer use cases; how each library handles them; and the impact on memory, processing power, and ease of use/coding. Come and let us help you choose the right bag for your tricks!
From the Scalapeño 2013 conference: http://scalapeno.underscore.co.il/
It’s no secret that in Israel, C# is one of the leading languages for development. This stems from various reasons, ranging from the power of the language to the ubiquity of Microsoft’s technologies in government and defense organizations. When it first came out, C# was Microsoft’s answer to Java and the two were on-par. Since then, C# has grown leaps and bounds and Java, while still sitting on top of the powerful JVM with a huge, open ecosystem created over nearly two decades, was left behind. Developers looking to stop paying the Microsoft-tax were faced with a language that simply did not meet their expectations.
Scala is the one of the answers to this growing need for a new, modern language for the JVM.
This lecture introduces the language, comparing its idioms to those of C#, and introduces you some of the tools and frameworks to get you started with it.
Production debugging is hard, and it’s getting harder. With architectures becoming more distributed and code more asynchronous and reactive, pinpointing and resolving errors that happen in production is no child’s game. This session covers some essential tools and more advanced techniques Scala developers can use to debug live applications and resolve errors quickly. It explores crucial techniques for distributed debugging - and some of the pitfalls that make resolution much harder, and can lead to downtime. The talk also touches on some little-known JVM tools and capabilities that give you super-deep visibility at high scale without making you restart it or attach debuggers.
10 SQL Tricks that You Didn't Think Were PossibleLukas Eder
SQL is the winning language of Big Data. Whether you’re running a classic relational database, a column store (“NewSQL”), or a non-relational storage system (“NoSQL”), a powerful, declarative, SQL-based query language makes the difference. The SQL standard has evolved drastically in the past decades, and so have its commercial and open source implementations.
In this fast-paced talk, we’re going to look at very peculiar and interesting data problems and how we can solve them with SQL. We’ll explore common table expressions, hierarchical SQL, table-valued functions, lateral joins, row value expressions, window functions, and advanced data types, such as XML and JSON. And we’ll look at Oracle’s mysterious MODEL and MATCH_RECOGNIZE clauses, devices whose mystery is only exceeded by their power. Most importantly, however, we’re going to learn that everyone can write advanced SQL. Once you learn the basics in these tricks, you’re going to love SQL even more.
Tomer Elmalem - GraphQL APIs: REST in Peace - Codemotion Milan 2017Codemotion
This talk will introduce attendees to GraphQL and then dive into the intricacies of how we built the API. It’ll cover end-to-end the flow we provide to our developers and some of the specific considerations we took when making it a public API: * solving the N+1 data retrieval problem and query planning * structuring models for optimal data retrieval * when to use GraphQL This talk will also cover some of the specifics of hooking GraphQL into a service-oriented architecture, how it’s built into our infrastructure, and the advantages you gain by having GraphQL interface with your services.
Lightbend Lagom: Microservices Just Right (Scala Days 2016 Berlin)mircodotta
Microservices architecture are becoming a de-facto industry standard, but are you satisfied with the current state of the art? We are not, as we believe that building microservices today is more challenging than it should be. Lagom is here to take on this challenge. First, Lagom is opinionated and it will take some of the hard decisions for you, guiding you to produce microservices that adheres to the Reactive tenents. Second, Lagom was built from the ground up around you, the developer, to push your productivity to the next level. If you are familiar with the Play Framework's development environment, imagine that but tuned for building microservices; we are sure you are going to love it! Third, Lagom comes with batteries included for deploying in production: going from development to production could not be easier. In this session, you will get an introduction to the Lightbend Lagom framework. There will be code and live demos to show you in practice how it works and what you can do with it, making you fully equipped to build your next microservices with Lightbend Lagom!
Presented at Devoxx US (http://cfp.devoxx.us/2017/talk/PEV-2089)
Collections are a staple in any programming language: the need to collect, sort or iterate over values is needed by nearly all developers.
The Java language introduced the Collections framework long ago and that's what many (incredibly not all!) developers learn when they start programming. It has plenty to offer, but many find it lacking: the amount of collection libraries as active open source projects demonstrate the need for something else.
If we were to search to find a holistic comparison of famous collection libraries, there is not much literature available. The talk is poised to fill this gap. In this session, we will explore the most common collections (pun intended!) frameworks, what they have to offer and what you should consider for your next project.
We will also show common programmer use cases, how each library handles them and the impact on memory, processing power and ease of use/coding.
After this session, you will be able to choose the right bag for you tricks!
Scal`a`ngular a term composed of Scala and Angular JS, a relationship, a handshake between Scala and Angular JS.
It's a way to build AngularJS based applications in a type-safe manner with Scala, Way to provide the bindings to core AngularJS classes and functions.
Lightbend Lagom: Microservices Just Rightmircodotta
Microservices architecture are becoming a de-facto industry standard, but are you satisfied with the current state of the art? We are not, as we believe that building microservices today is more challenging than it should be. Lagom is here to take on this challenge. First, Lagom is opinionated and it will take some of the hard decisions for you, guiding you to produce microservices that adheres to the Reactive tenents. Second, Lagom was built from the ground up around you, the developer, to push your productivity to the next level. If you are familiar with the Play Framework's development environment, imagine that but tuned for building microservices; we are sure you are going to love it! Third, Lagom comes with batteries included for deploying in production: going from development to production could not be easier. In this session, you will get an introduction to the Lightbend Lagom framework. There will be code and live demos to show you in practice how it works and what you can do with it, making you fully equipped to build your next microservices with Lightbend Lagom!
Collections are a staple in any programming language: the need to collect, sort, or iterate over values is needed by nearly all developers. The Java language introduced the Collections framework long ago. It has plenty to offer, but many find it lacking: the number of collection libraries as active open source projects demonstrates the need for something else. This session does a holistic comparison of the most-common collections (pun intended!) frameworks, what they have to offer, and what you should consider for your next project. It also shows common programmer use cases; how each library handles them; and the impact on memory, processing power, and ease of use/coding. Come and let us help you choose the right bag for your tricks!
From the Scalapeño 2013 conference: http://scalapeno.underscore.co.il/
It’s no secret that in Israel, C# is one of the leading languages for development. This stems from various reasons, ranging from the power of the language to the ubiquity of Microsoft’s technologies in government and defense organizations. When it first came out, C# was Microsoft’s answer to Java and the two were on-par. Since then, C# has grown leaps and bounds and Java, while still sitting on top of the powerful JVM with a huge, open ecosystem created over nearly two decades, was left behind. Developers looking to stop paying the Microsoft-tax were faced with a language that simply did not meet their expectations.
Scala is the one of the answers to this growing need for a new, modern language for the JVM.
This lecture introduces the language, comparing its idioms to those of C#, and introduces you some of the tools and frameworks to get you started with it.
Production debugging is hard, and it’s getting harder. With architectures becoming more distributed and code more asynchronous and reactive, pinpointing and resolving errors that happen in production is no child’s game. This session covers some essential tools and more advanced techniques Scala developers can use to debug live applications and resolve errors quickly. It explores crucial techniques for distributed debugging - and some of the pitfalls that make resolution much harder, and can lead to downtime. The talk also touches on some little-known JVM tools and capabilities that give you super-deep visibility at high scale without making you restart it or attach debuggers.
10 SQL Tricks that You Didn't Think Were PossibleLukas Eder
SQL is the winning language of Big Data. Whether you’re running a classic relational database, a column store (“NewSQL”), or a non-relational storage system (“NoSQL”), a powerful, declarative, SQL-based query language makes the difference. The SQL standard has evolved drastically in the past decades, and so have its commercial and open source implementations.
In this fast-paced talk, we’re going to look at very peculiar and interesting data problems and how we can solve them with SQL. We’ll explore common table expressions, hierarchical SQL, table-valued functions, lateral joins, row value expressions, window functions, and advanced data types, such as XML and JSON. And we’ll look at Oracle’s mysterious MODEL and MATCH_RECOGNIZE clauses, devices whose mystery is only exceeded by their power. Most importantly, however, we’re going to learn that everyone can write advanced SQL. Once you learn the basics in these tricks, you’re going to love SQL even more.
Tomer Elmalem - GraphQL APIs: REST in Peace - Codemotion Milan 2017Codemotion
This talk will introduce attendees to GraphQL and then dive into the intricacies of how we built the API. It’ll cover end-to-end the flow we provide to our developers and some of the specific considerations we took when making it a public API: * solving the N+1 data retrieval problem and query planning * structuring models for optimal data retrieval * when to use GraphQL This talk will also cover some of the specifics of hooking GraphQL into a service-oriented architecture, how it’s built into our infrastructure, and the advantages you gain by having GraphQL interface with your services.
Lightbend Lagom: Microservices Just Right (Scala Days 2016 Berlin)mircodotta
Microservices architecture are becoming a de-facto industry standard, but are you satisfied with the current state of the art? We are not, as we believe that building microservices today is more challenging than it should be. Lagom is here to take on this challenge. First, Lagom is opinionated and it will take some of the hard decisions for you, guiding you to produce microservices that adheres to the Reactive tenents. Second, Lagom was built from the ground up around you, the developer, to push your productivity to the next level. If you are familiar with the Play Framework's development environment, imagine that but tuned for building microservices; we are sure you are going to love it! Third, Lagom comes with batteries included for deploying in production: going from development to production could not be easier. In this session, you will get an introduction to the Lightbend Lagom framework. There will be code and live demos to show you in practice how it works and what you can do with it, making you fully equipped to build your next microservices with Lightbend Lagom!
Presented at Devoxx US (http://cfp.devoxx.us/2017/talk/PEV-2089)
Collections are a staple in any programming language: the need to collect, sort or iterate over values is needed by nearly all developers.
The Java language introduced the Collections framework long ago and that's what many (incredibly not all!) developers learn when they start programming. It has plenty to offer, but many find it lacking: the amount of collection libraries as active open source projects demonstrate the need for something else.
If we were to search to find a holistic comparison of famous collection libraries, there is not much literature available. The talk is poised to fill this gap. In this session, we will explore the most common collections (pun intended!) frameworks, what they have to offer and what you should consider for your next project.
We will also show common programmer use cases, how each library handles them and the impact on memory, processing power and ease of use/coding.
After this session, you will be able to choose the right bag for you tricks!
Scal`a`ngular a term composed of Scala and Angular JS, a relationship, a handshake between Scala and Angular JS.
It's a way to build AngularJS based applications in a type-safe manner with Scala, Way to provide the bindings to core AngularJS classes and functions.
Lightbend Lagom: Microservices Just Rightmircodotta
Microservices architecture are becoming a de-facto industry standard, but are you satisfied with the current state of the art? We are not, as we believe that building microservices today is more challenging than it should be. Lagom is here to take on this challenge. First, Lagom is opinionated and it will take some of the hard decisions for you, guiding you to produce microservices that adheres to the Reactive tenents. Second, Lagom was built from the ground up around you, the developer, to push your productivity to the next level. If you are familiar with the Play Framework's development environment, imagine that but tuned for building microservices; we are sure you are going to love it! Third, Lagom comes with batteries included for deploying in production: going from development to production could not be easier. In this session, you will get an introduction to the Lightbend Lagom framework. There will be code and live demos to show you in practice how it works and what you can do with it, making you fully equipped to build your next microservices with Lightbend Lagom!
Alberto Maria Angelo Paro - Isomorphic programming in Scala and WebDevelopmen...Codemotion
Scala is the only language that can be used to produce code that can be "trans/compiled" for the JVM, in Javascript and in native binary. This allows to write libraries that are usable in JVM and JS using the power of functional programming (i.e. cats, scalaz), generic programming (i.e. shapeless) and macro/scalameta available in Scala. In this talk, we will see how to write a Scala application backend and a SPA (scala.js/scala-js-react) that share the same code as a business logic, datamodels and transparent API call (JVM/JS) in Scala (via autowire/akka-http/circe).
Scaling Up Machine Learning Experimentation at Tubi 5x and BeyondScyllaDB
Scylla enables rapid Machine Learning experimentation at Tubi. The current-generation personalization service, Ranking Service, ramps up experimentation by 5x, while Popper, the next-generation experimentation engine, will grow by 10x and beyond. We'll talk about what's so special about these services.
Spring Day | Spring and Scala | Eberhard WolffJAX London
2011-10-31 | 09:45 AM - 10:30 AM
Spring is widely used in the Java world - but does it make any sense to combine it with Scala? This talk gives an answer and shows how and why Spring is useful in the Scala world. All areas of Spring such as Dependency Injection, Aspect-Oriented Programming and the Portable Service Abstraction as well as Spring MVC are covered.
Schema on read is obsolete. Welcome metaprogramming..pdfLars Albertsson
How fast can you modify your data collection to include a new field, make all the necessary changes in data processing and storage, and then use that field in analytics or product features? For many companies, the answer is a few quarters, whereas others do it in a day. This data agility latency has a direct impact on companies' ability to innovate with data. Schema-on-read has been a key strategy to lower that latency - as the community has shifted towards storing data outside relational databases, we no longer need to make series of schema changes through the whole data chain, coordinated between teams to minimise operational risk. Schema-on-read comes with a cost, however. Errors that we used to catch during testing or in early test deployments can now sneak into production undetected and surface as product errors or hard-to-debug data quality problems later than with schema-on-write solutions.
In this presentation, we will show how we have rejected the tradeoff between slow schema change rate and quality to achieve the best of both worlds. By using metaprogramming and versioned pipelines that are tested end-to-end, we can achieve fast schema changes with schema-on-write and the protection of static typing. We will describe the tools in our toolbox - Scalameta, Chimney, Bazel, and custom tools. We will also show how we leverage them to take static typing one step further and differentiate between domain types that share representation, e.g. EmailAddress vs ValidatedEmailAddress or kW vs kWh, while maintaining harmony with data technology ecosystems.
The Dining Man: how does Afisha Restaurants change the behavioral patterns of choice and payments in cafes and restaurants. Based on the real experience of Project Manager
Accelerate your Kubernetes clusters with Varnish CachingThijs Feryn
A presentation about the usage and availability of Varnish on Kubernetes. This talk explores the capabilities of Varnish caching and shows how to use the Varnish Helm chart to deploy it to Kubernetes.
This presentation was delivered at K8SUG Singapore. See https://feryn.eu/presentations/accelerate-your-kubernetes-clusters-with-varnish-caching-k8sug-singapore-28-2024 for more details.
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
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.
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...James Anderson
Effective Application Security in Software Delivery lifecycle using Deployment Firewall and DBOM
The modern software delivery process (or the CI/CD process) includes many tools, distributed teams, open-source code, and cloud platforms. Constant focus on speed to release software to market, along with the traditional slow and manual security checks has caused gaps in continuous security as an important piece in the software supply chain. Today organizations feel more susceptible to external and internal cyber threats due to the vast attack surface in their applications supply chain and the lack of end-to-end governance and risk management.
The software team must secure its software delivery process to avoid vulnerability and security breaches. This needs to be achieved with existing tool chains and without extensive rework of the delivery processes. This talk will present strategies and techniques for providing visibility into the true risk of the existing vulnerabilities, preventing the introduction of security issues in the software, resolving vulnerabilities in production environments quickly, and capturing the deployment bill of materials (DBOM).
Speakers:
Bob Boule
Robert Boule is a technology enthusiast with PASSION for technology and making things work along with a knack for helping others understand how things work. He comes with around 20 years of solution engineering experience in application security, software continuous delivery, and SaaS platforms. He is known for his dynamic presentations in CI/CD and application security integrated in software delivery lifecycle.
Gopinath Rebala
Gopinath Rebala is the CTO of OpsMx, where he has overall responsibility for the machine learning and data processing architectures for Secure Software Delivery. Gopi also has a strong connection with our customers, leading design and architecture for strategic implementations. Gopi is a frequent speaker and well-known leader in continuous delivery and integrating security into software delivery.
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
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
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.
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/
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.
8. ● open source - open-genesis.org
● 2 years of development
● > 50 KLOC of scala code
● successfully deployed to production in one
large american financial institution
● Buzzwords: continuous deployment, cloud,
chef, devops, aws, openstack
OpenGenesis
Deployment orchestration tool
9. ● Integration with legacy apps and data (lots of
SOAP and xml)
● sophisticated security policies
● IT department separated from development
team
● J2EE Containers everywhere
● Risk averse
Enterprise characteristics
11. j2ee stack. Scala edition
Web layer
Service layer
Data access layer
DB
Spring MVC + scala magic
Spring + scala implicits
JPA Squeryl
12. j2ee stack. Scala edition
Web layer
Service layer
Data access layer
DB
Spring MVC
Spring
Squeryl
WAR
13. j2ee stack. Scala edition + scala
goodness
Web layer
Service layer
Data access layer
DB
Spring MVC
Spring
Squeryl
Workflow distributed
engine
Akka
WAR
15. ● DI fits almost nicely with scala
Spring with scala
16. ● DI fits almost nicely with scala
class GenesisRestController {
@Autowired var genesisService: GenesisService = _
}
class GenesisRestController {
@BeanProperty var genesisService: GenesisService = _
}
class GenesisRestController (genesisService: GenesisService) {}
Spring with scala
17. ● DI fits almost nicely with scala
○ "Everything is a trait" approach can't be done
Spring with scala
18. ● DI fits almost nicely with scala
○ "Everything is a trait" approach can't be done
○ Be aware of type inference in @Configuration bean
trait Service
class ServiceImpl extends Service
@Configuration
class ServiceContext {
@Bean def service = new ServiceImpl
}
Spring with scala
19. ● DI fits almost nicely with scala
○ "Everything is a trait" approach can't be done
○ Be aware of type inference in @Configuration bean
trait Service
class ServiceImpl extends Service
@Configuration
class ServiceContext {
@Bean def service: Service = new ServiceImpl
}
Spring with scala
20. ● DI fits almost nicely with scala
● Rich spring templates libraries.
Spring with scala
21. ● DI fits almost nicely with scala
● Rich spring templates libraries.
springLdapTemplate.authenticate("user", "*", "password", new
AuthenticationErrorCallback {
def execute(e: Exception) {log.error(e)}
})
Spring with scala
22. ● DI fits almost nicely with scala
● Rich spring templates libraries.
springLdapTemplate.authenticate("user", "*", "password", new
AuthenticationErrorCallback {
def execute(e: Exception) {log.error(e)}
})
Spring with scala
23. ● DI fits almost nicely with scala
● Rich spring templates libraries.
springLdapTemplate.authenticate("user", "*", "password", new
AuthenticationErrorCallback {
def execute(e: Exception) {log.error(e)}
})
springLdapTemplate.authenticate("user", "*", "password", log.error(_))
Spring with scala
24. ● DI fits almost nicely with scala
● Rich spring templates libraries.
springLdapTemplate.authenticate("user", "*", "password", log.error(_))
implicit def authErrorCallbackWrapper(func:(Exception) => Any) = {
new AuthenticationErrorCallback {
def execute(exception: Exception): Unit = func(exception)
}
}
Spring with scala
25. ● DI fits almost nicely with scala
● Rich spring templates libraries.
● AOP for free (almost)
Spring with scala
26. ● DI fits almost nicely with scala
● Rich spring templates libraries.
● AOP for free (almost)
○ Be aware of naming in debug info
def findUsers(projectId: Int) {
dao.findUsers(projectId)
}
def findUsers2(projectId: Int) {
dao.allUsers().filter(_.projectId == projectId)
}
Spring with scala
27. ● DI fits almost nicely with scala
● Rich spring templates libraries.
● AOP for free (almost)
○ Be aware of naming in debug info
def findUsers(projectId: Int) { // debugIfo: name "projectId"
dao.findUsers(projectId)
}
def findUsers2(projectId: Int) { // debugInfo: name "projectId$"
dao.allUsers().filter(_.projectId == projectId)
}
Spring with scala
28. ● DI fits almost nicely with scala
● Rich spring templates libraries.
● AOP for free (almost)
● Spring security just works
Spring with scala
31. ● Lightweight ORM written in scala
Squeryl
class Workflow(override val id: Int) extends KeyedEntity[Int]
32. ● Lightweight ORM written in scala
Squeryl
class Workflow(override val id: Int) extends KeyedEntity[Int]
object GS extends Schema {
val workflows = table[Workflow]
}
33. ● Lightweight ORM written in scala
Squeryl
class Workflow(override val id: Int) extends KeyedEntity[Int]
object GS extends Schema {
val workflows = table[Workflow]
}
def find(workflowId: Int) = from(GS.workflows)(w =>
where(w.id === workflowId)
select (w)
orderBy(w.id desc)
)
34. ● Lightweight ORM written in scala
○ First class support for scala collections, options, etc
Squeryl
35. ● Lightweight ORM written in scala
○ First class support for scala collections, options, etc
○ Integrates with spring transaction management
(not out of the box)
Squeryl
36. ● Lightweight ORM written in scala
○ First class support for scala collections, options, etc
○ Integrates with spring transaction management
(not out of the box)
Squeryl
@Transactional(propagation = REQUIRES_NEW)
def find(workflowId: Int) = from(GS.workflows)(w =>
where(w.id === workflowId)
select (w)
orderBy(w.id desc)
)
37. Squeryl
● Lightweight ORM written in scala
○ Likes heap in the same proportion as
Hibernate does
hibernate squeryl
38. ● Lightweight ORM written in scala
○ Likes heap in the same proportion as
Hibernate does
○ Lot's of "black magic" in source code
Squeryl
39. ● Lightweight ORM written in scala
● Internal scala DSL for writing queries
○ Type safe queries - compile time syntax check
Squeryl
40. ● Lightweight ORM written in scala
● Internal scala DSL for writing queries
○ Lot's of "black magic" in source code
Squeryl
41. ● Lightweight ORM written in scala
● Internal scala DSL for writing queries
○ Lot's of "black magic" in source code
○ Fallback on native sql is not easy
Squeryl
42. ● Lightweight ORM written in scala
● Internal scala DSL for writing queries
○ Lot's of "black magic" in source code
○ Fallback on native sql is not easy
○ Lots of implicits drives IDE crazy and
increases compilation time
Squeryl
43. ● Lightweight ORM written in scala
● Internal scala DSL for writing queries
○ Lot's of "black magic" in source code
○ Fallback on native sql is not easy
○ Lots of implicits drives IDE crazy and
increase compilation time
○ The approach is somewhat flawed (opinion)
Squeryl
52. ● Hiring is hard
○ Scala is a talent attraction
Challenges
53. ● Hiring is hard
○ Scala is a talent attraction
○ In avg: 0.5 interview per month
Challenges
54. ● Hiring is hard
● Settling team standards and code
convention
Challenges
55. ● Hiring is hard
● Settling team standards and code
convention
○ Tools are not there yet
Challenges
56. ● Hiring is hard
● Settling team standards and code
convention
○ Tools are not there yet
○ Between "OCaml" and "Java" fires
Challenges
57. ● Hiring is hard
● Settling team standards and code
convention
○ Tools are not there yet
○ Between "OCaml" and "Java" fires
○ "Effective scala" by Twitter and "Scala style guide"
might help (a bit)
Challenges
58. The greatest code-review mystery of
all times
if (option.isDefined) {
..
}
option.foreach { .. }
option match {
case Some(x) => ..
case None => ..
}
How to deal with scala.Option
?
59. The greatest code-review mystery of
all times
if (option.isDefined) {
..
}
option.foreach { .. }
option match {
case Some(x) => ..
case None => ..
}
How to deal with scala.Option
?