github.com/geniusesgroup/libgo@v0.0.0-20220713101832-828057a9d3d4/ChaparKhane/manifest.go (about) 1 /* For license and copyright information please see LEGAL file in repository */ 2 3 package chaparkhane 4 5 // Manifest use to store server manifest data 6 // All string slice is multi language and in order by ManifestLanguages order 7 type Manifest struct { 8 AppID [16]byte // Application ID 9 PlatformID uint32 // XP part of GPs! 10 RouterID uint32 // Router part of GPs! 11 Email string 12 Icon string 13 AuthorizedUsers [][16]byte // Just accept request from these users! 14 SupportedLanguages []uint32 15 ManifestLanguages []uint32 16 Name []string 17 Description []string 18 TermsOfService []string 19 Licence []string 20 TAGS []string // Use to categorized apps e.g. Music, GPS, ... 21 RequestedPermission []uint32 // ServiceIDs from PersiaOS services e.g. InternetInBackground, Notification, ... 22 TechnicalInfo TechnicalInfo 23 } 24 25 // TechnicalInfo store some technical information but may different from really server condition! 26 type TechnicalInfo struct { 27 OS []string // PersiaOS, Linux, Windows, ... 28 ApplicationProtocols []string // sRPC, HTTP, ... 29 UseAI bool // false: Open the lot of security concerns || true: use more resource. 30 AuthorizationServer string // Domain name that have sRPC needed store connection data. default is "apis.sabz.city" 31 // Shutdown settings 32 ShutdownDelay uint16 // the server will wait for at least this amount of time for active streams to finish! 33 // Server Overal rate limit 34 MaxOpenConnection uint64 // The maximum number of concurrent connections the app may serve. 35 // Guest rete limit - Connection.OwnerType==0 36 GuestMaxConnection uint64 // 0 means App not accept guest connection. 37 GuestMaxStreamConnectionDaily uint32 // Max open stream per day for a guest connection. overflow will drop on creation! 38 GuestMaxServiceCallDaily uint64 // 0 means no limit and good for PayAsGo strategy! 39 GuestMaxBytesSendDaily uint64 40 GuestMaxBytesReceiveDaily uint64 41 GuestMaxPacketsSendDaily uint64 42 GuestMaxPacketsReceiveDaily uint64 43 // Registered rate limit - Connection.OwnerType==1 44 RegisteredMaxConnection uint64 45 RegisteredMaxStreamConnectionDaily uint32 // Max open stream per day for a Registered user connection. overflow will drop on creation! 46 RegisteredMaxServiceCallDaily uint64 // 0 means no limit and good for PayAsGo strategy! 47 RegisteredMaxBytesSendDaily uint64 48 RegisteredMaxBytesReceiveDaily uint64 49 RegisteredMaxPacketsSendDaily uint64 50 RegisteredMaxPacketsReceiveDaily uint64 51 // If you want to know Connection.OwnerType>1 rate limit strategy, You must read server codes!! 52 // 53 // Minimum hardware specification for each instance of application. 54 CPU uint64 // Hz 55 RAM uint64 // Byte 56 GPU uint64 // Hz 57 NetworkBandwidth uint64 // Byte 58 HDD uint64 // Byte, Hard disk drive as storage engine. Act as object+block storage. 59 SSD uint64 // Byte, Solid state drive as storage engine. Act as object+block storage.. 60 // 4 type of devices trend now: 61 // Out of XP scope - Cloud Computing - Cheapest scenario - Primary Datastore ::/1 () 62 // Adjacent Router or Inside same XP - Fog Computing - Caching Datastore ::/32 63 // Inside Router scope - Edge Computing - Caching Datastore ::/64 64 // End user device - ::/128 65 MaxNetworkScalability uint8 // If ::/32 it mean also ::/1 but not ::/64!! 66 }