Github user liancheng commented on the pull request:

    https://github.com/apache/spark/pull/1715#issuecomment-50959924
  
    `SparkSubmit` uses `primaryResource` in various places, omitting primary 
resource makes the change hard to be correct in every corner case. Especially, 
in Python applications, primary resource is used to located the primary Python 
script. If we simply put it in `--py-files`, we'll have to add more constraints 
like "Python primary resource put in `--py-files` must appear as the first 
file", which can be rather unintuitive for users.
    
    Instead of omitting it, I'd suggest to add a new option `--primary` to 
specify the primary resource when `--` is used. Thus, the new option passing 
style looks something like:
    
    ```
    bin/spark-submit --class Foo --primary user.jar --master local -- --arg1 
--arg2
    ```
    
    To be more precise, the new mode consists of both `--primary` and `--`, and 
is used mutually exclusively with the positional primary resource mode. In this 
way, we needn't to change `SparkSubmit` and can also keep full downward 
compatibility.


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to