wasser in der wüste · wasser in der wüste vom custom-made sql-db-messaging anti-pattern zum...

Post on 05-Feb-2020

4 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Wasser in der Wüste

Vom custom-madeSQL-DB-Messaging Anti-Pattern

zum JMS-Standard mit Apache Camel

Niko Köbler

DOAG, 20.11.2012

Niko Köbler• Freiberuflicher Berater/Architekt

• IT seit 1999

e: niko@n-k.de

w: www.n-k.de

nikokoebler.blogspot.com

t: @dasniko

Wasser in der Wüste, Niko Köbler 2

Herausforderung

Wasser in der Wüste, Niko Köbler 3

Oracle DB

IBM AS/400

DB/400

PL/SQL

JEE Container

JDBC

File

File

SQL

JDBC

Der Weg I• IBM Websphere MQ ???

• Oracle SOA-Suite ???

• JMS!

• Lose Kopplung

• Asynchrone Übertragung

• Queues (point-to-point)vs.Topics (publish-subscribe)

Wasser in der Wüste, Niko Köbler 4

NO!

Oracle AQ• JMS-Provider „built-in“

• Seit Version 9i Release 2 „Advanced Queuing“

• Auch in XE!

• Robust, stabil, etabliert

• Datenbanktabellen / -user

• Nutzbar über PL/SQL-Packages oder JMS-Adapter

• Kein weiteres System notwendig

Wasser in der Wüste, Niko Köbler 5

Der Weg II• Spring Integration

• Mule ESB / Mule Integration

• Apache Camel

Wasser in der Wüste, Niko Köbler 6

Was ist Apache Camel?„Apache Camel is messaging technology glue with routing. It

joins together messaging start and end points allowing the

transference of messages from different sources to different

destinations.“

„It‘s a complete production-ready framework for people who

want to implement their solotuion to follow the EIPs.“

Quelle: http://stackoverflow.com/questions/8845186/what-exactly-is-apache-camel

Wasser in der Wüste, Niko Köbler 7

Apache Camel• EIP Open Source Framework

• leichtgewichtig

• Implementiert in Java

• Routing / Mediation / Transformation

• DSLs: Java, XML, Scala

• Pipes&Filters, Bean Binding

• Testbar (Unit-Tests)

• Apache Projekte, die Camel verwenden:o ServiceMix

o ActiveMQ

o …

Wasser in der Wüste, Niko Köbler 8

Apache Camel – 10.000m

Wasser in der Wüste, Niko Köbler 9

Camel Beispiel - Java

Wasser in der Wüste, Niko Köbler 10

Camel Beispiel - XML

Wasser in der Wüste, Niko Köbler 11

Apache Camel Components• GAuth, GMail, …

• HBase

• HDFS

• HTTP

• iBatis

• IRC

• JDBC

• JMS

• JMX

• JPA

Wasser in der Wüste, Niko Köbler 12

• Atom

• Amazon WS

• Bean / Bean Validation

• Crypto

• CXF (SOAP)

• Direct, Seda, Mock

• EJB

• File

• Freemarker

• FTP

Apache Camel Components• RSS

• Solr

• SpringBatch, -Integration

• SQL

• SSH

• StAX

• TCP

• Twitter

• XQuery

• XSLT

Wasser in der Wüste, Niko Köbler 13

• JT400

• LDAP

• Log

• Lucene

• Mail (IMAP, POP3, SMTP)

• MongoDB

• Nagios

• Printer

• REST

• RMI

Enterprise Integration Patterns• Gregor Hohpe & Bobby Woolf

• Designing, Building and Deploying Messaging Solutions

• 65 Patternso (einfache) Lösungen und Ansätze für verschiedene bzw. alle Integrations-Werkzeuge

o „Gemeinsame Sprache“ und visuelle Notation

• If you are involved with the operation or development

of an enterprise application, there will doubtless come

a time when you will need to integrate your application

with another using the emerging preferred approach

of messaging. When that time comes, this book will

be your most valuable reference.

(Randy Stafford, Oracle)

Wasser in der Wüste, Niko Köbler 14

Ziel-Architektur

Wasser in der Wüste, Niko Köbler 15

Oracle DB

IBM AS/400

DB/400

PL/SQL

JT400DTAQ

JEE Container

AQ

Apache CamelJMS

JMS

JMS

JDBC

SQL

JPA

Ziel-Routing

Wasser in der Wüste, Niko Köbler 16

Route1 Route2

Route3

Route4

Transformation, Unmarshalling,

SplittingEndpoint-Input

Content-Based-Routing

XML-Marshalling JMS-Queue

Entity-Transformation

Persistenz

Demo

Q&A

Links• Oracle AQ:

http://en.wikipedia.org/wiki/Oracle_Advanced_Queuing

• JMS: http://de.wikipedia.org/wiki/Java_Message_Service

• Apache Camel: http://camel.apache.org

• Spring Integration:http://www.springsource.org/spring-integration

• Mule ESB: http://www.mulesoft.org

• EAI Patterns: http://www.eaipatterns.com

• JT400: http://jt400.sourceforge.net

Wasser in der Wüste, Niko Köbler 19

top related