Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
Storage Service Adapters
The Storage Service supports multiple implementations of storage
and selects an adapter at runtime based on browser support and specified characteristics of
persistence and security. Storage can be persistent and secure. With persistent storage,
cached data is preserved between user sessions in the browser. With secure storage, cached data is
encrypted.
| Storage Adapter Name | Persistent | Secure |
|---|---|---|
| IndexedDB | true | false |
| Memory | false | true |
- IndexedDB
- (Persistent but not secure) Provides access to an API for client-side storage and search of structured data. For more information, see the Indexed Database API.
- Memory
- (Not persistent but secure) Provides access to JavaScript memory for caching data. The stored cache persists only per browser page. Browsing to a new page resets the cache.
The Storage Service selects a storage adapter on your behalf that matches the persistent and secure options you specify when initializing the service. For example, if you request a persistent and insecure storage service, the Storage Service returns the IndexedDB storage if the browser supports it.