Commit Graph

88 Commits

Author SHA1 Message Date
paul chipchase
b587f92b64 Add support for downloading a file from source control directly without actually checking it out (ie p4 print) and add additional support so that the command can be called from a background thread.
- Only implemented for perforce source control at the moment.
- The source control operation FDownload file can be used just like any other command via ::Execute BUT it will also work with the new method ::TryToDownloadFileFromBackgroundThread which unlike ::Execute can be called from a background thread.

#rb Sebastien.Lussier
#rnx

* PerforceConnection
- Extend ::RunCommand to take an optional FSharedBuffer reference which can be used to return text/binary data downloaded as part of a perforce command
-- Ideally we would replace all of the out parameters with a single struct but that level of refactor would be better suited to its own submit.
- Removed the bool parameter for FP4ClientUser and replaced it with a set of flags instead
- Added a flag to allow FP4ClientUser to store data, either in binary or text format from a perforce command. Although in general this will be the result of a p4 print command.

* PerforceSourceControlCommand
- No longer assert if the command is not on the game thread if the operation indicates that it is safe to run on a background thread.

* PerforceSourceControlModule
- Register the 'DownloadFile' worker

* PerforceSourceControlOperations
- Add FPerforceDownloadFileWorker

* PerforceSourceControlProvider
- Adding implementation for ::TryToDownloadFileFromBackgroundThread.
-- This method is thread safe compared to the normal ::Execute call due to:
-- 1) This method does not accept any callbacks as the most common use of callbacks with ::Execute is to update the UI.
-- 2) This method does not add the command to any of the internal queues nor rely on Tick to process the command.
-- 3) The worker is invoked directly from the calling thread rather than as a background task.
--4) This method does not allow commands that modify the cached states as this would be very difficult to manage without rewriting how all commands are processed to make sure that they are only run one at a time and the results processed in order. NOTE that async commands can be issued from the game thread and can in theory be run in any order on the p4 server depending on how the background task processing works out with no certainty as to the order the results will be processed in. It is unlikely that we will process results out of order but not impossible, but this is a pre-exisiting issue with the current API, extending it to be fully multithreaded will just make it worse.
-- Note that we do not explicity check if the command supports being called from a background thread, as creating the command will check that anyway.
- Calling ::OutputCommandMessages is now thread safe. When called from the game thread it will issue it's output via FMessageLog as before but when called from a background thread we will use the UE_LOG macros instead. Marshalling all output in the same way is something we will need to solve when/if we make the entire API thread safe.

* PerforceControlSettings
- Improve thread safety when calling ::GetConnectionInfo
- If the password is stored in the UI then this is not thread safe but that feature is hidden at the moment due to being unsecure. I am unsure if we want to move the password to be stored in a member variable that can be accessed from any thread and only updated via the UI or not.

* SourceControlOperations
- Add new FDownloadFile operation.
- This can either download the file(s) to FSharedBuffers which can be accessed by calling ::GetFileData OR directly to a directory on disk if the target directory is supplied as part of the constructor.

* ISourceControlOperation
- Add a new base method CanBeCalledFromBackgroundThreads (false by default) which can be overriden by derived classes and return true to indicate that the operation can be run from a background thread. This is intended for use by FDownloadFile with the perforce source control provider in lieu and making the API fully thread safe.
#preflight 60a2290322cce000014243ae

#ROBOMERGE-SOURCE: CL 16346666 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v804-16311228)

[CL 16346668 by paul chipchase in ue5-release-engine-test branch]
2021-05-17 05:07:23 -04:00
Sebastien Lussier
f4be498ef2 FScopedSourceControl - Fix wrong condition preventing source control initialisation
#jira none
#rb patrick.enfedaque
#lockdown simon.tourangeau

[CL 15940139 by Sebastien Lussier in ue5-main branch]
2021-04-07 10:24:08 -04:00
louise rasmussen
825c64a6f5 Level Editor Menu Re-org, Part 1
#JIRA UETOOL-3039
#rb Lauren.Barnes
#lockdown Simon.Tourangeau
#preflight 606b8e0315d4190001b1698b

#ROBOMERGE-SOURCE: CL 15924633 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v786-15839533)

[CL 15924652 by louise rasmussen in ue5-main branch]
2021-04-05 19:11:24 -04:00
patrick enfedaque
66aa1c1b1d FScopedSourceControl: Only Init/Close Provider if it isn't Enabled yet
#rb jeanfrancois.dube, sebastien.lussier

#ROBOMERGE-SOURCE: CL 15889359 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v786-15839533)

[CL 15890444 by patrick enfedaque in ue5-main branch]
2021-04-01 12:15:20 -04:00
matt kuhlenschmidt
30e485f0f8 Updated async task notifications to the new progress notification api and reskined a few misc notifications
#rb lauren.barnes

#ROBOMERGE-SOURCE: CL 15797475 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v783-15756269)

[CL 15807602 by matt kuhlenschmidt in ue5-main branch]
2021-03-24 16:26:43 -04:00
patrick enfedaque
e8ea35842e SourceControlHelper: Replace UE4 by UE in comment
#jira UE-111669

#rb none

#ROBOMERGE-SOURCE: CL 15776338 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v783-15756269)

[CL 15786021 by patrick enfedaque in ue5-main branch]
2021-03-23 17:59:47 -04:00
Sebastien Lussier
3901276790 WP HLODBuilder - Fix error when there's no files to mark for add
* P4 SCC would give an "invalid syntax" error as the p4 command was ill formed
* Added early exits in USourceControlHelpers operations that take an array of files
#robomerge Release-5.0-EarlyAccess
#rb patrick.enfedaque

