File tree Expand file tree Collapse file tree 4 files changed +8
-12
lines changed
packages/react-on-rails-pro
spec/dummy/config/initializers Expand file tree Collapse file tree 4 files changed +8
-12
lines changed Original file line number Diff line number Diff line change 88 "build-watch" : " yarn run clean && yarn run tsc --watch" ,
99 "clean" : " rm -rf ./lib" ,
1010 "test" : " yarn test:non-rsc && yarn test:rsc" ,
11- "test:non-rsc" : " jest tests --testPathIgnorePatterns=\" .*\\ .rsc\\ .test\\ . .*\" " ,
11+ "test:non-rsc" : " jest tests --testPathIgnorePatterns=\" .*( .rsc.test.) .*\" " ,
1212 "test:rsc" : " NODE_CONDITIONS=react-server jest tests/*.rsc.test.*" ,
1313 "type-check" : " yarn run tsc --noEmit --noErrorTruncation" ,
1414 "prepack" : " nps build.prepack" ,
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ const streamRenderRSCComponent = (
5555 transformRenderStreamChunksToResultObject ( renderState ) ;
5656
5757 const reportError = ( error : Error ) => {
58+ console . error ( 'Error in RSC stream' , error ) ;
5859 if ( throwJsErrors ) {
5960 emitError ( error ) ;
6061 }
Original file line number Diff line number Diff line change @@ -234,8 +234,8 @@ def create_connection
234234 retry_after : -> ( req , res ) do
235235 Rails . logger . error ( "An error occured and retry is going to be made" )
236236 Rails . logger . error ( "Error: #{ res . error } " )
237- Rails . logger . error ( "Request Body: #{ req . body } " )
238- 0
237+ Rails . logger . error ( "Request Body: #{ req . body &. first ( 1000 ) } " )
238+ nil
239239 end ,
240240 )
241241 . plugin ( :stream )
@@ -254,12 +254,8 @@ def create_connection
254254 # :operation_timeout
255255 # :keep_alive_timeout
256256 timeout : {
257- connect_timeout : 100 ,
258- read_timeout : 100 ,
259- write_timeout : 100 ,
260- request_timeout : 100 ,
261- operation_timeout : 100 ,
262- keep_alive_timeout : 100 ,
257+ connect_timeout : ReactOnRailsPro . configuration . renderer_http_pool_timeout ,
258+ read_timeout : ReactOnRailsPro . configuration . ssr_timeout
263259 }
264260 )
265261 rescue StandardError => e
Original file line number Diff line number Diff line change 2424 # that the remote renderer works for CI.
2525 config . renderer_use_fallback_exec_js = false
2626
27- config . renderer_http_pool_timeout = 20
28- config . ssr_timeout = 30
27+ config . ssr_timeout = 10
2928
3029 config . raise_non_shell_server_rendering_errors = false
3130
3635
3736 # Retry request in case of time out on the node-renderer side
3837 # 0 - no retry
39- config . renderer_request_retry_limit = 0
38+ config . renderer_request_retry_limit = 1
4039
4140 # Array of globs to find any files for which changes should bust the fragment cache for
4241 # cached_react_component and cached_react_component_hash. This should
You can’t perform that action at this time.
0 commit comments