Presentation used by Lucas Jellema and Marco Gralike during the AMIS Oracle Database 12c Launch event on Monday the 15th of July 2013 (much thanks to Tom Kyte, Oracle, for being allowed to use some of his material)
M.
Streamlining Python Development: A Guide to a Modern Project Setup
An AMIS Overview of Oracle database 12c (12.1)
1. Marco Gralike & Lucas Jellema
15th July 2013
An overview of
Oracle Database 12c (12.1)
2. Outline
• History, customer demand, market trends
• The Fourth Dimension: Time
• Availability: Application continuity and more
• Data masking (data redaction)
• Security
• Big Data: R and SQL Pattern Matching
• Multi Tenancy
• For cloud environments
• For efficient administration
• Automatic data optimization (& ILM)
• Administration Tooling: Database Express
• Migration to 12c
• Goodies
3. Database release history
2009 2012 2013 2014
12c R1
2010 2011
11g R2
11gR1: August 2007
10gR2: September 2005
10gR1: January 2004
September
2009
June
2013
4. Version 6
July 1988
• New Architecture
• Performance (first SMP)
• Availability
• Parallel Server
• TPO
• PL/SQL
• V6 Lays Architectural Groundwork for the Future
– This was a rewrite of the entire database
5. Oracle Database
Innovation
Audit Vault
Database Vault
Grid Computing
Self Managing Database
XML Database
Oracle Data Guard
Real Application Clusters
Flashback Query
Virtual Private Database
Built in Java VM
Partitioning Support
Built in Messaging
Object Relational Support
Multimedia Support
Data Warehousing Optimizations
Parallel Operations
Distributed SQL & Transaction Support
Cluster and MPP Support
Multi-version Read Consistency
Client/Server Support
Platform Portability
Commercial SQL Implementation
1977 2007
30 years of
sustained
innovation …
… continuing with
Oracle Database 12c
6. The first major architecture change since 1988
Multitenant architecture
8. Managing dozens of databases
means…
– Installing
– Configuring
– Securing
– Monitoring
– Patching
– Upgrading
– Backing up
• many database instances on potentially a large number of machines
• Using dedicated resources for each individual database instance
– 20 processes
– Memory for SGA
– Disk space for generic objects such as most of the SYS schema
13. Flashback
• Introduced in 9i
• Based on UNDO
• Initially only for recovery
• As of 11g – Total Recall option with
Flashback Data Archive
– Controlled history keeping
• Look back into history
– Query trends (version history)
– Difference reporting
– Audit trails (Replace journaling tables)
• Require trick for transaction history: WHO?
• Also: when is the start of history?
• By the way: Flashback Data Archive requires EE & Advanced
Compression database option
14. The Fourth Dimension: Time
In Oracle Database 12c R1:
• User-created Flashback Data Archive contents
• Import and Export of History
• Tracking of transaction (session) context
• Flashback Data Archive available in every edition of the database
15. The Fourth Dimension: Time
Part 2
• Support for SQL 2011 Temporal Validity
• Record state associated with business start and end date (time)
– Instead of Transaction date (time)
• Tables can be associated with Periods – based on a pair of columns
• Flashback queries against these tables can query for valid records at a
certain point in time
• Not just looking back in time but also looking ahead!
SELECT *
FROM EMP AS OF PERIOD FOR user_time
TO_TIMESTAMP('01-DEC-2013 09.00.00 AM')
16. Availability
• Ever more DDL operations can be performed without taking a lock
– Metadata-only Defaults for NULL columns
– Invisible Indexes
– Online move of a partition
– Cascade Truncate
– DROP INDEX ONLINE, DROP CONSTRAINT ONLINE, SET UNUSED COLUMN
ONLINE, ALTER INDEX UNUSABLE ONLINE, ALTER INDEX [VISIBLE | INVISIBLE]
• Reduced limitations with Edition Based Redefinition
– No reason not to use EBR for PL/SQL and Views in order to achieve zero-down time
application upgrade
• Parallel Upgrade
• Transaction Guard
• Application Continuity
18. Application Continuity
• Outages cause in-flight work to be lost, and leave users not knowing what
happened
• Often leads to
– users seeing errors
– data re-entry
– duplicate submissions
– rebooting mid-tiers
Before:
19. Transaction Guard
• Known outcome for every transaction
• At-most-once transaction execution
• Used by Application Continuity
• Available for JDBC-thin, OCI, OCCI, ODP.net
• Without Transaction Guard,
retries can cause
logical corruption
20. Application Continuity
• Improves end user experience
• Improves developer productivity
• Application transparent when using
Oracle stack
• Enabled with
WebLogic Server,
Peoplesoft, Fusion Apps,
Siebel(possibly)
21. Data Masking
• Gartner reports that: data masking should be mandatory for enterprises
using copies of sensitive production data for application
development, analytics or training.
• They also believe the market is
expanding into production and
unstructured data protection.
22. Data Redaction
• At runtime, you can optionally have the query results modified to
reset/scramble/randomize sensitive data
– Through „data redaction‟ policies associated with tables and view and applied at
query time
• Because the data is masked in real-time, Data Redaction is well suited to
environments in which data is constantly changing.
• You can create the Data Redaction policies in one central location and
easily manage them from there.
SQL
engine SQL
POLICY
POLICY
RESULTS
23. Security
• PL/SQL security refinement
– Whitelist to specify which program units may invoke a prcoedure
– Roles attached to invoker rights program units
– Prevent automatic inheritance of invoker‟s privileges in invoker rights unit
• View with invoker rights
• Digest Authentication for DBMS_EPG
• Real Application Security - a database authorization model that
enables end-to-end security for multitier applications
– privilege delegation, role-based constraints, time-based access control, code-
based security, multi-level authorization, negative grants, authorization on user
interface artifacts, access constraints on relational data, and application users
auditing
• Run-Time Privilege Analysis (Privilege Capture)
• Unified Context-Based Database Audit Architecture
24. Big Data
• Spatial and Semantic Query are merged into Spatial and
Graph
• Oracle Text is enhanced in many ways
• Enterprise R is further extended
• SQL Pattern Matching has been introduced
– Inspired by CQL
– Look for patterns in subsequent rows in the result set using regular
expressions
(go beyond Analytic Functions)
25. Other Database Development
enhancements
• SQL evolution
– APPLY, Top-N and Pagination
• SQL PL/SQL integration
– WITH, UDF, Call Stack API
• Improved Defaults
• SQL Text Expansion
• Improved JDBC integration
47. 47
Database as a Service
RAC, Data
Guard, Daily
Incrementals
Data Guard
Daily Incrementals
✔
GOLD
SILVER
BRONZE Weekly Full
Backups
✔
48. 48
Notes
• Database National Characterset
• Database Option License (25 juni 2013)
– 17,500$ per CPU
– 350$ per Named User Plus
• No extra cost for: 1 CDB + 1 PDB
• CDB ORA-00600 / ORA-07445
50. 50
Heat Map
• Automatically tracks usage information at the row and segment levels
• ALTER SYSTEM SET HEAT_MAP = ON | OFF;
• Package DBMS_HEAT_MAP
• V$HEAT_MAP_SEGMENT Real-time Segment Access Information
• Views:
ALL/DBA/USER _HEAT_MAP_SEGMENT
ALL/DBA/USER _HEAT_MAP_SEQ_HISTOGRAM
DBA_HEATMAP_TOP_OBJECTS
Top 1000 objects
DBA_HEATMAP_TOP_TABLESPACES
Top 100 Tablespaces
51. 51
Automatic Data Optimization
• Automate compression or movement of data
• Via CREATE and ALTER TABLE SQL statements
• Heat Map must be enabled
• Policy based levels:
– Row
– Segment
– Tablespace
• Default Compression Mappings:
– COMPRESS ADVANCED on a heap table maps to standard compression for indexes
and LOW for LOB segments.
– COMPRESS FOR QUERY LOW/QUERY HIGH on a heap table maps to standard
compression for indexes and MEDIUM for LOB segments.
– COMPRESS FOR ARCHIVE LOW/ARCHIVE HIGH on a heap table maps to
standard compression for indexes and HIGH for LOB segments.
54. 54
XML DB
• XQuery Update
– Replaces all “old” update methods
• XQuery Full Text
– Full Text Index
– XML (Schema) Aware
• Compatibility across the Board
– Dataguard
– GoldenGate
– DataPump
– DBFS
• Parallel XMLType
60. Goodies you always wanted…?
• EXPORT BY VIEW
• ALTER DATABASE MOVE datafile ONLINE!
• Multiple indexes on the SAME column
– can be used when…
• B-Tree versus Bitmap
• Different partitioning strategies
• Unique versus nonunique
• Privilege Capture…
12c:All table definition, partitioning, and space management DDLs are supported on FDA-enabled tables. Retain session context with transaction Data Pump supports flashback history import ‘user defined history’ as flashback history restore pointsTemporal modeling/ valid time definition specifying the validity period for records unique keys that allow multiple entries with non-overlapping validity periods, foreign keys that include period, flashback based on valid time (not transaction time); joins, aggregation, … valid time aware
Logical Transaction IdentifierApplications use a concept called the logical transaction ID (LTXID) to determine the outcome of the last transaction open in a database session following an outage. The LTXID is held in the OCI session handle and in a connection object for the thin JDBC-Thin and ODP.Net drivers. The logical transaction IDis used to obtain the commit outcome and for the at-most once semantics. Reliable Commit OutcomeFrom the client perspective, the transaction is committed when an Oraclemessage (termed Commit Outcome), generated after the transactionredo is written, is received by the client. However, the COMMIT message is not durable. Transaction Guard obtains the Commit Outcome reliably when it has been lost following a recoverable error.Recoverable Error (enhanced)A recoverable error is an error that arises due to an external system failure, independent of the application session logic that is executing.Recoverable errors occur following planned and unplanned outages of foregrounds, networks, nodes, storage, and databases.The application receives an error code that can leave the application not knowing the status of the last operation submitted. Recoverable errors areenhanced in Oracle Database 12c, to include more errors and to includea public API for OCI. Applications should no longer list error numbers in their code.Transaction Guard is invoked following a recoverable error code