Objects in the Cloud - Edition 2014


Published on

How do you write objects for cloud computing? Is Object Oriented Programming still THE way to write apps? What about the state that objects contains?

Published in: Technology
1 Like
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide
  • It’s something that object is able to do and that can change the state of the same object
  • Objects in the Cloud - Edition 2014

    1. 1. Objects in the Cloud Edizione 2014 Marco Parenzan
    2. 2. Objective Thinking about #state, #objects and how #cloud need respect using #state and writing #objects
    3. 3. Musing about some modern #misconceptions
    4. 4. We cannot take it for granted that…  The network is reliable  Latency is negligible  bandwidth is infinite  the net is safe  the topology doesn't change  The transport cost is negligible/zero  the network is homogeneous  there is only one administrator Mauro Servienti - http://www.communitydays.it/events/2014/vs06/
    5. 5. Objects in the Cloud Can we apply traditional object oriented principles to the #cloud? Can we think #state as just #objects value?
    6. 6. Why thinking about #state? #state does not fits so well in the #cloud with: #network #scaling #mainteinance #performances
    7. 7. What is #state here?
    8. 8. Understanding #state and #behavior
    9. 9. What is state? Is a set of attributes (of something) that allows you to identify and characterize it State is something that is maintained in absence of inputs
    10. 10. State and #software Every software program have a #state That state is what we want for the program In #traditional software development we don’t focus on #state, it’s just there We focus on behavior and how to express it
    11. 11. What is a behavior?  It’s something you can do on a state to change it  Everything you do is to change yourself (at least!)  Many ways to express behavior  Imperative  “Run that behavior on that state”!  Functional  It’s a relationship between values  It’s a relationship between state (of something) in two different times (before and after)
    12. 12. Why state and behavior are important? Because statet+1=behaviorj(inputt, st) Where t and t+1 are two consecutive instants And there are cases where statet+1=statet
    13. 13. Where is state?  In memory  Variables  In transient storages (timeout): faster more than infinite  Caches  Sessions  In persistent storage (tinfinite - MTBF)  Blobs  In structured data  Files  Databases
    14. 14. Choose the right representation Choosing the right representation of the state is the most difficult part of an application Relational Database is a choose, not a starting point
    15. 15. State and the Cloud In the #cloud, the state is the most important thing Define the correct state and how to represent it
    16. 16. Just objects
    17. 17. What is an object? It is state and behavior in the same “place”
    18. 18. What is an attribute? Is a characteristic (of an object) you can measure (it has a value)
    19. 19. Some quotes Everything is an object… …so everything have a state …so everything have a behavior If an object have no behavior, is still an object? Or is just state? If an object have no state, but only behavior, is still an object?
    20. 20. What is modeling? Is the activity of shaping objects
    21. 21. What is an entity Is something you can model
    22. 22. You as programmer… …model entities into objects
    23. 23. What is OOP (Object Oriented Programming)? It’s a way of modeling everything as an object, with state and behavior …and classes?
    24. 24. Objects, non classes We can speak about objects without referring to classes, ever!
    25. 25. What is a class? A #class is a model for objects A #class is a way to define a model for objects A #class is the typical way to define objects models in a strongly typed (not yet statically typed) language (C#, Java, but also Python and Ruby) There are other ways
    26. 26. Does a class-based language imply OOP? No, OOP is a way of thinking and modeling at first Class-based languages cannot be an excuse to avoid real principles
    27. 27. What is a prototype Is an object itself you can use as a model to create others objects copying from it #javascript teaches us that we can write #objects without #classes
    28. 28. Objects in the Cloud Edizione 2014 Marco Parenzan