Closed Bug 1526327 Opened 7 months ago Closed 7 months ago

Add API to prevent redirects in GeckoWebExecutor

Categories

(GeckoView :: General, enhancement, P1)

Unspecified
All
enhancement

Tracking

(firefox67 fixed)

RESOLVED FIXED
mozilla67
Tracking Status
firefox67 --- fixed

People

(Reporter: csadilek, Assigned: snorp)

References

Details

Attachments

(1 file)

There's currently no way to specify whether or not redirects should be followed when making WebRequests with GeckoWebExecutor.

Assignee: nobody → snorp

Using this flag will cause GeckoWebExecutor.fetch() to not automatically
follow redirects, which is the default behavior if no flag is specified.

Pushed by jwillcox@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/11f1c1b18d28
Add GeckoWebExecutor.FETCH_FLAGS_NO_REDIRECT r=geckoview-reviewers,droeh,esawin

Backed out 3 changesets (Bug 1526327, Bug 1522705) for WebExecutorSupport.cpp caused Android build bustages

Push with failures: https://treeherder.mozilla.org/#/jobs?repo=autoland&selectedJob=229747488&searchStr=android&revision=11f1c1b18d2823dfcbc92b4272d7a9c1058e6ce1

Backout link: https://hg.mozilla.org/integration/autoland/rev/21e5e458085d7f1ef210e2d4873d9af6d7726ba8

Failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=229747488&repo=autoland&lineNumber=21903

