Project ZeroでServer Side Mashup - IBMpublic.dhe.ibm.com/software/dw/jp/offers/projectzero/... ·...

67
1 Project ZeroServer Side Mashup 小出 理史(日本IBMシステムズ・エンジニアリング) 須江 信洋(日本IBM) Wakhok Night Seminar 2007Project Zeroコース(第4回)

Transcript of Project ZeroでServer Side Mashup - IBMpublic.dhe.ibm.com/software/dw/jp/offers/projectzero/... ·...

  • 1

    Project ZeroでServer Side Mashup

    小出 理史(日本IBMシステムズ・エンジニアリング)須江 信洋(日本IBM)

    Wakhok Night Seminar 2007: Project Zeroコース(第4回)

  • 2

    この資料に含まれる情報は可能な限り正確を期しておりますが、日本アイ・ビー・エム株式会社及び日本アイ・ビー・エム システムズ・エンジニアリング株式会社の正式なレビューを受けておらず、当資料に記載された内容に関して日本アイ・ビー・エム株式会社及び日本アイ・ビー・エム システムズ・エンジニアリング株式会社は何ら保証するものではありません。従って、この情報の利用またはこれらの技法の実施はひとえに使用者の責任において為されるものであり、資料の内容によって受けたいかなる被害に関しても一切の保証をするものではありません。当資料をコピー等で複製することは、日本アイ・ビー・エム株式会社及び日本アイ・ビー・エム システムズ・エンジニアリング株式会社および執筆者の承諾なしではできません。また、当資料に記載された製品名または会社名はそれぞれの各社の商標または登録商標です。

    ご注意

  • 3

    本日のゴール

    Atomの重要性を理解するProject Zeroでの「マッシュアップ」のやり方を理解する

    AtomサポートFlowとIntegration Fabric

  • 4

    アジェンダ

    1. Atom基礎2. ZeroのAtomサポート3. Zeroのマッシュアップ機能4. M2新機能と将来計画

    注)本資料の記載内容は2007/11/8時点(Milestone2)に基づいています。Milestone3以降では変更される可能性がありますのでご了承下さい。

  • 5

    はじめに

    前回までの内容

  • 6

    第1回:Project Zero,背景と概要

    1. Project Zeroの背景2. RESTとWebサービス3. スクリプト言語とWebアプリケーション4. Project Zero First Look

    【セミナー資料ダウンロード】http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=45

    http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=45

  • 7

    第2回:GroovyとProject Zero

    1. スクリプト言語とは2. Javaとスクリプト言語3. Groovy4. Closure5. Projecrt ZeroとGroovy

    【セミナー資料ダウンロード】http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=46

    http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=46

  • 8

    第3回:2時間でRESTfullなアプリを作って動かす - Project Zeroを体験しよう!-

    1. Project Zeroの構成要素2. RESTfulアプリケーション開発入門

    (ハンズオン)

    3. 実践的なアプリケーション開発のために4. まとめと補足

    【セミナー資料ダウンロード】http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=53

    http://news.tokyo.wakhok.ac.jp/x/modules/mydownloads/singlefile.php?cid=13&lid=53

  • 9

    Project Zeroとは?

    「シンプル」かつ「パワフル」な、Webアプリケーションプラットフォーム過去のしがらみからの脱却

    ≠JavaEE、≠コンテナモデルスクリプト言語(Groovy/PHP)で開発Web2.0的用途に特化

    アーキテクチャをゼロから再構築

    オープンな環境化での商用製品開発Community Driven Commercial Development

  • 10

    Project Zeroの経緯

    2006/7 IBM社内のインキュベーションプロジェクトとしてスタート

    2007/6 プロジェクト公開http://www.projectzero.org/2007/8 ソースコード公開2007/9/14 Milestone1リリース2007/10/26 Milestone2リリース2007/12/14 Milestone3リリース(予定)

    http://www.projectzero.org/

  • 11

    CDCD(Community Driven Commercial Development)

    プロダクト開発におけるIBMの新しい試みの一つ従来のスタイルとOSS的スタイルのレバレッジ

    オープンな開発プロセス(ソースコード、情報、・・・)

    プロダクトに対する保証(Fix提供、サポート、・・・)

    We want to build stronger ties to our customers and users, so we're providing a panoramic view of the development process for Project Zero. With regular

    milestones throughout the development of a release, users get the opportunity to see what’s coming, provide feedback, and help set priorities.

    - From “Project Zero FAQ” -

    CDCDは ”California Pizza Kitchen”(*注)だ。お客様は、IBMが自分の欲しいものをCookしてくれるかいつでも見る事ができるし、自分の好みと違えば注文をつけることができる。クローズドな環境

    で作る製品よりも、よりお客様のニーズに見合った商品を提供できる、新しい試みだ。- Message from Jerry Cuomo -

    (*注)USでチェーン展開している人気のピザ屋で、ガラス張りのキッチンの中で、注文してからピザをcookしてくれる

  • 12

    Project Zero Community Site

    ディスカッション

    ニュース

    ドキュメント

    ダウンロード

    デモ/チュートリアルJIRA開発者Blog

    •誰でも利用可能(一部コンテンツはユーザー登録が必要)•プロジェクトの全情報はここでやり取りされている

    http://www.projectzero.org/

    http://www.projectzero.org/

  • 13

    1. Atom基礎

    AtomはWebにおけるデータアクセス手法として重要な位置を占つつあります。ここでは、その基礎と適用例について解説します。

  • 14

    Atomとは?

    ≒Webリソース(コンテンツ)の変更手続きの規定 + (変更)内容通知の書式規定

    (グループ化された)Webリソース

    コンテンツ(の要約)

    AtomPub

    Atom SyndicationFormat

    ニュース配信,blog,..“Web API”

  • 15

    Atomとは?詳細は、RFC (この資料の説明は、概要)

    The Atom Syndication Format, RFC4287 (*1)This document specifies Atom, an XML-based Web content and metadata syndication format.

    The Atom Publishing Protocol, RFC5023(*2) The Atom Publishing Protocol (AtomPub) is an application-level protocol for publishing and editing Web resources.The protocol is based on HTTP transfer of Atom-formatted representations.The Atom format is documented in the Atom Syndication Format.

    日本語訳(株式会社リコー、リコーソフトウェア株式会社)http://www.ricoh.co.jp/src/rd/webtech/rfc5023_ja.html

    先行する既存類似技術と並存しながら、適用範囲を広めつつあるRSSXML-RPC, WebDAV

  • 16

    Atom Syndication Formatの例

    Example Feed

    2003-12-13T18:30:02Z

    John Doe

    urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6

    Atom-Powered Robots Run Amok

    urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a2003-12-13T18:30:02ZSome text.

    (*1)

  • 17

    Atom Syndication Formatの構成Atom Feed Document, Atom Entry Documentの2つを規定(*1)

    参考文献3, P31の図が参考になる

    atomFeed =element atom:feed {

    atomCommonAttributes,(atomAuthor*& atomCategory*& atomContributor*& atomGenerator?& atomIcon?& atomId& atomLink*& atomLogo?& atomRights?& atomSubtitle?& atomTitle& atomUpdated& extensionElement*),atomEntry* }

    atomEntry =element atom:entry {

    atomCommonAttributes,(atomAuthor*& atomCategory*& atomContent?& atomContributor*& atomId& atomLink*& atomPublished?& atomRights?& atomSource?& atomSummary?& atomTitle& atomUpdated& extensionElement*) }

  • 18

    Atom Syndication Formatに関連するIANA登録

    Internet Assigned Numbers AuthorityDedicated to preserving the central coordinating functions of the global Internet for the public good.

    http://www.iana.org/

    Media typeapplication/atom+xml

    http://www.iana.org/assignments/media-types/application/

    HTTP ヘッダー,“Content-Type”等

    Link relationalternate, related, self, enclosure, via

    http://www.iana.org/assignments/link-relations.html

    (*1)

  • 19

    Atom Syndication Format, 拡張例Atom Threading Extensions

    This memo presents a mechanism that allows feeds publishers to express threaded discussions within the Atom Syndication Format.

    http://www.ietf.org/rfc/rfc4685.txt

    My original entry...

    A response to the original...

    ...

    ...

  • 20

    Atom Publishing Protocol (AtomPub)文書の作成方法/編集方法/グループ化手法の規定(提案)

    1. 目録, 図書分類, 目次(書籍)の導入。それに伴う本文の位置づけを規定。Service Documents :目録

    application/atomsvc+xmlCategory Documents :図書分類

    application/atomcat+xmlCollections :目次

    application/atom+xml (Feed)Member (resources) :本文(*注)

    application/atom+xml, その他

    2. 各文書の取り扱い手順を規定目録を見て本を特定、さらに目次から記事を探す..目次に追記して記事を作成(図書分類を考慮)....

    より詳しくは、http://atomenabled.org/developers/protocol/など

    *注:Member resourcesはさらに分類され、もう一階層追加されるケース(図表の別扱いに相当)がある

  • 21

    ..

    … …

  • 22

    AtomPubの構成(2)

    HTTP Method

    GET PUT POST DELETE

    ServiceDocument Collectionリストの取得 未定義 未定義 未定義

    Collection Member resourceリストの取得 未定義 Member Resourceの生成 未定義

    MemberResource Member(のrepresentation)の取得 編集 未定義 削除

    URIs(IRIs)for

  • 23

    AtomPubに関連するIANA登録Media type

    application/atomcat+xmlapplication/atomsvc+xmlhttp://www.iana.org/assignments/media-types/application/

    Link relationedit, edit-mediahttp://www.iana.org/assignments/link-relations.html

    Header FieldSLUG

    http (RFC2616)に対してhttp://www.iana.org/assignments/message-headers/perm-headers.html

    (*1)

  • 24

    AtomPub, “Beyond blogging”(*3)“The Atom Publishing Protocol as Universal Web Glue”

    Tim Bray, OSCON 2006http://conferences.oreillynet.com/cs/os2006/view/e_sess/9568

    “You can do a lot with collections + CRUD”参考資料3, P74

    現在までの例:Lucene Web services APIGoogle Data APIs

  • 25

    Lucene Web Services API

  • 26

    Google Data APIs (GData)GData is a new protocol based on the Atom 1.0 and RSS 2.0 syndication formats, plus the Atom Publishing Protocol.

    http://code.google.com/apis/gdata/overview.html

    Many Google services support the Google data API protocol. The following data APIs allow your client applications to interact with Google services:

    Google Apps Provisioning API Google Base data API Blogger data API Google Calendar data API Google Code Search data API Google Notebook data API Google Spreadsheets data API Picasa Web Albums data API Google Documents List data API YouTube data API

    http://code.google.com/apis/gdata/

  • 27

    OpenSocial Data APIsOpenSocial API DocumentationThe OpenSocial API is a set of common APIs for building social applications on many websites. There are two ways to access the OpenSocial API: .. and server-side using RESTful data APIs.…The People and Friends data API allows client applications …using AtomPub GData APIs with a Google data schema. …The Activities data API …The Persistence data API …

    http://code.google.com/apis/opensocial/docs/

  • 28

    AtomPubの実装2007年4月の相互運用性試験に参加した実装(サーバー、略称)

    Abdera (Snell), Amplee (Peterson), Blogger (Clinton), AOL (Panzer), LC Blogs (Snell), LC Dogear (Snell), Gregorio, Oracle (Mehta), Six Apart (Reese), O'Reilly (Greer), WordPress (Torres), Roller (Johnson), Propono (Johnson), PHP+DB2 (Beyer),Photo APP (Asakura), O'Reilly Deli

    http://www.intertwingly.net/wiki/pie/April2007Interophttp://www.intertwingly.net/wiki/pie/InteropGrid

    その後のInterop(東京含む)、予定などhttp://www.intertwingly.net/wiki/pie/InteropTesting

  • 29

    参考文献

    1. The Atom Syndication Format, RFC4287, 2005年12月, http://www.ietf.org/rfc/rfc4287.txt

    2. The Atom Publishing Protocol, RFC5023, 2007年10月, http://www.ietf.org/rfc/rfc5023.txt

    3. “Beyond blogging : Understand feeds and publishing protocols”, Dave Johnson, Sun Microsystems, Inc., 2006http://rollerweblogger.org/downloads/presentations/TriXML2006-BeyondBlogging.pdf

  • 30

    2. ZeroのAtomサポート

    Project Zeroが提供するAtom/RSSサポート機能についてご紹介します

  • 31

    ZeroのAtomサポート:概要zero.atom拡張モジュールでサポート

    内部はApache Abderaを利用

    AtomパーサーAtom文書(XML)をパースしてオブジェクト化

    AtomレンダラーZeroのレンダラーを追加し、Atom文書(XML)をレスポンスとして生成可能にrequest.view=“atom”request.json.output=objectsrender()

    DB->Atomの自動マッピング(Atom Enabled DB)http://www.projectzero.org/wiki/bin/view/Documentation/CoreDevelopersGuideAtom

    http://www.projectzero.org/wiki/bin/view/Documentation/CoreDevelopersGuideAtom

  • 32

    Atomレンダラー for entry

    入力形式org.apache.abdera.model.EntryMap

    Map Key データ型 Atom要素 内容

    id int

    String

    String

    Date

    contenttype String content/@type “TEXT” or “HTML” or “XML”

    String

    idlink/@href

    title title タイトル

    authorname author/name 著者名

    updated updated 更新日(ISO8601形式)

    URI(http://host:port/{reqUri}/{id})

    content content コンテンツ(text)

    Mapからのシリアライズ時の規約

  • 33

    Atomレンダラー for feed

    入力形式org.apache.abdera.model.FeedMap[]List

    Atom要素 内容

    id http://host:port/{reqUri}

    title http://host:port/{reqUri}

    entry Map毎にEntryへマップ

    link/@href http://host:port/{reqUri}

    updated Entryの中で最新の更新日

    Map[]/List からのシリアライズ時の規約

  • 34

    DB->Atom自動マッピング

    DBのカラム名からAtomへの対応付け

    ID int

    TITLE varchar

    AUTHORNAME varchar

    UPDATED date

    CONTENTTYPE varchar

    SUMMARY varchar

    CATEGORYTERM varchar

    CATEGORYLABEL varchar

    FOREIGN1 varchar

    FOREIGN2 varchar

    atomTable

    rs = dataManager.queryArray('SELECT * FROM atomTableORDER BY UPDATED DESC')

    request.view='atom'request.atom.output = rsrender()

    http://www.projectzero.org/wiki/bin/view/Documentation/CoreDevelopersGuideAtomEnabledDatabase

    http://www.projectzero.org/wiki/bin/view/Documentation/CoreDevelopersGuideAtomEnabledDatabase

  • 35

    デモ:books.demo

  • 36

    3. Zeroのマッシュアップ機能

    Project Zeroが提供するマッシュアップ支援機能について、Flowを中心にご紹介します

  • 37

    マッシュアップ機能の概要

    Flowコンポーネント組立によるアプリケーション構築

    XML/GroovyDSLによる定義Flow Editor / Flow Adminツール

    Integration Fabric宛先(Destination)による外部リソースの抽象化

    Connection:外部リソースへの接続各種プロトコル対応(HTTP/SMTP/File/Event)

    Mediation:非機能要件の分離retry、failover、routingロギング、プロトコル変換

  • 38

    Flow

    Flowの構成要素アクティビティ

    何らかの処理、もしくは制御

    リンク

    アクティビティの実行順序

  • 39

    Flowツール

    ブラウザ上で使える高機能GUIツールFlow Editor

    Flow定義をWYSWYGで作成Feed操作に特化したGUIの提供(Feedパースペクティブ)

    Flow AdminFlowインスタンスのステータス参照内部変数の値を参照

    利用方法zero.assemble.tooling モジュールを追加http://localhost:8080/tooling/index.gt

    http://localhost:8080/tooling/index.gt

  • 40

    Flowツール:初期画面

    Flow Editor起動(汎用パースペクティブ)

    Flow Editor起動(Feedパースペクティブ)

    Flow Admin起動

  • 41

    Flow Editor:汎用パースペクティブソース(XML)表示切替

    コンポーネントパレット

    編集ペイン

    アクティビティのプロパティ

    ツールバー

  • 42

    Flow Editor:FeedパースペクティブFlow実行

    Feed取得

    Feed加工

    Feed検索(Google)

    各アクティビティーでの途中経過を表示

  • 43

    Feedパースペクティブ:デモ

    Flow EditorでFeedを加工してみるソーシャルブックマークの人気エントリを集約

    はてなブックマーク

    livedoorクリップdel.icio.us

    重複エントリを削除

    ソート・件数制限

    リクエストパラメータでキーワード指定、絞込み

  • 44

    Flow Admin

    Flowインスタンスのステータス

    FlowインスタンスのインスタンスID

    Flow変数の値を参照

  • 45

    Flow定義

    Flow定義の方法は二通りXML(Flow Language)

    手書き or Flow EditorGroovy(Flow DSL)

    手書きのみ

    Recap: 第2回「構造型と手順型」XMLは構造を表すのに適している

    ツール化しやすいが、複雑な制御は苦手

    プログラムは手順を表すのに適している

    制御構造はリッチだが、ツール化は困難

    単純なFlowはGUIで手っ取り早く複雑なFlowはGroovyで効率良く

  • 46

    Flow Language

    process1つのFlow

    activity1つの処理要素名=アクティビティ名

    controlActivity間の依存関係

    inputActivityへの入力

    *

    *

    *

    *

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideFlowLangSynBe

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideFlowLangSynBe

  • 47

    Groovy DSL: FlowBuilderdef flow() {

    def builder = new FlowBuilder(writer);builder.process( name:"feedGroovyExample") {

    receiveGET( name:"rssRcv")feed( name:"YahooFeed", url:"http://rss.news.yahoo.com/rss/topstories") {

    control( source:"rssRcv") }feed( name:"CNNFeed", url:"http://rss.cnn.com/rss/cnn_topstories.rss") {

    control( source:"rssRcv")}aggregateFeeds( name:"aggregate" ) {

    input( value: '${YahooFeed}') input( value: '${CNNFeed}')

    }sortFeed( name:"sort", orderBy:"-title") {

    input( value: '${aggregate}') }replyGET( name:"rssRply") {

    input( value: '${sort}' ) }

    }}

    GroovyのBuilder機能を利用して、Flow専用の

    DSLを提供

  • 48

    Flow:組込アクティビティ

    外部サービスへのHTTPリクエスト発行GET, POST, PUT, DELETE

    クライアントからのHTTPリクエスト受付ReceivePOST, ReplyPOST, Receive-replyPOSTReceiveGET, ReplyGET, Recieve-replyGET

    制御while, for-eachpick, assignempty

  • 49

    Flow:拡張アクティビティ

    メール送信sendMail

    Feed操作feed, sortFeed, aggregateFeeds, filterFeed,unique, truncate

    XML操作XPath, XSLT

  • 50

    Flowのアーキテクチャ

    Even

    t Engin

    e

    _receiveGET on_receiveGET() {・・・・・}

    Global Context

    on_exchangeRate() {・・・・・}

    on_replyGET() {・・・・・}

    _exchangeRate

    _replyGET

    Event HandlerFlow

  • 51

    Flow:カスタムアクティビティの作成1. アクティビティ名を決める

    exchangeRate

    2. イベントハンドラーを作成する/app/scripts/sample/RateHandler.groovy

    3. ハンドラーメソッドを実装するon_excahgeRate() {・・・}

    4. イベントハンドラーを登録するzero.configに[/config/handlers]を追加

    5. Flow Editor用のメタデータを登録する(option)zero.configに[/config/activity/metadata/exchangeRate]を追加

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideExtensionActivityGetStarted

    Zero再起動が必要

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideExtensionActivityGetStarted

  • 52

    Flow:zero.config設定例

    [/config/handlers]events=_exchangeRatehandler=sample/SampleHandler.groovyconditions=[true]

    “_”+アクティビティ名イベントハンドラー登録

    [/config/activity/metadata/exchangeRate]attributes=[

    {name="from"},{name="to"}

    ]inputOccurence=0

    アクティビティの属性

    Flow Editor用メタデータ登録

  • 53

    Flow:イベントハンドラーの例package sample

    def on_exchangeRate() {// get attributesdef _fromCurrency = event.attributes['from']def _toCurrency = event.attributes['to']def resultUri = event.resultUridef target ="http://webservicex.com/CurrencyConvertor.asmx/ConversionRate?fromCurrency=${_fromCurrency}&ToCurrency=${_toCurrency}"

    zero.assemble.core.Connection.Response resp = zero.assemble.core.Connection.doGET(target)

    Reader body = resp.getResponseBodyReader();def data = new XmlParser().parse(body);

    // put result_gc.put(resultUri, data.value[0].toDouble())

    }

    Connection APIで外部サービスを呼出し

  • 54

    Connection API

    外部リソースへのアクセスをシンプルにzero.core.connection.Connectionzero.core.connection.Conneciton.ResponseConnection.Response response = Connection.doGET("http://www.projectzero.org/repo");

    マルチプロトコル対応HTTP / SMTP / FileEventカスタムプロトコル

    接続先リソースの抽象化Integration Fabricで定義されたdestination名も指定可能

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideConnectionAPI

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideConnectionAPI

  • 55

    Flowの配置と実行Flowの配置先とURIの対応

    /public///foo.flow⇒http://localhost:8080///foo.flowFlow名を省略した場合、index.flowが実行される

    Flowの実行receiveGETを含むFlow: FlowのURIにGET

    query parameterを付加できる例)http://localhost:8080/myApp/test.flow?

    order=yes&[email protected]を含むFlow: FlowのURIにPOST

  • 56

    Flow応用編:デモ

    Sales reportの集約国別にAtom形式で配布されているSales reportを集約XSLT変換:Excel形式メール送付

    為替レート取得は外部WebAPIを利用

  • 57

    Integration FabricDestinationによりリソース指定を抽象化非機能要件をアプリケーションから分離

    ルーティング、ロギング、プロトコル変換

    拡張可能、組合せ可能

    Request

    Response

    Step

    Request

    Response

    Step

    Failover Retry

    Yes

    No

    Yes

    No

    Extern

    alReso

    urse

    Req

    Res

    Zero

    Applicatio

    n

    Req

    Res

    Destination: “SomeResource”

    Connectio

    nAPI

    doGet(“SomeResource”)http://www.some.com/

  • 58

    Integration Fabricの設定

    http://www.projectzero.org/repo

    /config/integration_fabric.xml

    Connection.Response resp =Connection.doGET("ProjectZero");

    String body = resp.getResponseBodyAsString();print body

    destinationの呼び出し(例)

  • 59

    Mediationハンドラー

    リトライハンドラーのクラス名を指定

    フェイルオーバーハンドラーのクラス名を指定

    メディエーションステップ()

    ステップの実装クラス名を指定

    ステップの設定

    複数指定した場合、リクエストは設定順、レスポンスは設定の逆順に処理される

    ?

    ?

    *

  • 60

    組込メディエーションステップ

    Static router静的なルーティング

    Java loggerJava loggin APIによるログGlobal Contextの値を出力

    XPath loggerXPathがマッチした場合、指定されたURLにメッセージのコピーをPOST

    REST2SOAPSOAPサービスを呼出し

  • 61

    REST2SOAPによる変換

    Webブラウザ

    Project ZeroRuntime

    サービス(SOAP)control

    state

    AjaxToolkit

    JavaScript RESTful

    サービス

    RESTto SOAP

    mediation

    SOAP

    integration_fabric.xml

    SOAP Bodytemplate

    (.gt)

    ResourceHandler

    (.groovy)

    GET /resources/books/

    POST /bookService/(+SOAP Body)

    zero.assemble.core.mediation.soap.R2SStep

    http://localhost:8080/bookService/

    1.1

    GET

    getBook.gt

    /Book/{isbn}

  • 62

    Flow ExamplesサンプルFlowの導入手順(Eclipse)

    File -> New -> Example...Project Zero Example Projectszero.assemble.flow Samplesを選択

    以下が含まれる

    基本機能のサンプル

    Echo, Add, Proxy Add, MathAggregate/Sort/Filter/Truncate/Unique feedsfor-each, while, XPath, Errors

    応用サンプル

    Reports demoOrder demoFlow-augmented employee.demo

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideFlowSamples

    http://www.projectzero.org/wiki/bin/view/Documentation/AssembleDevelopersGuideFlowSamples

  • 63

    4. M2新機能と将来計画

    Milestone2で導入された新機能や変更点、およびM3以降に予定されている拡張についてご紹介します

  • 64

    M2新機能ZRM(Zero Resource Model)の導入

    Model Class(Groovy)を仲介として、RESTful resourceを自動的に永続化

    汎用のO/Rマッパーではない

    Global Context変更コンフィグレーションが/app -> /configに階層構造からフラット構造へ:パフォーマンス改善

    依存プロダクトの変更

    Groovy1.0 -> 1.1β2Dojo 0.4 -> 0.9

    Database Setup Tool提供

  • 65

    M3以降の拡張予定

    XMLのストリーミング(StAX)に対応M2でプレビュー提供大きなXMLの扱いを効率化

    ZRMの強化OpenID対応

  • 66

    おわりに

    wakhokナイトセミナー2007:Project Zero(4回シリーズ)は今回で終了です

    多数の皆様にご参加頂き、有難うございました

    最後に、丸山先生より総括をお願い致します

  • 67

    Enjoy “Project Zero”!!!

    Project ZeroでServer Side Mashup本日のゴールアジェンダはじめに第1回:Project Zero,背景と概要第2回:GroovyとProject Zero第3回:2時間でRESTfullなアプリを作って�動かす - Project Zeroを体験しよう!-Project Zeroとは?Project Zeroの経緯CDCD(Community Driven Commercial Development)Project Zero Community Site1. Atom基礎Atomとは?Atomとは?Atom Syndication Formatの例Atom Syndication Formatの構成Atom Syndication Formatに関連するIANA登録Atom Syndication Format, 拡張例�Atom Threading ExtensionsAtom Publishing Protocol (AtomPub)AtomPubの構成(1)AtomPubの構成(2)AtomPubに関連するIANA登録AtomPub, “Beyond blogging”(*3)Lucene Web Services APIGoogle Data APIs (GData)OpenSocial Data APIsAtomPubの実装参考文献2. ZeroのAtomサポートZeroのAtomサポート:概要Atomレンダラー for entryAtomレンダラー for feedDB->Atom自動マッピングデモ:books.demo3. Zeroのマッシュアップ機能マッシュアップ機能の概要FlowFlowツールFlowツール:初期画面Flow Editor:汎用パースペクティブFlow Editor:FeedパースペクティブFeedパースペクティブ:デモFlow AdminFlow定義Flow LanguageGroovy DSL: FlowBuilderFlow:組込アクティビティFlow:拡張アクティビティFlowのアーキテクチャFlow:カスタムアクティビティの作成Flow:zero.config設定例Flow:イベントハンドラーの例Connection APIFlowの配置と実行Flow応用編:デモIntegration FabricIntegration Fabricの設定Mediation組込メディエーションステップREST2SOAPによる変換Flow Examples4. M2新機能と将来計画M2新機能M3以降の拡張予定おわりにEnjoy “Project Zero”!!!