microservices and iot with adobe experience manager

41
© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential. Microservices and IoT David Bosschaert and Carsten Ziegeler

Upload: duongdieu

Post on 14-Feb-2017

227 views

Category:

Documents


0 download

TRANSCRIPT

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Microservices and IoT David Bosschaert and Carsten Ziegeler

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

I am doing IoT !

D

2

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

I am doing IoT !

D

3

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

D

David Bosschaert

• R&D Adobe Ireland

• Co-chair OSGi Enterprise Expert Group

• Apache Felix, Aries PMC member and committer

• … other opensource projects

• Cloud and embedded computing enthusiast

4

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Carsten Ziegeler

RnD Adobe Research Switzerland

Team Lead / Founder of Adobe Granite

Member of the Apache Software Foundation

VP of Apache Felix and Sling

OSGi Expert Groups and Board member

5

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

IoT

6

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

💡

C

IoT Hello World!

7

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

I am doing IoT ?

D

8

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

?

D

IoT and AEM

9

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Gateway

zwave

zigbee

D

IoT and AEM

10

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

OSGi for Gateway and Cloud

Unified platform

Share & Reuse

Provisioning, tooling...

Dynamically updatable

11

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

OSGi Device Abstraction Layer

Devices and Functions

Protocol independent

12

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

OSGi IoT

Protocols (CoAP, MQTT)

Zigbee, EnOcean

Not limited to this

13

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Gateway

zwave

zigbee

Services

D A L

C

IoT

14

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

And now Camera, Lights, and…ACTION

D

15

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Photo credit:

www.bargainmoose.ca

20%

OFF

!

D

Demo Scenario

16

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Clipart credit:

pixabay.com

31%

OFF

!

D

Increase sale discount with the weather!

17

Photo credit:

www.bargainmoose.ca

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Gateway

D

Architecture

18

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Microservices

19

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Microservices

Do one thing but do it right

Resource optimizations

Focused development/testing

Reduced time to production

20

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Gateway

C

Microservices

21

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

LB

LB LB

LB

C

Scaling

22

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Orchestration

Various solutions

Containers

The twelve-factor app

Disposability

23

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

D

Communication

Discovery / Topology

REST

Distributed OSGi

24

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

D

OSGi Services

25

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

D

OSGi Remote Services

26

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Remote services auto-discovered via zookeeper/etcd/slp … integration

D

Remote Services – dynamic rebinding

27

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

class MyComponent { @Reference PaymentService paymentService; @Activate public void activate() { paymentService.makePayment(…); }

C

Using Local OSGi Services

28

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

class MyComponent { @Reference PaymentService paymentService; @Activate public void activate() { paymentService.makePayment(…); }

C

Using Remote OSGi Services

29

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

@Component(service=PaymentService.class) class MyPaymentService implements PaymentService { public boolean makePayment(…) { ... } }

C

Registering an OSGi Service

30

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

@Component(service=PaymentService.class, property="service.exported.interfaces=*") class MyPaymentService implements PaymentService { public boolean makePayment(…) { ... } }

C

Registering a Remote OSGi Service

31

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

class MyComponent { @Reference PaymentService paymentService; @Reference Async asyncService; @Activate public void activate() { PaymentService mediated = asyncService.mediate(paymentService, PaymentService.class); asyncService.call(mediated.makePayment(…)) .then(p -> updatePaymentStatus(p)); // … thread continues while payment service being called …

C

Asynchronous Services

32

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

D

Provisioning

Cloud : Orchestration of AEM/OSGi

Gateways : Manage through AEM/OSGi

33

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

FrameworkNodeStatus

service

NodeStatus

service

D

Cloud discovery and provisioning

RFC 183 Cluster Information (Cloud Ecosystems)

34

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Provisioning Model

Descriptive

Feature based

Complete

35

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Gateway PUSH

C

Models

Start

Add

Provisioning

36

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Requirements and Capabilities

Imports / Exports

Provided / Required Services

Functionality (whiteboard, extender)

Extensible (database)

37

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

OSGi Resolver & Repositories

Verify runnable configuration

Calculate required / missing modules

38

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

Media

Conversion

Resolver Media

Converter

Service

Start

Dynamic Provisioning & Orchestration

39

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

C

OSGi / AEM is the ideal base for IoT and Microservices

Endless possibilities with IoT

40

© 2016 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

THANK YOU.

41