This document discusses a function-passing programming model for distributed systems. The key concepts are:
1. Immutable, stationary data stored in "silos".
2. Portable "spore" functions that are serialized and sent to remote silos to perform work on the data.
Silos contain the data and run functions on it. Silo references allow applying functions asynchronously across machines by serializing the functions and data references. The model aims to simplify distributed programming by keeping data stationary and moving functions to the data.
Design patterns are optimized, reusable solutions to the programming problems that we encounter every day. A design pattern is not a class or a library that we can simply plug into our system; it's much more than that. It is a template that has to be implemented in the correct situation. It's not language-specific either. A good design pattern should be implementable in most—if not all—languages, depending on the capabilities of the language. Most importantly, any design pattern can be a double-edged sword— if implemented in the wrong place, it can be disastrous and create many problems for you. However, implemented in the right place, at the right time, it can be your savior.
Attack countermeasure tree (act) meets withIJCNCJournal
In this paper, we present a novel attack tree paradigm called attack countermeasure tree (ACT) comprising an additional attack resistant element known as the Split-protocol. ACT which circumvent the fabrication
and way out of a state-space representation and takes keen on account attack, as well as countermesures (in the form of detection and mitigation events). Split-protocol as an attack resistant element enhances the availability of the system during or after a security attack on the system. We compare ACT with or without Split-protocol implantation. The split-protocol concept stemmed from splitting the HTTP/TCP protocol in
webserver application. An HTTP/TCP protocol is standard on a webserver can be split into two segments, and each part can be separately run on a different Web server, thus constituting dual servers. These servers communicate across a network by using inter-server messages or delegate messages.In ACT, recognition and alleviation are allowed not just at the leaf node but also at the intermediate nodes,andsimultaneouslythe state-space explosion problem is avoided in its analysis. We study the consequences of incorporating countermeasures in the ACT and Split-protocol using various case studies.
Design patterns are optimized, reusable solutions to the programming problems that we encounter every day. A design pattern is not a class or a library that we can simply plug into our system; it's much more than that. It is a template that has to be implemented in the correct situation. It's not language-specific either. A good design pattern should be implementable in most—if not all—languages, depending on the capabilities of the language. Most importantly, any design pattern can be a double-edged sword— if implemented in the wrong place, it can be disastrous and create many problems for you. However, implemented in the right place, at the right time, it can be your savior.
Attack countermeasure tree (act) meets withIJCNCJournal
In this paper, we present a novel attack tree paradigm called attack countermeasure tree (ACT) comprising an additional attack resistant element known as the Split-protocol. ACT which circumvent the fabrication
and way out of a state-space representation and takes keen on account attack, as well as countermesures (in the form of detection and mitigation events). Split-protocol as an attack resistant element enhances the availability of the system during or after a security attack on the system. We compare ACT with or without Split-protocol implantation. The split-protocol concept stemmed from splitting the HTTP/TCP protocol in
webserver application. An HTTP/TCP protocol is standard on a webserver can be split into two segments, and each part can be separately run on a different Web server, thus constituting dual servers. These servers communicate across a network by using inter-server messages or delegate messages.In ACT, recognition and alleviation are allowed not just at the leaf node but also at the intermediate nodes,andsimultaneouslythe state-space explosion problem is avoided in its analysis. We study the consequences of incorporating countermeasures in the ACT and Split-protocol using various case studies.
An introduction to creational design patterns in object orientation. Suitable for intermediate to advanced computing students and those studying software engineering.
If you want to program just about anything these days,
you’d better learn object-oriented programming.
Anyone should write a framework and never use it !
Who cares, right? We have the framework! We don't need to know how to "do it by hand"! Right?
iOS development Crash course in how to build an native application for iPhone.
i will be start from beginning till publishing on Apple Store step by step.
this session # 1 after the intro
This slide deck introduces Deep Learning concepts, such gradient descent, back propagation, activation functions, and CNNs. Basic knowledge of vectors, matrices, and Android, as well as elementary calculus (derivatives), are strongly recommended in order to derive the maximum benefit from this session.
An introduction to creational design patterns in object orientation. Suitable for intermediate to advanced computing students and those studying software engineering.
If you want to program just about anything these days,
you’d better learn object-oriented programming.
Anyone should write a framework and never use it !
Who cares, right? We have the framework! We don't need to know how to "do it by hand"! Right?
iOS development Crash course in how to build an native application for iPhone.
i will be start from beginning till publishing on Apple Store step by step.
this session # 1 after the intro
This slide deck introduces Deep Learning concepts, such gradient descent, back propagation, activation functions, and CNNs. Basic knowledge of vectors, matrices, and Android, as well as elementary calculus (derivatives), are strongly recommended in order to derive the maximum benefit from this session.
4 года разрабатывает видеостриминговый сервер эрливидео и в этом докладе расскажет о некоторых отличительных возможностях Erlang, которые позволяют быстро развиваться и поддерживать высочайшее качество ПО минимальными усилиями.
In this talk, I discussed the different forms of complexities that can arise when integrating with APIs, and how DSLs can be used to tackle these complexities. I demonstrated that F# can be a very effective tool for creating both internal and external DSLs using both FParsec and active patterns.
Мобильные приложения в экосистеме открытых данных (RIW 2013)Vitaly Vlasov
В контексте последних тенденций в IT-индустрии, в частности бурно развивающийся тренд создания сервисов SoLoMo (Social, Local, Mobile), тематика открытых данных особенно актуальна. В России открытые данные имеют ширкую государственную поддержку: создаются региональные порталы данных, местные администрации прикладывают усилия к ид популяризации (например, через проведение хакатонов). Открытые данные как технология дают новые возможности для разработчиков, создавая не только новые общественно-полезные сервисы и новый рынок приожений, но и автоматизируя многие
Есть ли жизнь после релиза мобильного приложения?Alexander Khozya
1. Отличия заказной и продуктовой разработки
2. Какие инструменты для сбора краш логов и аналитики есть на рынке?
3. Какие используем мы
4. Воспроизводим найденные краши
5. Использование обезьянок вместе со средствами аналитики
6. Перевыкладка
7. Внутреннее бета-тестирование
8. A/B тестирование
Города включены в глобальную конкуренцию за капитал — человеческий, финансовый, производственный, символический, социальный — стараясь следовать передовым концепциям и принципам городского планирования. При этом, ставка делается на несколько параметров — как правило, это уровень дохода, возможности самореализации, привлекательная физическая и социальная среда, высокотехнологичные сервисы, экология и некоторые другие, — которые не охватывают в полной мере всего спектра ожиданий талантливого специалиста или предпринимателя от своего нового места жительства.
Самые передовые города стремятся к тому, чтобы быть городом, построенным в соответствии с лучшими мировыми практиками, обеспечивающим принципиально новое качество жизни. Такие города чутки к потребностям, пожеланиям и особенностям своих клиентов — жителей, гостей, инвесторов, бизнеса. Именно люди являются ведущими драйверами развития городов — только опираясь на «голос клиента», постоянно коммуницируя с ними, выявляя потребности, создавая нужные и востребованные сервисы — город может стать выиграть в глобальной конкуренции.
Ритейл на ладони (мобильные приложения в жизни ритейла) - Журнал "Мое дело. ...Artem Andreev
Мобильные технологии настолько проникли в жизнь каждого человека, что, конечно, нашли применение и в ритейле. Со времен прихода на рынок персональных компьютеров никакие другие технологии не были настолько широким полем для предложений разработчиков и не обещали столь многого. Сканеры штрихкодов, планшеты, смартфоны со специальными приложениями…
Intro to JAVA
Basics of Oops
Features of Oops
Applications of Oops
How to create a JAVA program
How to Edit a Java Program
Compiling a Java program
Java Class file
Run or Executing a Java program
Command line arguments
Zenoh is rapidly growing Eclipse project that unifies data in motion, data at rest and computations. It elegantly blends traditional pub/sub with geo distributed storage, queries and computations, while retaining a level of time and space efficiency that is well beyond any of the mainstream stacks. This presentation will provide an introduction to Eclipse Zenoh along with a crisp explanation of the challenges that motivated the creation of this project. We will go through a series of real-world use cases that demonstrate the advantages brought by Zenoh in enabling and optimising typical edge scenarios and in simplifying the development of any scale distributed applications.
Lotusphere 2007 AD507 Leveraging the Power of Object Oriented Programming in ...Bill Buchan
Co-presented with Jens Augustini
Object Oriented Programming (OOP) may drastically reduce your coding time in projects that reach a higher degree of complexity, as it brings re-usable and consistent logic in the form of your own objects to your fingertips. This session will show how to create and use your own classes and how they can relate to the LotusScript Object Model. If you are familiar with LotusScript but don't know how to create your own classes, this session is for you!
What are the actors? What are they used for? And how can we develop them? And how are they published and used on Azure? Let's see how it's done in this session
Slides for the session presented at the "Un Actor (Model) per amico - multithreading made easy" DevMarche User group event.
In the talk I introduced many of the techniques and practices the teams I work with use when it comes to design and develop highly concurrent and possibly distributed applications.
I also tried to show how many of the concepts coming from several "sources", like Agile practices, DDD, SOA, Microservices, Actor Model, etc overlap and integrate to reach the goal of modelling a working solution for our customers.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Generating a custom Ruby SDK for your web service or Rails API using Smithyg2nightmarescribd
Have you ever wanted a Ruby client API to communicate with your web service? Smithy is a protocol-agnostic language for defining services and SDKs. Smithy Ruby is an implementation of Smithy that generates a Ruby SDK using a Smithy model. In this talk, we will explore Smithy and Smithy Ruby to learn how to generate custom feature-rich SDKs that can communicate with any web service, such as a Rails JSON API.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
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.
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
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.
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!
Elevating Tactical DDD Patterns Through Object Calisthenics
Heather Miller
1. Function-Passing Style
Typed, Distributed Functional
Programming
Heather Miller
@heathercmiller
Philipp Haller
@philippkhaller
EPFL Typesafe
2. …been working on
Language support for distributed
system builders.
Serialization
That happens mostly at compile
time, so it’s performant.
Type classes to allow users to
serialize to different formats
(binary, JSON, etc)
1.
3. …been working on
Language support for distributed
system builders.
Spores
Portable (serializable) closures.
Type constraints to restrict what
they capture
2.
4. In this talk…
A programming model.
Builds on the basis of serializable
functions
to provide a substrate that
distributed systems can be built
upon
5. In this talk…
A programming model.
The result…
the model greatly simplifies the design
and implementation of mechanisms for:
Fault-tolerance
In-memory caching
Debugging(i.e., pushing types into
more layers of the stack)
IN A CLEAN & FUNCTIONAL WAY.
(STATELESS!)
6. Note:
Currently a research project.
Thus, all aspects of it are under
development + publication in
the works.
(Thanks, )
11. Actors…
Encapsulate state and behavior.
Are stationary.
Actors exchange data/commands
through asynchronous messaging.
12. Function-passing…
Stateless. Built on persistent
data structures.
Keep the data stationary.
Functions are exchanged through
asynchronous messaging.
13. Function-passing…
Stateless. Built on persistent
data structures.
Keep the data stationary.
Functions are exchanged through
asynchronous messaging.
Of note:
This is a model for programming with data and not a new
model of concurrent processes like actors.
!
Instead, we provide a new means of working with
distributed data in a functional way.
14. A Note on Distributed Computing
Jim Waldo, Geoff Wyant, Ann Wollrath, and Sam Kendall
Sun Microsystems Laboratories
2550 Garcia Avenue
Mountain View, CA 94043
1 Introduction
Much of the current work in distributed, object-oriented
systems is based on the assumption that objects form a sin-gle
ontological class. This class consists of all entities that
can be fully described by the specification of the set of
interfaces supported by the object and the semantics of the
operations in those interfaces. The class includes objects
that share a single address space, objects that are in sepa-rate
address spaces on the same machine, and objects that
are in separate address spaces on different machines (with,
perhaps, different architectures). On the view that all
1.1 Terminology
In what follows, we will talk about local and distributed
computing. By local computing (local object invocation,
etc.), we mean programs that are confined to a single
address space. In contrast, we will use the term distributed
computing (remote object invocation, etc.) to refer to pro-grams
that make calls to other address spaces, possibly on
another machine. In the case of distributed computing,
nothing is known about the recipient of the call (other than
that it supports a particular interface). For example, the
client of such a distributed object does not know the hard-ware
architecture on which the recipient of the call is run-ning,
15. A Note on Distributed Computing
Differences in latency, memory access, partial failure, and
Jim Waldo, Geoff Wyant, Ann Wollrath, and Sam Kendall
concurrency make merging of the computational models of local
and distributed computing Sun Microsystems both unwise Laboratories
to attempt and unable to
succeed.
2550 Garcia Avenue
Mountain View, CA 94043
1 Introduction
Much of the current work in distributed, object-oriented
systems is based on the assumption that objects form a sin-gle
ontological class. This class consists of all entities that
can be fully described by the specification of the set of
interfaces supported by the object and the semantics of the
operations in those interfaces. The class includes objects
that share a single address space, objects that are in sepa-rate
address spaces on the same machine, and objects that
are in separate address spaces on different machines (with,
perhaps, different architectures). On the view that all
1.1 Terminology
In what follows, we will talk about local and distributed
computing. By local computing (local object invocation,
etc.), we mean programs that are confined to a single
address space. In contrast, we will use the term distributed
computing (remote object invocation, etc.) to refer to pro-grams
that make calls to other address spaces, possibly on
another machine. In the case of distributed computing,
nothing is known about the recipient of the call (other than
that it supports a particular interface). For example, the
client of such a distributed object does not know the hard-ware
architecture on which the recipient of the call is run-ning,
“
”
16. A Note on Distributed Computing
Differences in latency, memory access, partial failure, and
Jim Waldo, Geoff Wyant, Ann Wollrath, and Sam Kendall
concurrency make merging of the computational models of local
and distributed computing Sun Microsystems both unwise Laboratories
to attempt and unable to
succeed.
2550 Garcia Avenue
Mountain View, CA 94043
A better approach is to accept that there are irreconcilable
differences between local and distributed computing, and to be
conscious of those differences at all stages of the design and
implementation of distributed applications. Rather than trying to
merge local and remote objects, engineers need to be constantly
reminded of the differences between the two, and know when it
is appropriate to use each kind of object.
1 Introduction
Much of the current work in distributed, object-oriented
systems is based on the assumption that objects form a sin-gle
ontological class. This class consists of all entities that
can be fully described by the specification of the set of
interfaces supported by the object and the semantics of the
operations in those interfaces. The class includes objects
that share a single address space, objects that are in sepa-rate
address spaces on the same machine, and objects that
are in separate address spaces on different machines (with,
perhaps, different architectures). On the view that all
1.1 Terminology
In what follows, we will talk about local and distributed
computing. By local computing (local object invocation,
etc.), we mean programs that are confined to a single
address space. In contrast, we will use the term distributed
computing (remote object invocation, etc.) to refer to pro-grams
that make calls to other address spaces, possibly on
another machine. In the case of distributed computing,
nothing is known about the recipient of the call (other than
that it supports a particular interface). For example, the
client of such a distributed object does not know the hard-ware
architecture on which the recipient of the call is run-ning,
“
”
“
”
21. Function-Passing
Model
the
Two concepts:
(illustrated)
1. Stationary, immutable data.
Portable functions –
move the functionality to the data. 2.
22. Function-Passing
Model
the
Two concepts:
(illustrated)
1. Stationary, immutable data.
Silos
Portable functions –
move the functionality to the data. 2.
23. Function-Passing
Model
the
Two concepts:
(illustrated)
1. Stationary, immutable data.
Silos
(for a lack of a
better name)
Portable functions –
move the functionality to the data. 2.
24. Function-Passing
Model
the
Two concepts:
(illustrated)
1. Stationary, immutable data.
Silos
(for a lack of a
better name)
Portable functions –
move the functionality to the data. 2.
Spores
25. Function-Passing
Two concepts:
(illustrated) Model
the
1. Stationary, immutable data. Silos
(for a lack of a
better name)
Portable functions –
move the functionality to the data. 2.
Spores
27. Function-Passing
Model
the
(illustrated)
Silo[T]
T
Silos.
WHAT ARE THEY?
SiloRef[T]
def
apply
def
send
The handle to a Silo.
(The workhorse.)
28. Function-Passing
Model
the
(illustrated)
Silo[T]
T
Silos.
WHAT ARE THEY?
SiloRef[T]
def
apply
def
send
The handle to a Silo.
def
apply(s1:
Spore,
s2:
Spore):
SiloRef[T]
29. Function-Passing
Model
the
(illustrated)
Silo[T]
T
Silos.
WHAT ARE THEY?
SiloRef[T]
def
apply
def
send
The handle to a Silo.
def
apply(s1:
Spore,
s2:
Spore):
SiloRef[T]
Ta k e s t w o s p o r e s :
LAZY!
framework logic (combinator), e.g. map
user/application-provided argument function
Defers application of fn to silo, returns SiloRef
with info for later materialization of silo.
30. Function-Passing
Model
the
(illustrated)
Silo[T]
T
Silos.
WHAT ARE THEY?
SiloRef[T]
def
apply
def
send
The handle to a Silo.
def
apply(s1:
Spore,
s2:
Spore):
SiloRef[T]
def
send():
Future[T]
31. Function-Passing
Model
the
(illustrated)
Silo[T]
T
Silos.
WHAT ARE THEY?
SiloRef[T]
def
apply
def
send
The handle to a Silo.
def
apply(s1:
Spore,
s2:
Spore):
SiloRef[T]
Sends info for function application
and silo materialization to remote node
EAGER!
def
send():
Future[T]
Asynchronous/nonblocking data transfer to
local machine (via Future)
39. Function-Passing
Model
the
Two concepts:
(illustrated)
1. Stationary, immutable data.
Silos
(for a lack of a
better name)
Portable functions –
move the functionality to the data. 2.
Spores
40. What do spores look like?
Basic usage:
val
s
=
spore
{
val
h
=
helper
(x:
Int)
=>
{
val
result
=
x
+
"
"
+
h.toString
println("The
result
is:
"
+
result)
}
}
a sequence of local value (val) declarations
only (the “spore header”), and 1
THE BODY OF A SPORE CONSISTS OF 2 PARTS
2 a closure
http://docs.scala-lang.org/sips/pending/spores.html
41. A Spore
Guarantees...
(vsclosures)
1. All captured variables are declared in
the spore header, or using capture
2. The initializers of captured variables
are executed once, upon creation of
the spore
3. References to captured variables do
not change during the spore’s execution
http://docs.scala-lang.org/sips/pending/spores.html
42. Spores&
Closures
Evaluation semantics:
Remove the spore marker, and the code
behaves as before
spores & closures are related:
You can write a full function literal and pass
it to something that expects a spore.
(Of course, only if the function literal
satisfies the spore rules.)
http://docs.scala-lang.org/sips/pending/spores.html
43. Function-Passing
Model
the
(illustrated)
Spores.
Benefits:
environment (captured variables) is
declared explicitly, and fixed at spore creation time.
can statically ensure that everything captured is
serializable
44. Function-Passing
Model
the
(illustrated)
14
Spores.
Benefits:
6SRUHV $ 7SH%DVHG )RXQGDWLRQ IRU ORVXUHV LQ WKH
$JH RI RQFXUUHQF DQG 'LVWULEXWLRQ
+HDWKHU 0LOOHU 3KLOLSS +DOOHU1 DQG 0DUWLQ 2GHUVN
(3)/ DQG 7SHVDIH ,QF1
environment (captured ’Š‹Ž‹’’ŜŠƒŽŽ‡”ɒ–›’‡•ƒˆ‡Ŝ…‘variables) 1
DQG is
declared ƇŠ‡ƒ–Š‡”Ŝ‹ŽŽ‡”ř ƒ”–‹Ŝ‘†‡”•›ƈɒ‡’ˆŽŜ…Š explicitly, and fixed at spore creation time.
can statically ensure that everything captured is
serializable
$EVWUDFW )XQFWLRQDO SURJUDPPLQJ )3
45. LV UHJXODUO WRXWHG DV WKH ZD IRUZDUG
IRU EULQJLQJ SDUDOOHO FRQFXUUHQW DQG GLVWULEXWHG SURJUDPPLQJ WR WKH PDLQVWUHDP
7KH SRSXODULW RI WKH UDWLRQDOH EHKLQG WKLV YLHZSRLQW KDV HYHQ OHG WR D QXPEHU RI
REMHFWRULHQWHG 22
48. Function-Passing
Model
the
(illustrated)
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
SiloRef[List[Int]]
49. Function-Passing
Model
the
(illustrated)
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood) (Spores)
SiloRef[List[Int]]
50. Function-Passing
Model
the
(illustrated)
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
SiloRef[List[Int]]
.apply
51. Function-Passing
Model
the
(illustrated)
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
SiloRef[List[Int]] SiloRef[List[Int]]
.apply
52. Function-Passing
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
.apply
Model
the
(illustrated)
SiloRef[List[Int]] SiloRef[List[Int]]
.apply
53. Function-Passing
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
map f
.apply
Model
the
(illustrated)
SiloRef[List[Int]] SiloRef[List[Int]]
.apply
54. Function-Passing
Distributed List with operations map and reduce.
SiloRef[List[Int]] SiloRef[List[Int]] SiloRef[Int]
map f
.apply
Model
SiloRef[List[Int]]
map (_*2)
the
(illustrated)
reduce (_+_)
EXAMPLE:
(This is what would be happening under the hood)
.apply .apply
55. Function-Passing
Distributed List with operations map and reduce.
SiloRef[List[Int]] SiloRef[List[Int]] SiloRef[Int]
map f
.apply
Model
SiloRef[List[Int]]
map (_*2)
the
(illustrated)
reduce (_+_)
EXAMPLE:
(This is what would be happening under the hood)
.apply .apply .send()
56. Function-Passing
Model
the
(illustrated)
EXAMPLE:
Distributed List with operations map and reduce.
(This is what would be happening under the hood)
SiloRef[List[Int]] SiloRef[List[Int]] SiloRef[Int]
map f
.apply
SiloRef[List[Int]]
.apply .send()
map (_*2)
reduce (_+_)
65. Data in silos easily
reconstructed:
Silos and SiloRefs relate to each other by
means of a persistent data structure
The persistent data structure is based on
the chain of operations to derive the data
of each silo.
Thus, traversing the silo data structures
yields the complete lineage of a silo.
Since the lineage is composed of spores,
it’s serialized. This means it can be
persisted or transferred to other machine.
66. in
SUMMARY,
Data (Silos) managed using persistent data
structure.
All operations, including operations provided by
system builders, are spores – so, serializable!
Taken together:
A lot simpler to build mechanisms for fault tolerance!
67. Can’t I just…
Send spores within messages between
actors/processes?
Granted, that’s already quite powerful. :-)
However, spores + silos additionally provides
a lot of benefits that actors + spores alone do
not provide out-of-the-box:
Benefits:
deferred evaluation (laziness) enables
optimizations to reduce intermediate results.
statelessness + lineages simplifies the
implementation of mechanisms for fault tolerance
for certain applications
(think dist. collections)
68. Looking for feedback,
demanding use cases, contributors.
Get involved!
function-passing@googlegroups.com
Thank you!