Enterprise Mashup Markup Language
{{multiple issues|
{{advert|date=August 2012}}
{{notability|date=August 2012}}
{{primary sources|date=August 2012}}
}}
Enterprise Mashup Markup Language (EMML) is an XML markup language for creating enterprise mashups, which are software applications that consume and mash data from variety of sources. These applications often perform logical or mathematical operations as well as present the data.
Mashed data produced by enterprise mashups are presented in graphical user interfaces as mashlets, widgets, or gadgets. EMML can also be{{Cite web |title=Software AG |url=https://documentation.softwareag.com/webmethods/MashZone_NextGen/MashZone_NextGen_Business_Analytics/v10-0/webhelp/index.html#page/presto-onlinehelp/apisSpecs_2.html |access-date=2023-04-08 |website=documentation.softwareag.com}} considered a declarative mashup domain-specific language (DSL). A mashup DSL eliminates the need for complex, time-consuming, and repeatable procedural programming logic to create enterprise mashups. EMML also provides a declarative language for creating visual tools for enterprise mashups.
The primary benefits of EMML are mashup design portability and interoperability of mashup solutions. These benefits are expected to accelerate the adoption of enterprise mashups by creating transferable skills for software developers and reducing vendor lock-in.
The introduction of EMML is expected to help accelerate the trend toward the integration of web-based applications and service-oriented architecture (SOA) technologies.{{cite web | title = Where Is The Future of SOA Headed? Where The Web Goes | date = 17 November 2015| url = http://www.ebizq.net/blogs/enterprise/2009/09/where_is_soa_heading_where_the.php}} Bank of America was a high-profile early supporter of EMML.{{cite web | title = Why Bank of America Joined the Open Mashup Alliance | url = http://adtmag.com/articles/2009/09/25/why-bank-of-america-joined-open-mashup-alliance.aspx | access-date = 2009-09-28 | archive-date = 2009-10-01 | archive-url = https://web.archive.org/web/20091001103517/http://adtmag.com/Articles/2009/09/25/Why-Bank-Of-America-Joined-Open-Mashup-Alliance.aspx | url-status = dead }} Other prominent early supporters included Hewlett-Packard, Capgemini, Adobe Systems, and Intel.{{cite web | title = Enterprise mashup proponents start organizing | url = http://blogs.zdnet.com/service-oriented/?p=2972 | access-date = 2009-09-28 | archive-date = 2009-10-03 | archive-url = https://web.archive.org/web/20091003233624/http://blogs.zdnet.com/service-oriented/?p=2972 | url-status = dead }}
EMML history
Raj Krishnamurthy (chief architect at JackBe Corporation) and Deepak Alur (VP engineering at JackBe Corporation) started working on EMML in 2006. Their objective was to enable user-oriented and user-enabled mashups by creating what was then a new type of middleware called an Enterprise Mashup Platform. Raj Krishnamurthy became the chief language designer and implementer of EMML and also led the team to create an Eclipse-based EMML IDE called Mashup Studio.{{cite web | title = JackBe announces free enterprise mashup software | date = 17 November 2015| url = http://www.ebizq.net/news/10503.html}} This work evolved into the EMML reference implementation that was donated to the Open Mashup Alliance. Raj Krishnamurthy continues to be one of the key contributors to EMML through the Open Mashup Alliance.
EMML features
EMML language provides a rich set of high-level mashup-domain vocabulary to consume and mash a variety of web data-sources in flexible ways. EMML provides a uniform syntax to invoke heterogeneous service styles: REST, WSDL, RSS/ATOM, RDBMS, and POJO. The EMML language also provides the ability to mix diverse data formats: XML, JSON, JDBC, JavaObjects, and primitive types.
High-level EMML language features include:
- Filter and sort data coming from heterogeneous services.
- Join data across heterogeneous services and data formats.
- Group and aggregate data using assorted functions.
- Annotate original service data to enrich its semantic meaning.
- Merge multiple data streams into consolidated datasets
- Split datasets to select individual data fields.
- Embedded scripting support for JavaScript, JRuby, Groovy, XQuery
- Web clipping to scrape data from HTML pages.
- Conditional statements -
If
/Then
/Else
,While
,ForEach
- Parallel syntax for concurrent processing
EMML is primarily an XML-based declarative language, but also provides the ability to encode complex logic using embedded scripting engines. XPath is the expression language used in EMML.
= Directinvoke statement=
directinvoke
{{cite web | title = EMML Documentation Directinvoke chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/directinvokeRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-30 | archive-url = https://web.archive.org/web/20090930011750/http://www.openmashup.org/omadocs/v1.0/emml/directinvokeRefCmd.html | url-status = dead }} provides ability to invoke and consume a variety of data services. These data services may be REST, RSS/ATOM, or SOAP services. directinvoke
also supports Web clipping by allowing HTML pages to be specified as service endpoints. HTTP GET
, POST
, PUT
, and DELETE
protocols are supported in directinvoke
. HTTP Header and cookie support is also available thus providing the capability to consume a wide variety of REST/SOAP Web services. It is possible to use directinvoke
with a proxy server.
Code sample of passing attributes as parameters to a service:
method="GET" outputvariable="$result" query="items=all" appID="67GYH30N25" /> method="GET" outputvariable="$news" xmlns:sc="http://www.svcltd.com/" sc:date="20070515" sc:nights="3"/>
= Filter statement =
The filter
{{cite web | title = EMML Documentation Filter chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/filterRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-10-17 | archive-url = https://web.archive.org/web/20091017101111/http://www.openmashup.org/omadocs/v1.0/emml/filterRefCmd.html | url-status = dead }} statement filters the content of a variable using an XPath expression and places the result in a new variable.
Code sample for filtering west-coast customers using region data-item:
= Sort statement =
The sort
{{cite web | title = EMML Documentation Sort chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/sortRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-29 | archive-url = https://web.archive.org/web/20090929082327/http://www.openmashup.org/omadocs/v1.0/emml/sortRefCmd.html | url-status = dead }} statement sorts the content of a document-type variable or variable fragment based on key expressions and places the result in another variable.
Code sample that sorts tickets based on created date and customer:
sortexpr="ticket" sortkeys="xs:date(created) descending, customer ascending" outputvariable="$troubleTickets"/>
= Groupby statement =
groupby
{{cite web | title = EMML Documentation Groupby chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/groupRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-29 | archive-url = https://web.archive.org/web/20090929043134/http://www.openmashup.org/omadocs/v1.0/emml/groupRefCmd.html | url-status = dead }} provides the ability to group and aggregate data sets. Standard XPath aggregation operations can be used and there is an extension mechanism for adding user-defined functions. Nested Grouping of hierarchical data sets are also supported. There is a Having
clause to filter Group attributes.
Code sample that groups books by genre and computes total copies for each genre:
= Merge statement =
merge
{{cite web | title = EMML Documentation Merge chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/mergeRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-29 | archive-url = https://web.archive.org/web/20090929082244/http://www.openmashup.org/omadocs/v1.0/emml/mergeRefCmd.html | url-status = dead }} provides ability to combine various data sources including RSS/ATOM feeds, XML, JSON payload formats. The merge feature is similar to SQL UNION
functionality but merges hierarchical document structures.
Code sample that merges Yahoo! News, Financial News, and Reuters feeds:
outputvariable="$NewsAggregate"/>
= Annotate statement =
annotate
{{cite web | title = EMML Documentation Annotate chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/annotateRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-30 | archive-url = https://web.archive.org/web/20090930011729/http://www.openmashup.org/omadocs/v1.0/emml/annotateRefCmd.html | url-status = dead }} provides ability to enrich the semantic meaning of source service data with microformat-like elements/attributes. These data annotations can be used by mashlets or gadgets to provide richer visual user interfaces.
Code sample for annotating vendor payload with geo-coordinates:
element geo:lat { $georesult//y:Latitude/string() },
element geo:long { $georesult//y:Longitude/string() }
= Join statement =
The join
{{cite web | title = EMML Documentation Join chapter | url = http://www.openmashup.org/omadocs/v1.0/emml/joinRefCmd.html | access-date = 2009-10-11 | archive-date = 2009-09-29 | archive-url = https://web.archive.org/web/20090929043144/http://www.openmashup.org/omadocs/v1.0/emml/joinRefCmd.html | url-status = dead }} statement defines how disparate, hierarchical data formats are joined and is comparable to inner joins for relational databases.
Code sample where output variable contains a
element with a repeating set of
children, which are the repeating items. Each
contains a
child with data from the variable named movies and
and
children with data from the variable named reviews:
joincondition="$movies/movie/@id = $reviews/review/movie/title">
= Scripting in EMML =
EMML is a declarative language, but provides programmatic scripting{{cite web | title = EMML Documentation Scripting chapter}} extensions for performing complex mashup logic. JavaScript, JRuby, Groovy, POJO, XQuery scripting environments are supported. Data flows seamlessly between EMML and scripting environments.
Code sample where JavaScript snippet is used to extract authentication token that is required for subsequent calls "result" variable that gets propagated to JavaScript environment:
var r = new String(result)
var ar = r.split("=");
auth = ar[ar.length-1];
auth = auth.slice(0, -1)
]]>