33
What’s New in Java. Leveraging Java in Hybrid Cloud Val Chibisov, Senior Product Manager

AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Embed Size (px)

Citation preview

Page 1: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

What’s New in Java. Leveraging Java in Hybrid Cloud Val Chibisov, Senior Product Manager

Page 2: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Agenda

1.  What’s new in Java? Java 8 – Memory Model 2.  JVM-based Languages 3.  Hybrid Cloud 4.  Microservice Refactoring

Copyright © 2015 AppDynamics. All rights reserved. 2

Page 3: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

JAVA 8 – MEMORY MODEL

Page 4: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 7 – Recap – Java Memory Model

Copyright © 2015 AppDynamics. All rights reserved. 4

Eden Survivor Survivor

Old Gen

Perm Gen

Heap -Xmx

Native Memory

Page 5: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 8 – Recap – Java Memory Model

Copyright © 2015 AppDynamics. All rights reserved. 5

Eden Survivor Survivor

Old Gen

Heap -Xmx

Native Memory

Metaspace

Page 6: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 8 – PermGen Issues

•  PermGen necessary size is hard to predict –  Results in either under-provisioning or over-provisioning

•  GC performance improvements

•  Support for advanced optimizations –  G1 concurrent class unloading

Copyright © 2015 AppDynamics. All rights reserved. 6

Page 7: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 8 – Metaspace Changes

•  PermGen –  Memory space is gone

•  Metaspace memory allocation model –  Most class metadata is now allocated out of native memory –  No more classes which are used to describe class metadata

•  Metaspace capacity –  Out of the box available allocation space is limited by the amount of available native

memory –  Dynamically resizes depending on the allocation demand at runtime –  Possible to use a flag (-XX:MaxMetaspaceSize=Y) in order to limit the amount of

native memory used for class metadata

Copyright © 2015 AppDynamics. All rights reserved. 7

Page 8: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 8 – Metaspace Changes Ctd

•  Metaspace garbage collection –  Garbage collection is triggered once the class metadata usage reaches the MaxMetaspaceSize –  Excessive Metaspace GCs may point to:

•  Memory leaks of classes •  Memory leaks of classloaders •  Improper allocation sizing

–  Metaspace tuning and monitoring is highly important to limit the frequency/delay of these GCs

•  Java heap space impact –  There may be some increase of Java heap due to various data being moved to Java heap space

•  Metaspace monitoring –  Hotspot 1.8 GC logs provide Metaspace usage –  AppDynamics!

Copyright © 2015 AppDynamics. All rights reserved. 8

Page 9: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Java 8 – Metaspace – Magic Bullet?

•  Magic Bullet? –  Not quite –  Memory caveats still remain

•  Requires proper monitoring and proactive remediation –  Class metadata memory footprint –  Class memory leaks –  Class loader memory leaks

Copyright © 2015 AppDynamics. All rights reserved. 9

Page 10: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

AppDynamics – Passive Metaspace Monitoring

Copyright © 2015 AppDynamics. All rights reserved. 10

Page 11: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

AppDynamics – Proactive Metaspace Monitoring

Copyright © 2015 AppDynamics. All rights reserved. 11

Page 12: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

JVM-BASED LANGUAGES & APPDYNAMICS

Page 13: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Scala

Copyright © 2015 AppDynamics. All rights reserved. 13

•  JVM-based flexible programming language

•  Rising in popularity due to its extremely flexible functional-object-oriented approach and Java interoperability

Page 14: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Groovy

Copyright © 2015 AppDynamics. All rights reserved. 14

•  Dynamic JVM-based object-oriented programming language

•  Best trait: simplicity, dynamic language

•  Superset of Java – easier to adopt

Page 15: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

JRuby

Copyright © 2015 AppDynamics. All rights reserved. 15

•  JVM-based programming language

•  Full access to Java toolchain

•  Real system threads

Page 16: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

JVM-based Language Stack Monitoring

Copyright © 2015 AppDynamics. All rights reserved. 16

•  AppDynamics enables deep monitoring and troubleshooting of JVM-based languages!

•  Proactive alerts

•  Distributed cross-stack environment monitoring!

Page 17: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

