)]}'
{
  "commit": "228b889750caf12529ea90fab1ca98f075fcc8d3",
  "tree": "6f0af2de365540f89aa30628315d7724bd2496b8",
  "parents": [
    "1aa25ed384064da37942c78a421e7dec189bd6f4"
  ],
  "author": {
    "name": "nileshrathi345",
    "email": "113672051+nileshrathi345@users.noreply.github.com",
    "time": "Fri Jul 10 00:51:12 2026 +0530"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Thu Jul 09 15:21:12 2026 -0400"
  },
  "message": "[LIVY-1059][FOLLOWUP] Fix missing validation condition and add unit test\n\n## What changes were proposed in this pull request?\n\nThis is a follow-up fix for [LIVY-1059](https://github.com/apache/livy/pull/529).\n\nWhen a client sends `\"queue\": \"\"` in the session create JSON, Livy was treating it as a valid queue value instead of falling back to the server default `livy.spark.yarn.queue`.\n\nThis change treats an empty queue string the same as a missing queue, so the default YARN queue from Livy config is used when the client passes \"\".\n\nUpdated in both batch and interactive session creation:\n`request.queue.filterNot(_.isEmpty).orElse(livyConf.sparkYarnQueue())`\n\n## How was this patch tested?\n\n- Added unit test in `BatchSessionSpec` for `queue \u003d Some(\"\")` and verified the default queue is passed to spark-submit\n- Added unit test in `InteractiveSessionSpec` for `queue \u003d Some(\"\")` and verified the session uses the default queue from `LivyConf`\n- Existing tests for `queue \u003d None` and user-provided queue values still pass",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "ec0f961f43e88264a7427f07e43f270cce41f0d9",
      "old_mode": 33188,
      "old_path": "server/src/main/scala/org/apache/livy/server/batch/BatchSession.scala",
      "new_id": "de771156e13ffe6b073cd21e7d9242b1b50076ac",
      "new_mode": 33188,
      "new_path": "server/src/main/scala/org/apache/livy/server/batch/BatchSession.scala"
    },
    {
      "type": "modify",
      "old_id": "0c7cb0bdeb4c82125b230bd7519c07bb0b3f88ff",
      "old_mode": 33188,
      "old_path": "server/src/main/scala/org/apache/livy/server/interactive/InteractiveSession.scala",
      "new_id": "e578326c35b580d99cef7fc91b5dce98fc16d81d",
      "new_mode": 33188,
      "new_path": "server/src/main/scala/org/apache/livy/server/interactive/InteractiveSession.scala"
    },
    {
      "type": "modify",
      "old_id": "807b20f34c6b7f1bb0e7c5325f5464420ef235dc",
      "old_mode": 33188,
      "old_path": "server/src/test/scala/org/apache/livy/server/batch/BatchSessionSpec.scala",
      "new_id": "9ecfd57b9233f2c6ccdf7909ae0d4b05d31b0537",
      "new_mode": 33188,
      "new_path": "server/src/test/scala/org/apache/livy/server/batch/BatchSessionSpec.scala"
    },
    {
      "type": "modify",
      "old_id": "31daefa1ff85a3ca219184d443f68c78df077011",
      "old_mode": 33188,
      "old_path": "server/src/test/scala/org/apache/livy/server/interactive/InteractiveSessionSpec.scala",
      "new_id": "72a2a31da5bb567eb3a302ca126cca667c5a60b5",
      "new_mode": 33188,
      "new_path": "server/src/test/scala/org/apache/livy/server/interactive/InteractiveSessionSpec.scala"
    }
  ]
}
