Github user davies commented on a diff in the pull request:

    https://github.com/apache/spark/pull/9819#discussion_r47410028
  
    --- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/execution/Window.scala ---
    @@ -149,43 +152,102 @@ case class Window(
       }
     
       /**
    -   * Create a frame processor.
    -   *
    -   * This method uses Code Generation. It can only be used on the executor 
side.
    -   *
    -   * @param frame boundaries.
    -   * @param functions to process in the frame.
    -   * @param ordinal at which the processor starts writing to the output.
    -   * @return a frame processor.
    +   * Collection containing an entry for each window frame to process. Each 
entry contains a frames'
    +   * WindowExpressions and factory function for the WindowFrameFunction.
        */
    -  private[this] def createFrameProcessor(
    -      frame: WindowFrame,
    -      functions: Array[WindowFunction],
    -      ordinal: Int): WindowFunctionFrame = frame match {
    -    // Growing Frame.
    -    case SpecifiedWindowFrame(frameType, UnboundedPreceding, 
FrameBoundaryExtractor(high)) =>
    -      val uBoundOrdering = createBoundOrdering(frameType, high)
    -      new UnboundedPrecedingWindowFunctionFrame(ordinal, functions, 
uBoundOrdering)
    -
    -    // Shrinking Frame.
    -    case SpecifiedWindowFrame(frameType, FrameBoundaryExtractor(low), 
UnboundedFollowing) =>
    -      val lBoundOrdering = createBoundOrdering(frameType, low)
    -      new UnboundedFollowingWindowFunctionFrame(ordinal, functions, 
lBoundOrdering)
    -
    -    // Moving Frame.
    -    case SpecifiedWindowFrame(frameType,
    -        FrameBoundaryExtractor(low), FrameBoundaryExtractor(high)) =>
    -      val lBoundOrdering = createBoundOrdering(frameType, low)
    -      val uBoundOrdering = createBoundOrdering(frameType, high)
    -      new SlidingWindowFunctionFrame(ordinal, functions, lBoundOrdering, 
uBoundOrdering)
    -
    -    // Entire Partition Frame.
    -    case SpecifiedWindowFrame(_, UnboundedPreceding, UnboundedFollowing) =>
    -      new UnboundedWindowFunctionFrame(ordinal, functions)
    -
    -    // Error
    -    case fr =>
    -      sys.error(s"Unsupported Frame $fr for functions: $functions")
    +  private[this] lazy val windowFrameFactoryMap = {
    --- End diff --
    
    This is a list of Tuple, not Map


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to