Oliot epcis at a glance

Preview:

Citation preview

Jaewook ByunKorea Advanced Institute of Science and TechnologyReal-time and Embedded Systems Laboratory(RESL)

bjw0829@kaist.ac.kr

Oliot EPCIS At a glance

Table of Contents

1. Introduction2. Installation3. Tutorial4. Programming Guide

Introduction – RFID & GS1 EPC global

• Radio Frequency IDentification (RFID)• Identifiable and Traceable everyday-objects• The Internet of Things (IoT)

• GS1 EPCglobal• A complete suite of RFID standards

Introduction – EPCIS Standard

• EPC Information Service (EPCIS)• Recent version: version 1.1, May 2014• A distributed repository, which can capture and share EPC-based event/vocabulary accompanying 4W

(i.e. What, When, Where and Why)

Introduction – EPCIS Event

• EPCISEvent – Base event type• See. 7.2. section

Object Event Aggregation Event Transaction Event Transformation Event

Receiving time at Capturing ApplicationReceiving time at EPCIS repositoryTimeZone, offset from UTC

Extends

Introduction – EPCIS Event

• ObjectEvent• Observation of object(s)

(Optional)Instance level master data: e.g. expiration date

(Optional)

(Optional)

List of Observed objects

e.g. Created, Observed, Destroyed

c.f Red: new in EPCIS v1.1

Introduction – EPCIS Event

• AggregationEvent• Association between containing/contained object(s)

Aggregation Event(e.g. box, case, pallet)

e.g. Box, case, pallet

e.g. Trade items in box

e.g. child added, observed, or deleted from parents

(Optional)

Introduction – EPCIS Event

• Transaction Event• (Dis)Association of object(s) to business transaction(s)

Transaction Event(Optional)

e.g. Item (dis)associated to the BizTransaction

Business Step Business process e.g. Loading, Packing, Shipping, Receiving

Disposition Status of object Available for sale, in Storage

Business Transaction Transaction information e.g. Purchase, Invoice

Introduction – EPCIS Event

• Transformation Event• Capture the relationship between the input (source) and the outputs (product)

Input Outputs

(Optional)

c.f Red: new in EPCIS v1.1

COW Slides of Beef

Introduction – EPCIS Vocabulary

• Vocabulary (i.e. Master Data)• Represent static information on EPC

• Core Business Vocabulary (CBV)• supports base vocabularies for Supply Chain Management

• User Vocabulary• defined by user

• Vocabularies• Location: address, zip code, etc• Business Semantic

• Business Step: activity within a business process• Disposition: business state of an object• Business Transaction: purchase order

• Class-level item

[Examples of CBV]

Introduction – EPCIS Service

• EPCIS Services• Event Capture• Immediate Query• Scheduled Query

Introduction – Oliot EPCIS open source

• Oliot EPCIS• Open source web service compatible with EPCIS v1.1

• How implemented• Model Generation

• JAXB on standard XSD• Service Binding

• SOAP based on standard WSDL• Verification

• XSD verification• Running Environment

• Java Web Service ( Java v1.8, Servlet v3.1 )• Tomcat WAS ( v8.x )• MongoDB ( v3.x )

• Services• Service Bindings: SOAP, REST• Capture Service

• Event data / Master data• Query Service

• Standard ‘SimpleEventQuery’ (See EPCIS 8.2.7 )

BackendRepository

Event Data Master Data

Capture Service Listener

Cap

ture

Lay

er

Application

Quer

y La

yer

Poll Subscription

Scheduler

Schedule Destination

App

Query Service Receiver

Oliot-EPCIS

SOAP/HTTPREST/HTTP

Object-Relational Mapper(POJO Storage Unit)

JAXB Marshaller(XMLPOJO)

Document Validator

Capture

Immediate QueryStanding Query

EPCIS DOC

ResultSOAP/HTTPREST/HTTP

JAXB Unmarshaller (POJO XML)

Object-Relational Mapper(Storage Unit POJO)

XML/JSON

Installation - Prerequisite

• Install Java 8

• Install Tomcat 8

• Install MongoDB 3

• Download ‘epcis.war’ from

• https://github.com/gs1oliot/oliot-epcis-1.1/tree/master/epcis/target or

• https://github.com/JaewookByun/epcis/tree/master/epcis/target

• Locate ‘epcis.war’ into [tomcat-folder]/webapps

Installation

• Run MongoDB• Run Tomcat Server• See it starts• Access [ip:port]/epcis

Tutorial: How to make EPCIS document

• Based on GS1 Global Forum 2015 tutorial• You can access it via [ip:port]/epcis/tutorialPage.jsp

How?