HYBRID CLOUD & APPDYNAMICS

Page 18: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Public Cloud

Copyright © 2015 AppDynamics. All rights reserved. 18

•  Mutlitenant environment

•  You own a slice of a server in a cloud environment shared by other clients

•  Generally used for web servers or dev systems

Public

Page 19: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Public Cloud – Trade-Offs

Copyright © 2015 AppDynamics. All rights reserved. 19

•  Hardware Sharing –  Meeting compliance requirements is near to impossible in a public cloud

•  Scalability –  On-demand resource availability

•  Location independence –  Use computing resources local to clients/users Public

Page 20: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Private Cloud

Copyright © 2015 AppDynamics. All rights reserved. 20

•  “Single-tenant” environment dedicated to a single entity such as a client or company

•  Expanding on traditional enterprise datacenters

Private

Page 21: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Private Cloud – Trade-Offs

Copyright © 2015 AppDynamics. All rights reserved. 21

•  Security –  Cloud is scoped for a single entity –  Only such entity has access to the information in the private cloud –  Achieving compliance is much easier

Private

•  Resource Management –  Manual management of computing resources

including: purchasing, housing, updating and maintaining

•  Direct Control

Page 22: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Hybrid Cloud

Copyright © 2015 AppDynamics. All rights reserved. 22

•  Combination of a Public Cloud Provider & Private Cloud Platform

•  Huge surge in the adoption in the recent years

Hybrid

Private Public

Page 23: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Hybrid Cloud

Copyright © 2015 AppDynamics. All rights reserved. 23

•  Allows storage and processing of privileged data and applications in private cloud

•  Enables the use of vast computational resources of the public cloud that relies on the sensitive data from private cloud

•  Unique benefits of “Cloud Bursting” Hybrid

Private Public

Page 24: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Monitoring Hybrid Cloud

Copyright © 2015 AppDynamics. All rights reserved. 24

•  Monitoring of complex Hybrid Cloud set-ups is far from straightforward

•  Requires a solution that can trace distributed execution from private to public cloud and vice versa

•  Identification of the root-cause becomes extremely problematic

Hybrid Private Public

Page 25: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

AppDynamics & Hybrid Cloud

•  Distributed tracing from private cloud infrastructures all the way to the public cloud services

•  Identify which services are causing issues down to the line number

Copyright © 2015 AppDynamics. All rights reserved. 25

Page 26: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

MICROSERVICES & APPDYNAMICS

Page 27: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Microservices

Copyright © 2015 AppDynamics. All rights reserved. 27

•  Big shift in modern enterprise

•  Move from monolithic architectures to groups of independently deployable services

•  Huge surge in the adoption in recent years

Microservices

Page 28: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Microservices vs Monolithic

Copyright © 2015 AppDynamics. All rights reserved. 28

Microservices Monolithic

Page 29: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Monolithic Architecture

Copyright © 2015 AppDynamics. All rights reserved. 29

•  Encapsulates all of the functionality in a single application

•  Traditional “Layered” approach to building systems

•  Drawbacks: –  Agility is hindered –  Technology stack is hard to change –  Changes to the system requires complete rebuilding of entire

application

Monolithic

Page 30: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Microservices Architecture

Copyright © 2015 AppDynamics. All rights reserved. 30

•  Transforms a single application into a number of smaller “services”

•  Typical service exhibits the following characteristics –  Independently deployable/upgradable –  Encapsulates a single “smaller” functionality –  Clear module boundary

•  Drawbacks: –  Remote API calls can and will quickly become expensive –  Requires re-aligning of different teams –  Data consistency potentially needs to be actively managed

Microservices

Page 31: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Monitoring Microservices

Copyright © 2015 AppDynamics. All rights reserved. 31

•  Microservices are highly distributed by nature

•  Monitoring health and performance becomes crucially important –  API calls need to be streamlined –  More individually moving parts = more ambiguity –  Hard to nail down the root of the problem

Microservices

Page 32: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Microservices & AppDynamics

Copyright © 2015 AppDynamics. All rights reserved. 32

Page 33: AppSphere 15 - What's New in Java: Leveraging Java in Hybrid Cloud

Thank You