[task 2019-02-21T22:51:27.260Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/layout/build'
[task 2019-02-21T22:51:27.264Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/xpfe/appshell'
[task 2019-02-21T22:51:27.264Z] 22:51:27 INFO - mkdir -p '.deps/'
[task 2019-02-21T22:51:27.264Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/xpfe/appshell'
[task 2019-02-21T22:51:27.285Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/xpfe/appshell'
[task 2019-02-21T22:51:27.285Z] 22:51:27 INFO - xpfe/appshell/Unified_cpp_xpfe_appshell0.o
[task 2019-02-21T22:51:27.286Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/xpfe/appshell'
[task 2019-02-21T22:51:27.386Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/docshell/base'
[task 2019-02-21T22:51:27.390Z] 22:51:27 INFO - /builds/worker/workspace/build/src/sccache2/sccache /builds/worker/workspace/build/src/clang/bin/clang++ --target=aarch64-linux-android -o Unified_cpp_docshell_base0.o -c -I/builds/worker/workspace/build/src/obj-firefox/dist/stl_wrappers -I/builds/worker/workspace/build/src/obj-firefox/dist/system_wrappers -include /builds/worker/workspace/build/src/config/gcc_hidden.h -DDEBUG=1 -DOS_POSIX=1 -DOS_LINUX=1 -DMOZ_TOOLKIT_SEARCH -DSTATIC_EXPORTABLE_JS_API -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/builds/worker/workspace/build/src/docshell/base -I/builds/worker/workspace/build/src/obj-firefox/docshell/base -I/builds/worker/workspace/build/src/obj-firefox/ipc/ipdl/ipdlheaders -I/builds/worker/workspace/build/src/ipc/chromium/src -I/builds/worker/workspace/build/src/ipc/glue -I/builds/worker/workspace/build/src/docshell/shistory -I/builds/worker/workspace/build/src/dom/base -I/builds/worker/workspace/build/src/dom/bindings -I/builds/worker/workspace/build/src/layout/base -I/builds/worker/workspace/build/src/layout/generic -I/builds/worker/workspace/build/src/layout/style -I/builds/worker/workspace/build/src/layout/xul -I/builds/worker/workspace/build/src/netwerk/base -I/builds/worker/workspace/build/src/netwerk/protocol/viewsource -I/builds/worker/workspace/build/src/toolkit/components/browser -I/builds/worker/workspace/build/src/toolkit/components/find -I/builds/worker/workspace/build/src/tools/profiler -I/builds/worker/workspace/build/src/obj-firefox/dist/include -I/builds/worker/workspace/build/src/obj-firefox/dist/include/nspr -I/builds/worker/workspace/build/src/obj-firefox/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /builds/worker/workspace/build/src/obj-firefox/mozilla-config.h -Qunused-arguments -isystem /builds/worker/workspace/build/src/android-ndk/sysroot/usr/include/aarch64-linux-android -isystem /builds/worker/workspace/build/src/android-ndk/sysroot/usr/include -gcc-toolchain /builds/worker/workspace/build/src/android-ndk/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64 -D__ANDROID_API_=21 -fstack-protector-strong -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wwrite-strings -Wno-invalid-offsetof -Wclass-varargs -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wc++1z-compat -Wc++2a-compat -Wcomma -Wimplicit-fallthrough -Werror=non-literal-null-conversion -Wstring-conversion -Wtautological-overlap-compare -Wtautological-unsigned-enum-zero-compare -Wtautological-unsigned-zero-compare -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=return-std-move -Wno-error=atomic-alignment -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -Wno-unknown-warning-option -Wno-return-type-c-linkage -fno-sized-deallocation -fno-short-enums -fno-exceptions -I/builds/worker/workspace/build/src/android-ndk/sources/cxx-stl/llvm-libc++/include -I/builds/worker/workspace/build/src/android-ndk/sources/android/support/include -I/builds/worker/workspace/build/src/android-ndk/sources/cxx-stl/llvm-libc++abi/include -fstack-protector-strong -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pipe -g -Xclang -load -Xclang /builds/worker/workspace/build/src/obj-firefox/build/clang-plugin/libclang-plugin.so -Xclang -add-plugin -Xclang moz-check -Oz -mno-outline -fno-omit-frame-pointer -funwind-tables -Werror -Wno-error=shadow -MD -MP -MF .deps/Unified_cpp_docshell_base0.o.pp /builds/worker/workspace/build/src/obj-firefox/docshell/base/Unified_cpp_docshell_base0.cpp
[task 2019-02-21T22:51:27.390Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/docshell/base'
[task 2019-02-21T22:51:27.409Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/extensions/universalchardet/src/base'
[task 2019-02-21T22:51:27.411Z] 22:51:27 INFO - mkdir -p '.deps/'
[task 2019-02-21T22:51:27.412Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/extensions/universalchardet/src/base'
[task 2019-02-21T22:51:27.413Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/extensions/universalchardet/src/base'
[task 2019-02-21T22:51:27.415Z] 22:51:27 INFO - extensions/universalchardet/src/base/Unified_cpp_src_base0.o
[task 2019-02-21T22:51:27.416Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/extensions/universalchardet/src/base'
[task 2019-02-21T22:51:27.479Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/widget/android'
[task 2019-02-21T22:51:27.487Z] 22:51:27 INFO - /builds/worker/workspace/build/src/sccache2/sccache /builds/worker/workspace/build/src/clang/bin/clang++ --target=aarch64-linux-android -o Unified_cpp_widget_android0.o -c -I/builds/worker/workspace/build/src/obj-firefox/dist/stl_wrappers -I/builds/worker/workspace/build/src/obj-firefox/dist/system_wrappers -include /builds/worker/workspace/build/src/config/gcc_hidden.h -DDEBUG=1 -DOS_POSIX=1 -DOS_LINUX=1 -DMOZ_NATIVE_DEVICES -DSTATIC_EXPORTABLE_JS_API -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/builds/worker/workspace/build/src/widget/android -I/builds/worker/workspace/build/src/obj-firefox/widget/android -I/builds/worker/workspace/build/src/obj-firefox/ipc/ipdl/ipdlheaders -I/builds/worker/workspace/build/src/ipc/chromium/src -I/builds/worker/workspace/build/src/ipc/glue -I/builds/worker/workspace/build/src/docshell/base -I/builds/worker/workspace/build/src/dom/base -I/builds/worker/workspace/build/src/dom/system/android -I/builds/worker/workspace/build/src/gfx/2d -I/builds/worker/workspace/build/src/gfx/vr -I/builds/worker/workspace/build/src/layout/painting -I/builds/worker/workspace/build/src/netwerk/base -I/builds/worker/workspace/build/src/netwerk/cache -I/builds/worker/workspace/build/src/widget -I/builds/worker/workspace/build/src/xpcom/threads -I/builds/worker/workspace/build/src/obj-firefox/dist/include -I/builds/worker/workspace/build/src/obj-firefox/dist/include/nspr -I/builds/worker/workspace/build/src/obj-firefox/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /builds/worker/workspace/build/src/obj-firefox/mozilla-config.h -Qunused-arguments -isystem /builds/worker/workspace/build/src/android-ndk/sysroot/usr/include/aarch64-linux-android -isystem /builds/worker/workspace/build/src/android-ndk/sysroot/usr/include -gcc-toolchain /builds/worker/workspace/build/src/android-ndk/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64 -D__ANDROID_API_=21 -fstack-protector-strong -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wwrite-strings -Wno-invalid-offsetof -Wclass-varargs -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wc++1z-compat -Wc++2a-compat -Wcomma -Wimplicit-fallthrough -Werror=non-literal-null-conversion -Wstring-conversion -Wtautological-overlap-compare -Wtautological-unsigned-enum-zero-compare -Wtautological-unsigned-zero-compare -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=return-std-move -Wno-error=atomic-alignment -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -Wno-unknown-warning-option -Wno-return-type-c-linkage -fno-sized-deallocation -fno-short-enums -fno-exceptions -I/builds/worker/workspace/build/src/android-ndk/sources/cxx-stl/llvm-libc++/include -I/builds/worker/workspace/build/src/android-ndk/sources/android/support/include -I/builds/worker/workspace/build/src/android-ndk/sources/cxx-stl/llvm-libc++abi/include -fstack-protector-strong -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pipe -g -Xclang -load -Xclang /builds/worker/workspace/build/src/obj-firefox/build/clang-plugin/libclang-plugin.so -Xclang -add-plugin -Xclang moz-check -Oz -mno-outline -fno-omit-frame-pointer -funwind-tables -Werror -Wno-error=shadow -MD -MP -MF .deps/Unified_cpp_widget_android0.o.pp /builds/worker/workspace/build/src/obj-firefox/widget/android/Unified_cpp_widget_android0.cpp
[task 2019-02-21T22:51:27.489Z] 22:51:27 INFO - In file included from /builds/worker/workspace/build/src/obj-firefox/widget/android/Unified_cpp_widget_android0.cpp:92:
[task 2019-02-21T22:51:27.491Z] 22:51:27 ERROR - /builds/worker/workspace/build/src/widget/android/WebExecutorSupport.cpp:147:3: error: bad implicit conversion constructor for 'StreamSupport'
[task 2019-02-21T22:51:27.492Z] 22:51:27 INFO - StreamSupport(nsIRequest* aRequest) : mRequest(aRequest) {}
[task 2019-02-21T22:51:27.493Z] 22:51:27 INFO - ^
[task 2019-02-21T22:51:27.494Z] 22:51:27 INFO - /builds/worker/workspace/build/src/widget/android/WebExecutorSupport.cpp:147:3: note: consider adding the explicit keyword to the constructor
[task 2019-02-21T22:51:27.495Z] 22:51:27 INFO - StreamSupport(nsIRequest* aRequest) : mRequest(aRequest) {}
[task 2019-02-21T22:51:27.496Z] 22:51:27 INFO - ^
[task 2019-02-21T22:51:27.497Z] 22:51:27 INFO - explicit
[task 2019-02-21T22:51:27.498Z] 22:51:27 INFO - 1 error generated.
[task 2019-02-21T22:51:27.499Z] 22:51:27 INFO - /builds/worker/workspace/build/src/config/rules.mk:805: recipe for target 'Unified_cpp_widget_android0.o' failed
[task 2019-02-21T22:51:27.500Z] 22:51:27 ERROR - make[4]: *** [Unified_cpp_widget_android0.o] Error 1
[task 2019-02-21T22:51:27.501Z] 22:51:27 INFO - make[4]: Leaving directory '/builds/worker/workspace/build/src/obj-firefox/widget/android'
[task 2019-02-21T22:51:27.503Z] 22:51:27 INFO - make[4]: *** Waiting for unfinished jobs....
[task 2019-02-21T22:51:27.508Z] 22:51:27 INFO - make[4]: Entering directory '/builds/worker/workspace/build/src/obj-firefox/extensions/universalchardet/src/xpcom'
[task 2019-02-21T22:51:27.509Z] 22:51:27 INFO - mkdir -p '.deps/'

Flags: needinfo?(snorp)
Pushed by jwillcox@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/3f221b9ba73f
Add GeckoWebExecutor.FETCH_FLAGS_NO_REDIRECT r=geckoview-reviewers,droeh,esawin
Flags: needinfo?(snorp)
Status: NEW → RESOLVED
Closed: 7 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla67
See Also: → 1530069
You need to log in before you can comment on or make changes to this bug.