@@ -124,11 +124,11 @@ def accept(self, pipeline, is_interactive):
124124 # double fires on AfterCount trigger, once appropriately, and once
125125 # incorrectly at the end of the window. This if condition could be
126126 # more targeted, but for now we'll just ignore all unsafe triggers.
127- # if pipeline.allow_unsafe_triggers:
128- # self.supported_by_prism_runner = False
127+ if pipeline .allow_unsafe_triggers :
128+ self .supported_by_prism_runner = False
129129 # TODO(https://github.com/apache/beam/issues/33623): Prism currently
130130 # does not support interactive mode
131- if is_in_ipython () or is_interactive :
131+ elif is_in_ipython () or is_interactive :
132132 self .supported_by_prism_runner = False
133133 # TODO(https://github.com/apache/beam/issues/33623): Prism currently
134134 # does not support the update compat flag
@@ -144,10 +144,6 @@ def accept(self, pipeline, is_interactive):
144144 # It does sometimes, but at volume suites start to fail. We will try
145145 # to enable this in a future release.
146146 self .supported_by_prism_runner = False
147-
148- _LOGGER .error (
149- 'PrismRunnerSupportVisotr returns' +
150- str (self .supported_by_prism_runner ))
151147 return self .supported_by_prism_runner
152148
153149 def visit_transform (self , applied_ptransform ):
@@ -204,18 +200,13 @@ def visit_transform(self, applied_ptransform):
204200 transform .get_windowing ('' ).windowfn , beam .window .Sessions ):
205201 self .supported_by_prism_runner = False
206202
207- if not self .supported_by_prism_runner :
208- _LOGGER .error (
209- 'Visit ' + str (applied_ptransform ) + ' returns ' +
210- str (self .supported_by_prism_runner ))
211-
212203 # Use BundleBasedDirectRunner if other runners are missing needed features.
213204 runner = BundleBasedDirectRunner ()
214205
215206 # Check whether all transforms used in the pipeline are supported by the
216207 # PrismRunner
217208 if _PrismRunnerSupportVisitor ().accept (pipeline , self ._is_interactive ):
218- _LOGGER .error ('Running pipeline with PrismRunner.' )
209+ _LOGGER .info ('Running pipeline with PrismRunner.' )
219210 from apache_beam .runners .portability import prism_runner
220211 runner = prism_runner .PrismRunner ()
221212
@@ -225,7 +216,7 @@ def visit_transform(self, applied_ptransform):
225216 # probably failed on job submission.
226217 if (PipelineState .is_terminal (pr .state ) and
227218 pr .state != PipelineState .DONE ):
228- _LOGGER .error (
219+ _LOGGER .info (
229220 'Pipeline failed on PrismRunner, falling back to DirectRunner.' )
230221 runner = BundleBasedDirectRunner ()
231222 else :
@@ -234,14 +225,13 @@ def visit_transform(self, applied_ptransform):
234225 # If prism fails in Preparing the portable job, then the PortableRunner
235226 # code raises an exception. Catch it, log it, and use the Direct runner
236227 # instead.
237- _LOGGER .error ('Exception with PrismRunner:\n %s\n ' % (e ))
238- _LOGGER .error ('Falling back to DirectRunner' )
228+ _LOGGER .info ('Exception with PrismRunner:\n %s\n ' % (e ))
229+ _LOGGER .info ('Falling back to DirectRunner' )
239230 runner = BundleBasedDirectRunner ()
240231
241232 # Check whether all transforms used in the pipeline are supported by the
242233 # FnApiRunner, and the pipeline was not meant to be run as streaming.
243234 if _FnApiRunnerSupportVisitor ().accept (pipeline ):
244- _LOGGER .error ('Running pipeline with FnApiRunner.' )
245235 from apache_beam .portability .api import beam_provision_api_pb2
246236 from apache_beam .runners .portability .fn_api_runner import fn_runner
247237 from apache_beam .runners .portability .portable_runner import JobServiceHandle
0 commit comments