Guide three fundamental events

Tutorial: How to make EPCIS document

• Capture your event 1

Tutorial: How to make EPCIS document

• Standard XML format for Event 1

Tutorial: How to make EPCIS document

• Capture your event 2

Tutorial: How to make EPCIS document

• Standard XML format for Event 2

Tutorial: How to make EPCIS document

• Capture your event 3

Tutorial: How to make EPCIS document

• Standard XML format for Event 3

Tutorial: How to make EPCIS document

• Visualize it via queries to Oliot EPCIS

Tutorial: How to make EPCIS document (Bonus)

• When you want to insert Extra data beyond specification• Use extension field

• If your sensor generates two sensing values• sensorValue1: Float• sensorValue2: List of Integer

• Envelop your values using extension field• ObjectEvent can be a good candidate as an event type• The extra fields should be under a namespace

• e.g. device namespace• (Optional) if you formally define the fields using XSD

• We can get global consensus

sensorValue1: 15

sensorValue2: 10 12 14 19 23

[Example of EPCIS Document]

[(Optional)Example of your XSD]

Programming Guide

• Oliot EPCIS is web service• Write a code in language independent way

• e.g. C++, Java, Javascript, Python and etc.• Postman

• Good Tool for your testing• Sending your HTTP call

• e.g. POST, GETMethod Description

GetStandardVersion Return the standard version of EPCIS

EventCapture Capture your EPCIS Document into your backend storage

VocabularyCapture Capture your EPCIS Master Data Document into your backend storage

GetQueryNames Return a list of all query names available

Poll Return events/vocabularies stored in repository in interest immediately

GetSubscriptionIDs Return a list of all subscriptionIDs currently subscribed to the specified named query

Subscribe Register a subscriber for a previously defined query having the specified name

Unsubscribe Remove a previously registered subscription having the specified subscriptionID

Programming Guide

• Postman Example (GetStandardVersion)• Return the standard version of EPCIS

• Set URL• Then, Send with GET• See a version if succeed

Programming Guide

• Postman Example (Event Capture)• Make you capture your events

• Set URL• Prepare EPCIS document• Then, Send with POST• See HTTP.OK (200) if succeed

Programming Guide

• Postman Example (Vocabulary Capture)• Make you capture your vocabularies

• Set URL• Prepare EPCIS document• Then, Send with POST• See HTTP.OK (200) if succeed

Programming Guide

• Postman Example (GetQueryNames)• Return a list of all query names available

• Set URL• Then, Send with GET• See result if succeed

Programming Guide

• Postman Example (Poll Event Data)• Provide you stored events under

conditions you made

• Set URL with Parameter• Then, Send with GET• See result if succeed

• For more query examples• See [url:port]/epcis/rest-like-query-examples.html

Programming Guide

• Postman Example (Poll Master Data)• Provide you stored vocabularies under

conditions you made

• Set URL with Parameter• Then, Send with GET• See result if succeed

• For more query examples• See [url:port]/epcis/rest-like-master-query-

examples.html

Programming Guide

• Postman Example (Subscribe)• Provide you ‘periodically’ stored events

to ‘designated URL’ under conditions you made

• Set URL with Parameter• You can use ‘Poll’ parameters• Set additional Parameter

• e.g. dest: Your callback URL• e.g. cronExpression:

• See Rationale• See Cron Expression

• Then, Send with GET• Receive periodic result in Callback URL

Programming Guide

• Postman Example (GetSubscriptionIDs)• Returns a list of all subscriptionIDs currently

subscribed to the specified named query.

• Set URL• Then, Send with GET• See ID list if succeed

Programming Guide

• Postman Example (Unsubscribe)• Set URL with Parameter• Then, Send with GET• Receive periodic result in Callback URL

Further Information

• EPCIS v1.1 specification• Detailed description on • 4 core event types and master data• SimpleEventQuery• ...

• Embedded documentation• Access [base_url:port]/epcis after running your

Oliot EPCIS• Introduction• Service description

• Github• https://github.com/gs1oliot/oliot-epcis-1.1• https://github.com/JaewookByun/epcis

Reference

• GS1 EPCglobal: http://www.gs1.org/epcglobal• EPCIS v1.1: http://www.gs1.org/sites/default/files/docs/epc/epcis_1_1-standard-20140520.pdf• CBV v1.1: http://www.gs1.org/sites/default/files/docs/epc/cbv_1_1-standard-20140520.pdf• Oliot Homepage: http://gs1oliot.github.io/oliot/• Github

• https://github.com/gs1oliot/oliot-epcis-1.1• https://github.com/JaewookByun/epcis

Thank you

Recommended