Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

FMK2019 being an optimist in a pessimistic world by vincenzo menanno

37 views

Published on

Being an Optimist in a Pessimistic World by Vincenzo Menanno

Published in: Education
  • Be the first to comment

  • Be the first to like this

FMK2019 being an optimist in a pessimistic world by vincenzo menanno

  1. 1. Being an Optimist in a Pessimistic World 10. FileMaker Konferenz | Hamburg | 16.-19. Oktober 2019 www.filemaker-konferenz.com
  2. 2. Who am I? Been developing solutions with FileMaker since FileMaker 2.1 - Certified in versions 7 - 18 - Talented and Diverse Team @ Beezwax 🐝 Things I love… - Research and Development - Data Visualization ( Tableau, D3, etc… ) - Hiking - Sharp Knives - Architecture Vincenzo Menanno
  3. 3. Dramatically reduce network traffic! What If…
  4. 4. Less network traffic… translates into. Less work for the server Less network traffic on your network Sending only changed values Reduce number of locks server needs to manage Savings if you are using AWS
  5. 5. Significantly improve performance. And What If…
  6. 6. This enables things like … The ability to audit changes Store data transactionally Faster rendering and responsiveness
  7. 7. Pessimistic vs Optimistic Differences The Journey Tools Techniques
  8. 8. Break the rules…
  9. 9. FileMaker pessimistic record locking Record locked for duration of edit Server keeps tracks of Locks Edit happens locally The whole record is always transported Record modification count
  10. 10. O optimistic record locking Record locked only for committing data Server doesn’t have more work Edits happen on server Send only changes Use hashes instead modification counts Compare with Past, Present & Future E ^ 👻
  11. 11. Calculations unstored —> stored Log Audits Local editing (many benefits) And no additional traffic on network E ^ optimistic record lockingO there is more…
  12. 12. ⚠ WARNING 🚧 🚧🚧 🚧 Percent of Tasked Completed Project Task Year # Projects each Year Has to have transactional integrity Last Update 06/16/2019 04:33 PM Eventual integrity
  13. 13. ⚠ WARNING 🚧 🚧 🚧 🚧 Implications (not for everyone) Solution Complexity Types of Updates - Transactional Integrity - Eventual Integrity Transactions with FileMaker
  14. 14. Test & Measure 🛠 Test out new ideas Establish a Baseline Measure Need built in native tools - for measurements - for errors
  15. 15. 🛠 NetworkMonitor Tool 🛠
  16. 16. Native Editing Globals ( popovers and cards ) Local File Editing Local File Editing (Data API) Commit Footprint 3 Hashes (past, present, future) A twist on MVC (model, view, controller) The Journey
  17. 17. What is it Implementation How is it helpful The Commit Footprint
  18. 18. Convert Calculations From Unstored —> Stored Sum ( TASK::AMOUNT ) If ( UPDATE ; “” ) & Sum ( TASK::AMOUNT ) )
  19. 19. Commit Footprint | What Set Variable [ $_outer_start; Value: UTCMilli ] //Perform Script [ “. commit footprint”; P: "5463" ] [ Wait ] Perform Script on Server [ “. commit footprint”; P: "5463" ] [ Wait ] Set Variable [ $_inner_duration; Value:Get ( ScriptResult ) ] Set Variable [ $_outer_end; Value: UTCMilli ] Set Variable [ $_outer_duration; Value:$_outer_end - $_outer_start ] UTCMilli = Get ( CurrentTimeUTCMilliseconds ) / 1000
  20. 20. Commit Footprint | What Set Variable [ $_id; Value:Get ( ScriptParameter ) ] Go to Layout [ “JOB” (JOB) ] Perform Find [ Find Requests: Find Records: JOB::ID: “$_id” ] Set Variable [ $_inner_start; Value: UTCMilli ] Set Field [ JOB::UPDATE; Get ( CurrentHostTimestamp ) ] Commit Records/Requests [ No dialog ] Set Variable [ $_inner_end; Value: UTCMilli ] Set Variable [ $_inner_duration; Value:$_inner_end - $_inner_start ] Exit Script [ Result: "Inner: " & $_inner_duration ] UTCMilli = Get ( CurrentTimeUTCMilliseconds ) / 1000
  21. 21. Commit Footprint | Benefits measurement on local area network Local Area Network PS PSoS Percent outer 0.078 0.097 -24.3% inner 0.038 0.012 99.3%
  22. 22. Commit Footprint | Benefits measurement from Hayward about 25 miles away Wide Area Network PS PSoS Percent outer 1.134 0.145 87.2% inner 0.982 0.009 99.1%
  23. 23. Commit Footprint | Benefits measurement from Oakland about 50 miles away Wide Area Network PS PSoS Percent outer 1.554 0.265 82.9% inner 1.268 0.009 99.3%
  24. 24. Commit Footprint | Benefits measurement from London about 5359 miles away Wide Area Network PS PSoS Percent outer 3.03 0.279 90.8% inner 2.073 0.009 99.6%
  25. 25. Case Study Changes Items Before After % Change Basetables 46 33 -28.3% Tables 158 89 -43.7% Fields 985 549 -44.3% Scripts 271 147 -45.8% Layouts 97 47 -51.5% Unstored Cals 103 9 -91.3% Total 152’728 54805 -64.1%
  26. 26. Case Study | Benefits Performance Before After % Change Open 33 5 84.8% New Project 19 2 89.5% Project List 10 2 80% Admin View 15 1 93.3%
  27. 27. Get ( RecordModificationCount ) 1 2 3 4
  28. 28. MD5 Hash Ghosts 👻 - Past (original data) 👻 - Present (server data) 👻 - Future (changed data)
  29. 29. GetContainerAttribute ( List ( EventLocal::Event_Name ; EventLocal::Date_Start ; EventLocal::Date_End ; EventLocal::Event_Description ) ; "MD5" ) You can use GetContainerAttribute with non container fields!
  30. 30. MVC - Model | View | Controller Model View Controller Layout Local StorageScripts
  31. 31. Demos
  32. 32. Data Transferred
  33. 33. Globals ( popovers and cards ) Local File Editing Local File Editing (Data API) The Journey
  34. 34. Single Add or Edit Data validated before creation Drawback: Multiple Edits Globals
  35. 35. Single Add or Edit Data validated before creation Support for multiple edits Very verbose to put in place Local File Editing
  36. 36. Single Add or Edit but can be multiple Data validated before creation Support for multiple edits Less verbose but more complexity Local File Editing (Data API)
  37. 37. Pessimistic vs Optimistic Recap
  38. 38. xDifferences between Techniques Commit footprint / Local file editing Warnings Important things to consider Different approaches Global | Local | Data API MVC Clear separation & easy to implement Generating Hashes 👻 of past, present, and future
  39. 39. Resources Network Monitor Tool for FileMaker - search for Network Monitor Transactions Todd Geist - https://www.youtube.com/watch?v=FQzXs9SXt-U Native Imports on Server - https://blog.beezwax.net/2019/05/22/imports-without- tariffs-natively-with-filemaker-server/ Greg Lane (Tuesday 2:45 PM) - Maximizing FileMaker Performance Chris Irvine (concurrently) - Doing it Right: Fast Solutions Developed WAN First Under the Hood: Exploring FileMaker Server 18’s Performance Features My recorded DevCon Session https://www.youtube.com/watch?v=g00xNgjKzv0 👻 👻 👻
  40. 40. Credits and Images Slide: Luciano peeking Through - Vince Menanno Footprint: https://unsplash.com/photos/BqpdGGfezFw Piano - https://unsplash.com/photos/QNghR29tHR0 Choices - https://unsplash.com/photos/PXB7yEM5LVs Coffee Test - https://unsplash.com/photos/i22gbC3gFm4 Journey - https://unsplash.com/photos/5hvn-2WW6rY
  41. 41. Thank you

×