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.

Seven Deadly Sins


Published on

Seven ways to kill you Java EE Project.

Published in: Technology

Seven Deadly Sins

  1. 1. sevenSeven deadly sins.Seven ways to die.
  2. 2.
  3. 3.
  4. 4.
  5. 5. Browser OS HW Network JVM OS HW DB OS HW
  6. 6. ~ „Im ready. Im ready. Im ready. Im ready. ” LUST  a passionate desire for something  our absorbent yellow friend is an extremely lustful creature  will often stop at nothing to complete a taskSpongebob Lust or lechery (carnal "luxuria") is an intense desire. It is usually thought of as excessive sexual wants, however the word was originally a general term for desire. Therefore lust could involve the intense desire of money, fame, or power as well.
  7. 7. Golden-taps  Least valuable features at all  Not limited to UI – could also be another fancy something.  Find metrics to identify them  Might be a needed thing. LUST
  8. 8. Over Engineering  (outdated) way of applying patterns  (too many) interfaces  Solving tomorrows problems  Premature optimizationLUST
  9. 9. Premature Technologies  Remember: We are building things for business  Know the technologies you use  Alpha, Beta, Snapshot have different meanings  Don’t use everything you know that looks fancy LUST
  10. 10. Not invented here  Might be a corporate culture  Dangerous if applied to security LUST
  11. 11. ~ „Meow”Gluttony • Gary doesn’t do a whole lot besides eating and meowing, and the meowing is often due to the fact that he is hungry. • Gary is shown eating parts of their couch! Derived from the Latin gluttire, meaning to gulp down or wallow, gluttony (Latin, gula) is the over-indulgence and over-consumption of anything to the point of waste.
  12. 12. Performance  Non-functional requirements are requirements  Not taking care of performance at all  Different kinds of performance (development, runtime, etc.)  Throwing hardware at the problem  Caching (too much)Gluttony
  13. 13. Memory  Is less expensive than it was  There are limitations  Avoid creating unnecessary objects and always prefer to do Lazy Initialization  Always try to minimize mutability of a class  Dont try to outsmart the VM  Rely on your Application ServerGluttony  Profile your code
  14. 14. HttpSession Size  There to track state  Not your “in memory” cache  Control session lifetime  Be
  15. 15. Infrastructure  Know and control your Pool Sizes  Every connection allocates a thread  Know your threads; watch Thread-Dumps  Don’t try to work with your own threads  Trust your application serverGluttony
  16. 16. ~ „Will you please stop leaving yourWRATH undergarments on my front lawn? ” • hates his job at the Krusty Krab • portrayed as a general failure who refuses to acknowledge his own personal flaws. • a sarcastic sense of humor and resentment toward the society that doesn’t ‘appreciate’ his creativitySquidward Wrath (Latin, ira), also known as "rage", may be described as inordinate and uncontrolled feelings of hatred and anger. Wrath, in its purest form, presents with self-destructiveness, violence, and hate that may provoke feuds that can go on for centuries.
  17. 17. Mixing Technologies  Tempted to use Spring in your EE app?  Broad JVM ecosystem (Scala, Play, Akka, GWT, ..)  Know the technologies you’re working with and  Choose the right tool for the right job
  18. 18. Threading and Concurrency  EE was designed to provide an easy abstraction on concurrency and threading.  Don’t roll your own.  Don’t.  Ever.  If you need to: JCA => EE 7 will give you a valid opportunity to do it the right way (JSR 236)
  19. 19. Maintainability  Your no1 enemy is complexity!  Design for understandability  Less is more!
  20. 20. ~ „Oh, yes you do, no world means no money,GREED so either save the world, or youre fired! ” • constantly thinking of ways to turn a profit, even if it involves taking advantage of his friends or putting them in harmful situationsMr.Krabs Greed (Latin, avaritia), also known as avarice or covetousness, is, like lust and gluttony, a sin of excess. However, greed (as seen by the church) is applied to a very excessive or rapacious desire and pursuit of material possessions.
  21. 21. People and Resources  People are people. They are not resources. They are not capital. They are humans.  Too many people  Too many features  Two Juniors don’t make a Senior  Not licensing helpful tools  Cost cutting on environments / developer notebooks
  22. 22. ~ „Lady, someone should put you in a box toENVY drift in the river! ” • His life’s goal is to steal the Krabby Patty formula from his Krabs and drive his primary competitor out of business. Like greed and lust, Envy (Latin, invidia) is characterized by an insatiable desire. Envy is similar to jealousy in that they both feel discontent towards someones traits, status, abilities, or rewards. The difference is the envious also desire that entity and covet it.
  23. 23. Weaknesses in EE Specifications  aka application server specific features  Will kill you effectively multiple times New version of same server Different server Different spec version
  24. 24. ~ „ Its okay. Take your time. ”SLOTH • Patrick is given an award for ‘doing absolutely nothing longer than anyone else’ Sloth (Latin, Socordia) can entail different vices. While sloth is sometimes defined as physical laziness, spiritual laziness is emphasized. Failing to develop spiritually is key to becoming guilty of sloth. In the Christian faith, sloth rejects grace and God.
  25. 25. “Efficiency is intelligent laziness.” No refactoring No reuse Copy and Paste Too simple No improvement No peer reviews
  26. 26. ~ „ See? Hes worse than I thought. ”PRIDE • Sandy is quick to spout off about the greatness of the Lone Star state or to show off her athleticism in a karate match or a weightlifting contest. In almost every list, pride (Latin, superbia), or hubris (Greek), is considered the original and most serious of the seven deadly sins, and the source of the others.
  27. 27. "No, nothing, said Dumbledore, and a greatsadness filled his face” No usability testing No behavior testing No acceptance testing No business testing No unit testing No performance testing No security testing
  28. 28. I can do it better … I am better … See “lust” ..oO(“not invented here”) There shouldn’t be an “almighty” architect/designer/anything Development is a team effort
  29. 29. Q&A