[CL 15727461 by Sebastien Lussier in ue5-main branch]
2021-03-17 14:01:05 -04:00
Sebastien Lussier
adbade9535 Source control window speedup - USourceControlHelpers::GetAssetData() should only consider assets on disk
#fyi jeanfrancois.dube
#robomerge Release-5.0-EarlyAccess

[CL 15555247 by Sebastien Lussier in ue5-main branch]
2021-03-01 01:43:21 -04:00
julien lheureux
a460459eed Added possibility to get asset data from history, with a max fetch size (until we have a better solution)
Changed the way we associate shelved files with their local filename to facilitate mapping (perforce operations)
Implemented what was needed on the SCC side to support diff against shelve
Improved way we display object names for deleted & shelved files

#rb sebastien.lussier

[CL 15356101 by julien lheureux in ue5-main branch]
2021-02-08 09:36:20 -04:00
julien lheureux
6b739a3205 Added data validation capabilities in the source control.
Exposed data validation in changelists

#rb sebastien.lussier, jeanfrancois.dube, jamie.dale

[CL 15316170 by julien lheureux in ue5-main branch]
2021-02-04 11:50:49 -04:00
Matt Kuhlenschmidt
63c0fe02ac Few extra missing polish items for source control dialog
[CL 15179336 by Matt Kuhlenschmidt in ue5-main branch]
2021-01-25 13:09:45 -04:00
Matt Kuhlenschmidt
22268eca5f Source control dialog cleanup and reskin
[CL 15178205 by Matt Kuhlenschmidt in ue5-main branch]
2021-01-25 11:45:57 -04:00
Marc Audy
bc88b73a29 Merge Release-Engine-Staging to Main @ CL# 15151250
Represents UE4/Main @ 15133763

[CL 15158774 by Marc Audy in ue5-main branch]
2021-01-21 16:22:06 -04:00
julien lheureux
2bb7495a45 - Added new, delete, edit changelist commands
- Added revert unchanged on changelists & files
- Added changelist parameter to the Execute method of ISourceControlProvider (& updated all derived classes)
- Fixed style problem in the Perforce settings dialog

#rb sebastien.lussier

[CL 15128504 by julien lheureux in ue5-main branch]
2021-01-18 09:42:33 -04:00
Sebastien Lussier
6be153a555 Added initial support for changelists to the source control providers
#rb julien.lheureux

[CL 15039900 by Sebastien Lussier in ue5-main branch]
2021-01-11 14:32:27 -04:00
Marc Audy
bf80889353 UE5/Release-Engine-Staging to UE5/Main
This represents UE4/Main up to CL# 14958402

[CL 15028197 by Marc Audy in ue5-main branch]
2021-01-08 19:56:07 -04:00
Marc Audy
ada7c144fa Merge //UE5/Release-Engine-Staging @14903491 to //UE5/Main
[CL 14906022 by Marc Audy in ue5-main branch]
2020-12-11 14:21:20 -04:00
Marc Audy
4c1bb11c29 Merge UE5/Release-Engine-Staging to UE5/Main @ 14548662
This represents UE4/Main @ 14525125 + cherrypicked fixes
#skipundocheck

[CL 14551026 by Marc Audy in ue5-main branch]
2020-10-22 19:19:16 -04:00
Josh Adams
599aa317c2 - ConfigCacheIni overhaul to allow for multiple platform's "GConfigs" at once.
- FConfigCacheIni::ForPlatform(PlatformName) is the way to get the in-memory (won't write to disk) ini system for a different platform. Can pass it GEngineIni, etc for the filename (  FConfigCacheIni::ForPlatform("IOS")->GetString(....., GEngineIni);  )
- GEngineIni and some others (the "stadnard, runtime ini files") are no longer filenames, but identifiers that will work with other platform Ini systems
- Modified "GETINI" console command to allow for a <Platform>@ prefix, to get another platform's ini value (using new multi-platform config) (GetIni [Platform@]IniFile:Section.SubSection Key)
#rb rolando.caloca
#fyi chris.gagnon,Sebastian.Nordgren

[CL 14473359 by Josh Adams in ue5-main branch]
2020-10-12 13:54:50 -04:00
Marcus Wassmer
3b81cf8201 Merging using //UE5/Main_to_//UE5/Release-Engine-Staging @14384769
autoresolved files
#rb none

[CL 14384911 by Marcus Wassmer in ue5-main branch]
2020-09-24 00:43:27 -04:00
Marc Audy
a7c9001a94 Merging //UE5/Release-Engine-Staging to Main (//UE5/Main) @ 14075166
#rb
#rnx

[CL 14075271 by Marc Audy in ue5-main branch]
2020-08-11 01:36:57 -04:00
ryan durand
471d972e62 Updating copyright for Engine Developer.
#rnx
#rb none


#ROBOMERGE-SOURCE: CL 10869240 via CL 10869516 via CL 10869902
#ROBOMERGE-BOT: (v613-10869866)

[CL 10870584 by ryan durand in Main branch]
2019-12-26 15:32:37 -05:00
Ben Marsh
7598af0532 Update copyright notices to 2019.
#rb none
#lockdown Nick.Penwarden

[CL 4662404 by Ben Marsh in Main branch]
2018-12-14 13:41:00 -05:00
jamie dale
925a5c9aa8 Fixing localization warnings
#jira
#rb none

#ROBOMERGE-SOURCE: CL 4421191 in //UE4/Release-4.21/...
#ROBOMERGE-BOT: RELEASE (Release-4.21 -> Release-Staging-4.21)

[CL 4421299 by jamie dale in Staging-4.21 branch]
2018-10-03 11:50:30 -04:00
Marc Audy
d90da4ab1a Merge to Dev-Main for 4.20 @ 4090813
#rb
#rnx
#lockdown Nick.Penwarden

[CL 4091081 by Marc Audy in Main branch]
2018-05-23 21:04:31 -04:00