+ All Categories
Home > Technology > Generating Insights from WSO2 API Manager Statistics

Generating Insights from WSO2 API Manager Statistics

Date post: 20-Aug-2015
Category:
Upload: wso2
View: 456 times
Download: 0 times
Share this document with a friend
Popular Tags:
32
WSO2 Dinusha Senanayake, Amila De Silva Generating insight from WSO2 API Manager Statistics Dinusha Senanayake, Amila De Silva Dinusha Senanayake, Amila De Silva Dinusha Senanayake, Amila De Silva
Transcript

WSO2Dinusha Senanayake, Amila De Silva

Generating insight from WSO2 API Manager Statistics

Dinusha Senanayake, Amila De Silva Dinusha Senanayake, Amila De Silva Dinusha Senanayake, Amila De Silva

About the PresentersDinusha joined WSO2 in September 2010. She is a senior software engineer in the WSO2 API Manager team where she mainly focuses on the development of the product. In addition to her product development efforts she has provided development support and technology consulting on customer engagements, including customer QuickStart programs focused on SOA integration.

Amila joined WSO2 in September 2012. he is a software engineer in the WSO2 API Manager team. In addition to his product development efforts he has provided development support and technology consulting on customer engagements, including customer QuickStart programs.

3

About WSO2๏ Global enterprise, founded in

2005 by acknowledged leaders in XML, web services technologies, standards and open source

๏ Provides only open source platform-as-a-service for private, public and hybrid cloud deployments

๏ All WSO2 products are 100% open source and released under the Apache License Version 2.0.

๏ Is an Active Member of OASIS, Cloud Security Alliance, OSGi Alliance, AMQP Working Group, OpenID Foundation and W3C.

๏ Driven by Innovation

๏ Launched first open source API Management solution in 2012

๏ Launched App Factory in 2Q 2013

– Launched Enterprise Store and first open source Mobile solution in 4Q 2013

Insights

Insights

OperationalUseful when scaling up

the system/upgrading system resources

BusinessUseful for

expanding business / API Ecosystem

Operational Insights

Operational Insights๏ Production Systems involve many nodes

๏ Operational conditions change over the time

๏ Nodes can become non-responsive at certain times.

๏ It's hard to monitor many different machines all the time

๏ Performance Hits – Why they occur?

๏ Certain situations are transient – Observed repeatedly but hard to re-create

๏ System resources may not be fully utilized

๏ Bottlenecks may be occurring at unsuspecting locations – but remedies are applied to entirely different places.

What's available in the platform?๏ Tracing a call across many different servers.

๏ Useful for doing RCAs and figuring out the actual problem.

๏ Perform Retrospective analysis using offline data – May provide clues how to detect possible failures early.

๏ Using CEP to analyze runtime conditions

๏ CEP can measure changes in operational parameters – CPU,Memory, Response Times

๏ Can trigger alerts when certain changes occur under a pattern.

Structure of an EventName : Value

Description : Publish Message Tracing Event

Name : BAM_MESSAGE_TRACE

Nick_Name : MessageTracerAgent

StreamId : BAM_MESSAGE_TRACE:1.0.0

Timestamp : 1393227712801

Version: 1.0.0

correlation_activity_id : 1667815083593519812943

meta_host : 192.168.151.1:9765

meta_server : Application Server

payload_message_direction : OUT

payload_operation_name: greet

payload_service_name : HelloService

payload_status : success

payload_timestamp: 1393227712801

A Typical Deployment

Message Tracking - BAM

Message Tracking - CEP

Business Insights

Sample - Pizzashack๏ Consists of three APIs

๏ Menu – Retrieves all different Pizzas available

๏ Order – Places and order, get the state of an order.

๏ Delivery – Invoked when a delivery is done, change the state of an order

๏ Web Application uses these APIs

๏ End users log into the Web App and place orders.

๏ Data will be collected when users place the orders. These will be used for generating statistics.

๏ In this sample Pizzashack Owner is the Service Providers

Parties in an Ecosystem

Parties In an Ecosystem..

Business OwnersGoal : Increase Sales volume1.Retain existing customers.2.Introduce new Offers.3.Group common Items together.

API CreatorsGoal:Model Better APIs1.Expose only right amount of Data.2.Combine fine granular APIs

APP DevelopersGoal:Increase App Downloads 1.Improve User Experience2.Increase availability on different platforms

Parties In an Ecosystem..

