Upload
teresa-freeman
View
218
Download
0
Embed Size (px)
Citation preview
Why Upgrade to OmniMark V7 from
V5: Enterprise
Content Processing Copyright © 2003, Stilo Corporation
2
Copyright © Stilo Corporation 2003
URLs
http://developers.omnimark.com/etcetera/v7-upgrade-01.ppt
http://www.stilo.com/products/ omnimark/whyupgrade.html
3
Copyright © Stilo Corporation 2003
Goals for V7
• Overall Theme: Make it easier to use OmniMark For Content
Engineering, specifically Enterprise Content Processing
– For developers
• Improve the Language, through
– Software Engineering & Content Transformation improvements
• Add more connectivity
– For business
• More Product Packages & more flexible attitude to customers needs
• Partner programs
• Providing services to help customers utilize the power of OmniMark
4
Copyright © Stilo Corporation 2003
Overview
• Developer– Language Improvements
– Example Program
– Studio Developments
– Connectivity
• Business• Future developments
5
Copyright © Stilo Corporation 2003
Areas of Development• Richer XML support
– XML namespace support, External markup parser, XSLT library
• Increased connectivity and Enterprise integration– MQSeries library, ActiveX and Java Versions of VM
• Enterprise-enabled Web Services Capability– Web Services Broker
• Language Enhancements– over 20 of them
• Library Enhancements– filter functions, improved interfaces
• Improved IDE Studio Capability– more functionality, more robust, better interfaces
• For complete details, see:– http://www.stilo.com/products/omnimark/whyupgrade.html
6
Copyright © Stilo Corporation 2003
OmniMark V7 Language
• External Markup Parser: W3C Schema Support• XML Namespace support• Modules• Streaming and pattern matching improvements• and many more
• 7.1– User defined data types– Function pointers– Minor language improvements
• conditional expressions– output "number" || (x > 1 -> "s" | "") || "%n"
– Eclipse based Studio– Available: Q3, 2003
7
Copyright © Stilo Corporation 2003
External Markup Parser
• Lets OmniMark use other parsers• Instead of “do xml-parse” use “do markup-parser”, add the
include statement for the library that connects to the parser and everything else, except possibly markup error handling, in your program is the same
• Different parsers have different error messages, so Stilo’s error messages and numbers are different from these external parsers. If your program looks for specific markup errors then you will need to make some changes
• Initially Xerces parser from Apache Project is only one available– Xerces supports W3C Schema
8
Copyright © Stilo Corporation 2003
Support for XML Namespaces
• xmlns-change rule, fires when xmlns namespace of the element is different than its parent
• #xmlns-names shelf, list of active namespaces• The prefix name of Namespace is variable:
• <db:table xmlns:db=“URI1”>• <ata:table xmlns:ata=“URI1”>
– The element table is the same, because the XML Namespace is the same, URI1, even though the prefix is different. Programmers need assistance to deal with this variability
– Stilo refers to table as the base part of the element
• #full, #base, #xmlns operators modify interpretation of element names in rules and in tests
9
Copyright © Stilo Corporation 2003
#xmlns Operator
• For a fragment of
<a:list xmlns:a=“URI1>
<b:list xmlns:b=“UR12”>• If processing of the second list is different if the it is nested
inside another list of its type how do you detect that?• #xmlns restricts checks to the same namespace, so the test
is– do when ancestor is #xmlns list
– This correctly evaluates to true if the element list is ancestor in the same XML Namespace
10
Copyright © Stilo Corporation 2003
SGML/XML Parsing in V7
• “do sgml-parse”– this uses the builtin SGML Parser, with the Web SGML
Amendment
• “do xml-parse (document | creating | with xml-dtd) … scan”– this uses the builtin non-conformant DTD based XML parser,
this based on our SGML Parser. It must have a DTD.
• “do xml-parse scan”– this uses the builtin well-formed XML parser
• “do markup-parse”– this uses an external parser and the arguments to this action
specify which parser. Currently it is the Xerces which parses well-formed, DTD and Schema based XML documents
11
Copyright © Stilo Corporation 2003
Modules• Provides protected execution namespace within OmniMark
Programs– promotes code reuse and makes it easier to write large programs
• Modules have their own rules, functions, groups -- including #implied, macros, global variables, catch declarations and constants
• Modules can import and export functions, global variables, catch declarations and constants
• Modules can either do their own self-contained do xml-parse or they can share it with other modules or the program– the self-contained ability provides support for processing xml
configuration files
• Modules can have their own process-start/end rules but no process rule
Example: Updating A Database
Demonstrating the power of modules and the handling of XML Namespaces with the well-formed XML parser and
the Xerces Parser
13
Copyright © Stilo Corporation 2003
Main Program
import "update-db.xmd" unprefixed
process do unless number of #args = 2 log-message "Please supply the DSN and input file on the command line.%n" halt with 1 done
update-db dsn #args [1] from-file #args [2]
; rest of the program including element and find rules
14
Copyright © Stilo Corporation 2003
Input XML File<?xml version="1.1"?>
<db:table xmlns:db=”developers.omnimark.com/schema/sample/db">
<db:record>
<db:field name="CustomerID">890XYZ</db:field>
<db:field name="FirstName">John "Jack"</db:field>
<db:field name="LastName">Smith</db:field>
<db:field name="Title">Mr.</db:field>
<db:field name="Address">123 Main Street</db:field>
<db:field name="City">Anytown</db:field>
<db:field name="State">Elation</db:field>
<db:field name="Country">Vespugia</db:field>
<db:field name="Code">K12 16P</db:field>
<db:field name="Phone">555-6789</db:field>
<db:field name="Fax">555-8765</db:field>
<db:field name="Pager">555-1234</db:field>
</db:record>
</db:table>
15
Copyright © Stilo Corporation 2003
Module: update-db.xmd Part 1moduleimport "omdb.xmd" prefixed by db.
global db.database db
define input function insert-query as output "INSERT INTO Customer (" || "CustomerID, " || "FirstName, " || "LastName, " || "Title, " || "Address, " || "City, " || "State, " || "Country, " || "Code, " || "Phone, " || "Fax, " || "Pager) VALUES (%c)"
16
Copyright © Stilo Corporation 2003
Module: update-db.xmd Part 2xmlns-change do when xmlns-name = ”developers.omnimark.com/schema/sample/db” & open element is #base "table" suppress else log-message ("Error unknown schema URI.%nExpecting: %"" || "omnimark.com/schema/sample/db" || "%",%nreceived: %"" || xmlns-name || "%".%n") halt with 1 done
element #base "table" suppress
element #base "record" local db.statement statement initial { db.compile-statement in db sql insert-query } db.execute statement
element #base "field" output "," when occurrence > 1 output "%'" submit "%c" output "%'"
find "%'" output "%'%'"
17
Copyright © Stilo Corporation 2003
Module: update-db.xmd Part 3a
• This part 3 uses the builtin well-formed XML parser to parse the input file
export function update-db dsn value stream dsn from-file value stream file-nameas set db to db.open-odbc dsn do xml-parse scan file file-name suppress done
18
Copyright © Stilo Corporation 2003
Module: update-db.xmd Part 3b
• This part 3 uses the Xerces parser. This is done by including the parser module and using the “do markup-parse xml” action. Note that nothing else in the module’s code needs to be changed.
import "omxerces.xmd" unprefixed
export function update-db dsn value stream dsn from-file value stream file-name as set db to db.open-odbc dsn do markup-parse xml scan file file-name suppress done
OmniMark Studio For Eclipse
20
Copyright © Stilo Corporation 2003
OmniMark Studio For Eclipse
• Eclipse - Java open source IDE frameworks tool– see www.eclipse.org
• Unicode support• Multi-platform• Eclipse toolkit• Available: V7.1 Q3, 2003• More development to be done, once Eclipse port is finished
– Break points in datascopes
– Call stack
– Available: Q4 2003
• Alpha program, why not sign up and try it out
21
Copyright © Stilo Corporation 2003
Editing In Eclipse
22
Copyright © Stilo Corporation 2003
Debugging in Eclipse
23
Copyright © Stilo Corporation 2003
DataScope Display in Eclipse
Connectivity
25
Copyright © Stilo Corporation 2003
Connectivity
• Stabilizing the Libraries– Libraries convert to Modules– External API
• improved handling of OMX’s by 13%
• XSLT• Filter Functions• MQSeries• Web Services Broker
– SOAP, XML-RPC, User defined web services protocols - REST
• Enhancing vfs - FTP, HTTP, HTTPS– Available: V7.1 Q3, 2003
26
Copyright © Stilo Corporation 2003
Filter Functions
• Since V4 OmniMark has had filter functions, UTF-8 translations, but only for reading or writing to files
• Filtering is independent of the attachment, with Filter Functions, filtering is integrated into the streaming programming model
• now UTF-8 character translation can be directly applied to data read from TCP/IP connection or data written to a database
• open my-stream as shift-jis-writer file “my-file.txt”– all characters written to stream “my-stream” are converted to
Shift-JIS encoding• Filter Functions can be cascaded,
– submit decrypt decompress tcp.reader of my-connection– all text read from the TCP connection is first decompressed
and then decrypted and then processed by find rules
Web Services Broker
28
Copyright © Stilo Corporation 2003
Web Services Broker
• A library that has the ability to do load management of OmniMark Web Services Programs running in threads
• Can route Simple Object Access Protocol (SOAP) messages, XML-RPC messages and Representational State (REST) messages
• Does all of this under the control of an OmniMark program• Can work with a webserver or behind it or on its own
29
Copyright © Stilo Corporation 2003
Main Program
Web ServicesBroker
Service Map
Configuration
rtf2xml
rtf2xml
rtf2xml
rtf2xml
rtf2xml
Unknown Request
NewConfiguration
wp2xml
Web Services Broker Architecture
Business Improvements
31
Copyright © Stilo Corporation 2003
Packaging - Product Packages
• Single User– called: Desktop Engine
• serial usage only
– Active X– Java
• Multi-user– called: Server Engine
• concurrent usage supported
– Active X– Java
32
Copyright © Stilo Corporation 2003
Packaging - Product Lines
• Standard– Only for existing file based customers
– No external libraries, no external parser
• Professional– Main offering
• One Studio for both product lines
33
Copyright © Stilo Corporation 2003
Professional
• External Markup Parser• External Libraries
– omdb: both ODBC & OCI native interfaces– Math libs
• BCD & float
– Communication• TCP/IP, mail, FTP, HTTP
– File system– Utility
• Components, separately priced– Web Services Broker– Specialized connectivity
Possible Future Developments
35
Copyright © Stilo Corporation 2003
Language• More support for XML family standards
• Language productivity improvements
• Performance Improvements
• OmniMark launching OmniMark programs
• More External Markup Parsers
– ASN.1 Parser
– Native XML database parser
– Parsers for Proprietary Encodings
• Make External Markup Parser API available– want to perfect it before releasing it
36
Copyright © Stilo Corporation 2003
Connectivity
• Web Services Client• Filter Functions
– Encryption– Compression
• CMS Connectivity– Content@– Documentum
• More native omdb connectivity
– DB2– MySQL– Postgress– Sybase
• Specialized Connectivity– Websphere– BEA WebLogic– JMS– Workflow systems
37
Copyright © Stilo Corporation 2003
Packaging
• .Net– component, like ActiveX
– generate CLI code instead of byte codes
• Java Bean + XVC = ombeanlet• Web server plug in
– mod_perl why not mod_OmniMark
Q & A
The End