15. 创建 data store Window: 控制面板- > 管理工具- > 数据源 (ODBC) - > 系统 DSN
16. Data Store RAM Policy C:\Documents and Settings\ChenLi> ttadmin -query tttest RAM Residence Policy : inUse plus grace period RAM Residence Grace (Secs) : 30 Replication Agent Policy : manual Replication Manually Started : False Cache Agent Policy : manual Cache Agent Manually Started : False C:\Documents and Settings\ChenLi> ttAdmin -ramPolicy always tttest RAM Residence Policy : always Replication Agent Policy : manual Replication Manually Started : False Cache Agent Policy : manual Cache Agent Manually Started : False 内存策略: inUse: Load store into memory only if the store has at least one connection (default) always : Always keep the store resident in memory manual :Manually load and unload the store
17. 数据类型 数据类型 TypeMode: Oracle type mode ( recommended and default mode ) Timesten type mode ( provided for backward compatibility ) 存储方式 : 固定长度: inline 可变长度: inline or out-line Inline 与 out-line 区别: Inline: 空间的分配和普通的 int , char 等类型一样,都是放在表所在的连续空间中,当可变长度的长度小于等于 128 字节时缺省是 inline 。定义多少实际消耗多少。性能好。 Out-line : 放在一个另开的空间,比如堆中,当可变长度的长度大于 128 字节时,缺省是 not inline 。 out-line 存放的好处是节省空间。
18. DDL/DML DDL CREATE TABLE CREATE GLOBAL TEMPORARY TABLE AGING LRU/AGING USE DROP TABLE TRUNCATE TABLE ALTER TABLE CREATE INDEX ---T-tree index / hash index System tables Ttsize DML select/insert/update/delete/merge function prepare/exec
28. Application (0) SELECT <..> UPDATE <..> INSERT <..> (1) COMMIT TimesTen (2) Commit to transaction log (3) Return control to application (4) Propagate transaction to Oracle (UPDATE, INSERT, COMMIT) Oracle (5) Commit transaction and return to TimesTen AWT 数据流程 * 具体操作取决于 PassThrough 的设置 2 Application Application 4 5 TimesTen transaction log ASYNCHRONOUS WRITETHROUGH TimesTen 3 1
29. 0 1 2 3 PassThrough 的级别 在 TimesTen 出错的 DML Err O O O 对 READONLY 执行 DML Err Err O O 在 TimesTen 不出错的 DML T T O O DDL T T T O O : 在 Oracle 中执行 T : 在 TimesTen 中执行