aboutsummaryrefslogtreecommitdiff
path: root/zenserver
Commit message (Collapse)AuthorAgeFilesLines
* moved source directories into `/src` (#264)Stefan Boberg2023-05-0267-27610/+0
| | | | | | * moved source directories into `/src` * updated bundle.lua for new `src` path * moved some docs, icon * removed old test trees
* made Ref<> constructor explicit (#262)Stefan Boberg2023-04-272-4/+4
| | | This change makes the Ref<> constructor explicit, which can help avoid unnecessary overheads and other accidents
* fix sentry report callstack (#256)Dan Engelbrecht2023-04-252-52/+37
| | | | | | | * Include file, line and function in sentry log error messages * use sync direct error logger to get correct call stacks on error * changelog * use d1trimfile on windows to shorten file path on windows * constexpr -> consteval
* fixed dashboard file serving bug (#255)Stefan Boberg2023-04-242-2/+2
| | | | | a recent change which introduced support for specifying accept: implicitly via the file extension in the URI caused fallout in the dashboard which would fail to serve any content because the extension was stripped from the RelativeUri accessor. This change fixes that by retaining a copy of the Uri string view which includes the suffix additionally, in order to test this change with both asio/http.sys paths I made the path used for all tests configurable in zenserver-test which involved pulling in a change from sb/proto which makes testing configuration a bit more flexible
* check for port conflict before trying to take data dir lock (#253)Dan Engelbrecht2023-04-241-24/+29
| | | | * check for port conflict before trying to take data dir lock * demote data dir conflict to warning (still exist with error code)
* save cache rawsize and rawhash in manifest file instead of log file (#251)Dan Engelbrecht2023-04-212-235/+92
| | | | * save cache rawsize and rawhash in manifest file instead of log file * don't use # as prefix for counts in log
* Fix sentry init (#250)Dan Engelbrecht2023-04-211-1/+10
| | | | * Sentry does not like UNC paths. Strip them before passing them to sentry * changelog
* oplog and cache stats (#244)Dan Engelbrecht2023-04-217-39/+927
| | | | | | | | | | | | | | | | * basic oplog stats * add GetValueStats to cache store * RwLock::ExclusiveLockScope -> RwLock::SharedLockScope * add rawhash and attachment count to CacheValueStats * added cache-stats and project-stats commands * add cast to make Mac overload detection happy * fix accept type in cache-stats command * Add options to project-stats command * use resource paths for stats in project store * use resource paths for stats in cache * fix cache-info and project-info url discriminator * more control over details$ output * cleanup * changelog
* tweaks for enabling unity buildsStefan Boberg2023-04-193-5/+8
| | | | | | | | | | mostly changes to make sure anonymous namespaces don't clash and a change to avoid windows headers from leaking into other compilation units unity builds are not yet enabled by default, but can be enabled by uncommenting this line in the root `xmake.lua` ``` --add_rules("c++.unity_build") ```
* added missing #pragma onceStefan Boberg2023-04-193-0/+6
| | | | required for unity builds to work properly
* Support for HTTP range header (#245)Per Larsson2023-04-191-8/+45
| | | | | | | | | | | * Support for HTTP range header. * Implement http range for HTTP sys. * Validate range parameters. --------- Co-authored-by: Stefan Boberg <[email protected]>
* #minor - don't log "sentry initialized" if sentry is explicitly disabled.Dan Engelbrecht2023-04-031-6/+9
|
* Use ReadPayloadObject to read POST payloadStefan Boberg2023-03-301-3/+1
|
* send payloads as duplicated handles (#240)Dan Engelbrecht2023-03-142-18/+33
| | | | | | | | | * send payloads as duplicated handles if requestor provides process id and allows local file references. * linux/macos fixes * tests * fix access rights when duplicating handle * fix closing of duplicated handles on error * cleanup * changelog
* store cache rawhash and rawsize for unstructured cache values (#234)Dan Engelbrecht2023-02-233-170/+436
| | | | | | | | | * refactored MemoryCacheBucket to allow for storing RawHash/RawSize. * remove redundant conversions in AccessTime * reduce max count for memory cache bucket to 32-bit value * refactored DiskCacheBucket to allow for storing RawHash/RawSize. * Use CompressedBuffer::ValidateCompressedHeader when applicable * Make sure we rewrite the snapshot if we read an legacy existing index/log * changelog
* Clang format wanted to change one cell from a tab to a spaceMartin Ridgers2023-02-221-1/+1
|
* Removed unused functionMartin Ridgers2023-02-221-129/+0
|
* There is no need to calculate the start of a zip archive.Martin Ridgers2023-02-221-6/+2
| | | | | | | As zip files' directory structures are at the end of an archive, and Zen's dashboard archive is always at the end of the binary, there is no need to workout where the start of the archive is. A future improvement could be to only buffer the tail of the file.
* The start of a Zip archive can be calculated using its own dataMartin Ridgers2023-02-221-1/+1
|
* Magic value for Zip LocalFileHeader struct was incorrectMartin Ridgers2023-02-221-1/+1
|
* UE 177395 - fix crash when using asio http server and requesting info on ↵Dan Engelbrecht2023-02-211-0/+28
| | | | | non-existing chunk (#235) * Dont' write httpreq responses with content type text for empty strings
* Refactor CacheBuckets to allow for storing RawHash/RawSize (#232)v0.2.4-pre0v0.2.4Dan Engelbrecht2023-02-202-98/+258
| | | | | | * refactored MemoryCacheBucket to allow for storing RawHash/RawSize. * remove redundant conversions in AccessTime * reduce max count for memory cache bucket to 32-bit value * refactored DiskCacheBucket to allow for storing RawHash/RawSize.
* Enhanced rpc request recording (#229)Dan Engelbrecht2023-02-173-262/+62
| | | | | | | | | | | | | * rpc replay zen command * fix replay sessions for thread * recording start/stop as zen commands * move rpcrecording code to zenutil to remove code duplication * simplify recording http request threading * added more data logging to rpc replay * NotFound is an acceptable response for an rpc request * fix rpc replay command line parsing * rpc replay stats * Allow spawning of sub-process workers when replaying rpc recording * changelog
* Experimental ObjectStore/CDN like endpointPer Larsson2023-02-165-1/+321
|
* Move knowledge of UE env variable from zenserver to zen command line tool (#227)Dan Engelbrecht2023-02-131-14/+3
| | | | * move knowledge of UE env variable from zenserver to zen command line tool * move env-fetching code to GetEnvVariable
* no sentry report on port conflict (#228)Dan Engelbrecht2023-02-131-4/+8
| | | | * Exit with failure code on port conflict rather than reporting crash to Sentry * changelog
* oplog upload/download (#214)Dan Engelbrecht2023-02-0914-63/+2798
| | | | | | | | | | | | - Feature: Zen server endpoint `prj/{project}/oplog/{log}/chunks` to post multiple attachments in one request. - Feature: Zen server endpoint `prj/{project}/oplog/{log}/save` to save an oplog container. Accepts `CbObject` containing a compressed oplog and attachment references organized in blocks. - Feature: Zen server endpoint `prj/{project}/oplog/{log}/load` to request an oplog container. Responds with an `CbObject` containing a compressed oplog and attachment references organized in blocks. - Feature: Zen server endpoint `{project}/oplog/{log}/rpc` to initiate an import to or export from an external location and other operations. Use either JSon or CbPackage as payload. - CbObject/JSon RPC format for `import` and `export` methods: - CbObject RPC format for `getchunks` method, returns CbPackage with the found chunks, if all chunks are found the number of attachments matches number of chunks requested. - Feature: Zen server `{project}/oplog/{log}/{hash}` now accepts `HttpVerb::kPost` as well as `HttpVerb::kGet`. - Feature: Zen command line tool `oplog-export` to export an oplog to an external target using the zenserver oplog export endpoint. - Feature: Zen command line tool `oplog-import` to import an oplog from an external source using the zenserver oplog import endpoint.
* Add support for "packagedata" mapping in oplog entries (#224)Dan Engelbrecht2023-02-071-3/+13
|
* Merge pull request #219 from EpicGames/linux-buildMartin Ridgers2023-02-061-0/+11
|\ | | | | Scripts for building Linux binaries using UE's Linux toolchain.
| * Commented out breakpad_client xmake.lua adjustment - not applicable yetMartin Ridgers2023-02-031-0/+3
| | | | | | | | | | | | Later baselines of vcpkg will change to a newer version of sentry-native that will produce libbreakpad_client. This block of xmake script will then be required to coerce xmake to order libraries correctly
| * Fixed symbol resolution error because xmake reverses dependent librariesMartin Ridgers2023-02-021-0/+8
| |
* | remove legacy `export-project` and `import-project` (#222)Dan Engelbrecht2023-02-021-203/+0
| |
* | Reduce lock scopes in oplog (#220)Dan Engelbrecht2023-02-022-90/+123
|/
* Clean up project store file structure (#218)Dan Engelbrecht2023-02-013-1/+1
| | | | * move project store to separate folder * moved import/export project commands into projectstore cmd files
* Merge branch 'main' of https://github.com/EpicGames/zenStefan Boberg2023-01-262-113/+167
|\
| * Retain memory buffer when replaying oplog (#216)Dan Engelbrecht2023-01-261-3/+7
| | | | | | | | * Retain memory buffer when replaying oplog * changelog
| * Better error responses/logging in project store request (#217)Dan Engelbrecht2023-01-262-110/+160
| | | | | | | | * Better error responses/logging in project store request * changelog
* | mergeStefan Boberg2023-01-269-1073/+25
|\|
| * removed HttpLaunchService and related codeStefan Boberg2023-01-243-643/+0
| | | | | | | | this was used for testing but is no longer wanted in this form
| * removed dead/experimental file system related codeStefan Boberg2023-01-246-430/+0
| |
| * Added version information to server executable (#215)Stefan Boberg2023-01-242-0/+25
| | | | | | | | | | This change adds some version and product information to the Windows executable, in order to make it easier for users to understand the purpose of the zenserver.exe process when they see it in Task Manager and on disk It also adds back the executable icon which was lost when we transitioned from the previous sln build process
* | removed experimental mesh codeStefan Boberg2023-01-265-382/+0
|/ | | | should be replaced with a proper implementation later
* fix gc logging (#213)Dan Engelbrecht2023-01-131-7/+7
| | | | | | * Don't output time to next GC if time is "infinite". * Do immediate check of GC status on thread startup instead of waiting montior intervall first. * set up reasonable gc defaults * changelog
* zen command line tool improvements (#212)Dan Engelbrecht2023-01-131-0/+1
| | | | | | | | | | | | - Feature: zen command line tool `cache-info` to show cache, namespace or bucket info - Feature: zen command line tool `project-info` to show store, project or oplog info - Feature: zen command line tool `project-drop` to drop project or oplog - Feature: zen command line tool `gc` to trigger a GC run - Feature: zen command line tool `gc-info` to check status of GC - Improvement: zen command line tool now fails on any unrecognized arguments - Improvement: zen command line tool now displays extra help for all sub-commands - Improvement: host address can now be configured for zen command line tool `drop` command changelog
* Add info (GET) endpoints for structured cache (#211)Dan Engelbrecht2023-01-116-60/+415
| | | | | | | * Add GET requests on cache/namespace/bucket level * Add root route for project store requests (same as /list) * Add markerpath to oplog info object * Add totalsize, opcount and expired to oplog info * Changelog
* Fix log index snapshot (#210)Dan Engelbrecht2022-12-163-12/+19
| | | | | | * Fix log reading for structured cache store Make sure cache is flushed at exit * dont flush index to disk unless new entries have been written * changelog
* oplog level GC (#209)Dan Engelbrecht2022-12-142-43/+209
| | | | | | | | Adds check for marker file supplied by UE to see if an oplog is expired (user has deleted the corresponding cooked folder). Fixed concurrency vulnerabilities is project store related to oplogs. * fix concurrency vulnerabilities * propagate lifetime file path * oplog level gc * changelog
* Changed so CompressedBuffer::DecodeRawHash returns IoHash just like on the ↵Stefan Boberg2022-12-123-6/+5
| | | | | | UE side (#208) removed all use of IoHash::FromBLAKE3() caused by interactions with CompressedBuffer APIs
* Path from handle perf improvement (#206)Dan Engelbrecht2022-12-081-8/+12
| | | | | | * Read recorded requests to memory before parsing This will more accurately simulate how requests comes in from a client * Make a fast path for GetFinalPathNameByHandleW Try to get the path with a fixes size buffer first to avoid always doing two calls to GetFinalPathNameByHandleW
* Fix logging of number of read entries from log/index file for stores (#204)Dan Engelbrecht2022-12-081-5/+4
| | | | * Fix logging of number of read entries from log/index file for stores * changelog