Business OwnersWhat : Business Related Data, Request Payloads1.Find commonly moving items.2.Individual customer trends.3.Possible store locations.

API CreatorsWhat: API Call frequency, payload sizes, Response Times1.Improve frequently called APIs.

APP DevelopersWhat: No of calls sent through App,Locations where calls came from,Types of Devices Used1.Improve User Experience2.Increase availability on different platforms

What API Manager offers● Data gathering framework

● Works hand in hand with BAM,CEP

● Three streams – Request,Response and Fault

● Can be extended to gather request payloads.

● Data Analyzing Capabilities

● Leverages BAM and CEP

● BAM – Used for Analyzing Offline Data

● CEP – Used for Analyzing and reacting in realtime.

● Analyzing can be extended to achieve business specific requirements.

What API Manager offers...● Statistics Dashboard

● Displays Business Agnostic Stats by default

● No of subscriptions, No of Invocations, Response Times...

● Displays Basic Usage Data

● Google Analytics Handler

● Useful for getting quick break down of Geographic Distributions, Devices being used

CEP – Demo

๏ Triggering Events when Delivery takes more than a specified time.

Structure of EventsDefault Event Stream

{

'name':'org_wso2_apimgt_statistics_request',

'version':'1.0.0',

'nickName': 'API Manager Request Data',

'description': 'Request Data',

'metaData':[

{'name':'clientType','type':'STRING'}

],

'payloadData':[

{'name':'consumerKey','type':'STRING'},

{'name':'context','type':'STRING'},

{'name':'api_version','type':'STRING'},

{'name':'api','type':'STRING'},

{'name':'resource','type':'STRING'},

{'name':'method','type':'STRING'},

{'name':'version','type':'STRING'},

{'name':'request','type':'INT'},

{'name':'requestTime','type':'LONG'},

{'name':'userId','type':'STRING'},

{'name':'tenantDomain','type':'STRING'},

{'name':'hostName','type':'STRING'},

{'name':'apiPublisher','type':'STRING'},

{'name':'applicationName','type':'STRING'},

{'name':'applicationId','type':'STRING'}

]

}

Custom Event Stream

{

'name':'org_wso2_apimgt_custom_stream',

'version':'1.0.0',

'nickName': 'API Manager Open API Request Data',

'description': 'Open API Request Data',

'payloadData':[

{'name':'context','type':'STRING'},

{'name':'api_version','type':'STRING'},

{'name':'resource','type':'STRING'},

{'name':'method','type':'STRING'},

{'name':'name','type':'STRING'},

{'name':'version','type':'STRING'},

{'name':'requestTime','type':'LONG'},

{'name':'requestId','type':'STRING'},

{'name':'subscriber','type':'STRING'},

{'name':'clientAddress','type':'STRING'},

{'name':'oderId','type':'STRING'}

]

}

Statistics Dashboard View

GA tracking๏ Track API Calls like page visits

๏ API Resource Path is taken as the page.

๏ Show number of API calls against time.

๏ Useful for finding peak loads, frequently used days.

๏ Alternative platform for analyzing data.

๏ Web Applications can send the cookies along with API Calls

๏ Using _utmcc parameter, cookie details will be sent – This is useful for tracking campaigns, previously visited sites, and invoker details such as gender, age range.

๏ Useful for marketing campaigns – Which age group, gender should be targetted.

GA – Geographical Breakdown

GA- Device Wise Breakdown

GA Usage๏ Using GA Application Developers can ;

๏ Find out on which platform APIs are used most – Hence can improve User Experience on those platforms.

๏ Indicate possible App markets – API may be used mostly on Android – but particular App developer might not have developed an App for that platform.

๏ Considering the Geographical break down App developers can determine which languages should be supported.

๏ API Creators can:

๏ Determine on which languages data should be made available.

๏ Test on mostly used platforms before rolling out changes/introducing new APIs.

๏ Business Owners can;

๏ Determine possible places to open up new stores.

๏ Introduce Regional Varieties.

Summary

๏ Usage of Operational Insights

– How to use BAM to track messages across different servers.

– How CEP is used to calculate response times in real time.

๏ Different Roles involved in an API Ecosystem

๏ Using Google Analytics as a complementary analytics tool

๏ Generating Insights from Statistics Dashboad.

27

What WSO2 delivers

28

Business Model

29

Call to action page

๏ Include links to product downloads, white paper downloads , etc.

30

31

Contact us !


Recommended