Skip to content

Conversation

@JunielKatarn
Copy link
Contributor

@JunielKatarn JunielKatarn commented Aug 29, 2023

Backport of #11867

Microsoft Reviewers: Open in CodeFlow

JunielKatarn and others added 13 commits August 28, 2023 18:33
* Bump default _WIN32_WINNT_VERSION

* Change files
* Remove unused Beast production code

* Change files

* clang format

---------

Co-authored-by: Andrew Coates <30809111+acoates-ms@users.noreply.github.com>
* Declare FileReaderTurboModule

* Declare m_blobPersistor

* Use msrn namespace alias in FileReader module

* json lock

* Update lock files

* config

* Implement ReadAsDataUrl

* Define ReadAsText

* Define FileReaderResource

* Move persistor from module into resource

* Rename module name name

* Add using ModuleSpec

* clang format

* Change files
* Add WSTurboModule.h

* Implement CreateResource and MSRN SendEvent

* Define IWebSocketModuleContentHandler::ProcessMessage with JSValueObject

* Complete WebSocketTurboModule::CreateResource

* Complete WebSocketTurboModule::Connect

* Implement close, send, sendBinary and ping

* Include NativeWebSocketModuleSpec

* Make Close spec-compliant

* Add spec-compliant method stubs

* Make remaining existing methods spec-compliant

* Move NOOP Add/RemoveListeners implementation into source file

* clang format

* Use double as keys for m_resourceMap

* Change files
* Declare TurboModule

* Generate NativeNetworkingWindows spec

* Define HttpTurboModule

* Begin resource setup

* Initialize: Up to SetOnData

* Define wchar_t event names

* Migrate IRequestBodyHandler to JSValue

IMPORTANT: Migrate and fix RequestArgs::Data

* Migrate IResponseHandler to JSValue

* Rename m_onDataDynamic as m_onDataObject

* Implement Microsoft::React::Modules::ToJSValue

* Migrate IHttpResource to JSValue

* Fix Playground flavors ordering

* Finish implementing Initialize

* Define ToDynamic

* Change files

* Revert module.g.cpp

* Revert "Revert module.g.cpp"

This reverts commit 2f6c88a.

* Define target SetCppWinRTReferences

* clang format

* Revert temporary symbol exports

* Fix RedirectHttpFilterUnitTest import order

* Preserve include ordering in RedirectHttpFilterUnitTest.cpp

* Fix JSValueArray list constructor

* Drop RCTNetworkingNative in favor of NativeNetworkingWindows

* Add NativeNetworkingWindows to overrides

* Fix overrides.json newline

* Desktop int. tests: set RN_PLATFORM to win32

* Use iterator to lookup content types

* Revert module.g.cpp to main

* Use iterator for ToRequestBody content type

* Drop namespace from JSValueObject usage

* Finish HttpTurboModule

* clang format

* Use iOS HTTP spec

* Use DynamicReader and DynamicWriter for folly conversions

* Revert overrides.json

* Don't add newline to overrides.json

* Make RCTNetworking.windows.js a copy of RCTNetworking.ios.js

* Override upgrade
* Default IncludeFabricInterface to true

* Change files

* Remove IncludeFabricInterface from ExperimentalFeatures
* REVERT: remove CompositionView exports

* Declare BlobTurboModule

* Revert "REVERT: remove CompositionView exports"

This reverts commit 1ba874e.

* Define BlobTurboModule

* Declare IBlobResource

* Define DefaultBlobResource

* Define BlobCallbacks

* Migrate BlobWebSocketModuleContentHandler

* Pass needed args to DefaultBlobResource

* Define IBlobResource +/- network handlers

* Implement BlobModule using IBlobResource

* Fix GetConstants ownership

* Change files

* Set up error callback!

* clang format

* Remove BlobModule::SharedState

* Clean up includes and usings

* Remove ProcessMessage folly variant

* Remove folly:dynamic references

* Define IBlobResource::FieldNames

* Move IBlobPersistor out of Modules/

* Remove TODO comments

* clang format

* Add missing include to DefaultBlobResource
* Update packages.json

* Define GetHttpTurboModuleName

* Update packages.json

* Define GetHttpModuleProvider

* Define other netwk modules provider methods

* Register networking turbomodules

* Change files

* clang format

* Uncomment MSRN forward declarations

* Remove cntPtr.h include

* Remove CoreNativeModules

* Revert packages.lock.json
…1902)

* Use ReadAs* data argument as JSValueObject

* Change files
…11926)

* Update packages.lock

* Remove HttpModule.h from OInstance.cpp

* Remove runtime option Blob.EnableModule

* Call SetupHttpResource only once

* Attempt AddNetworkingHandler if HTTP module was not ready

* Change files
* Define FetchTest

* Implement fetch test

* Allow disabling Blob Cxx module

* Change files

* Format FetchTest.js

* yarn lint
@JunielKatarn JunielKatarn requested review from a team as code owners August 29, 2023 02:13
@JunielKatarn JunielKatarn changed the title Use TurboModules for networking in MSRN [0.69] Use TurboModules for networking in MSRN Aug 29, 2023
@JunielKatarn
Copy link
Contributor Author

Requesting parties have moved to RNW 0.71 or later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[0.71] Requests failing due to BlobModule checking for HttpModule.Proxy before WinRTHttpResource has added it

1 participant