Application
- 
                  
                  DeclarationSwift fileprivate static var ucs: UserCacheStorage?
- 
                  
                  DeclarationSwift private static var ucsLock: NIOLock
- 
                  
                  This is where UserCache stores its in-memory cache. DeclarationSwift static var userCacheStorage: UserCacheStorage { get set }
- 
                  
                  This is the datatype that gets stored in UserCacheStorage. Vapor’s Services API uses this. See moreDeclarationSwift struct UserCacheStorage
- 
                  
                  Storage key used by Vapor’s Services API. Used by UserCache to access its cache data. See moreDeclarationSwift struct UserCacheStorageKey : StorageKey
- 
                  
                  A simple mutex lock provided by Vapor’s Services API.. All code blocks that are protected with this lock’s withLock()method are serialized against each other.DeclarationSwift struct UserCacheLockKey : LockKey
- 
                  
                  After boot but before handling requests, this code runs to fill the cache with data on all known Users. LifecycleHandler is another part of Vapor’s Services API. Load all users into cache at startup.DeclarationSwift func initializeUserCache(_ app: Application) throws
- 
                  
                  DeclarationSwift func getUserHeader(_ username: String) -> UserHeader?
- 
                  
                  This is where we store active WebSockets. DeclarationSwift var websocketStorage: WebSocketStorage { get set }
- 
                  
                  This is the datatype that gets stored in UserCacheStorage. Vapor’s Services API uses this. Making this a class instead of a struct. This prevents internal modifications (e.g. adding/removing a value from the dicts) from causing the entire app.storage getting copied, in the case where app.storage is a value type composed of other value types. The custom setter for app.storage is not thread-safe. So, this is a workaround for app.storage having a non-thread-safe setter. See moreDeclarationSwift class WebSocketStorage
- 
                  
                  Storage key used by Vapor’s Services API. Used by UserCache to access its cache data. See moreDeclarationSwift struct WebSocketStorageKey : StorageKey
- 
                  
                  A simple mutex lock provided by Vapor’s Services API.. All code blocks that are protected with this lock’s withLock()method are serialized against each other.DeclarationSwift struct WebSocketStorageLockKey : LockKey
 View on GitHub
            View on GitHub
           Application Extension Reference
      Application Extension Reference