Skip to content

Conversation

@HyukjinKwon
Copy link
Member

What changes were proposed in this pull request?

This PR partially backports #28569.

1.. Rename

pyspark
└── resourceinformation.py
    └── class ResourceInformation

to

pyspark
└── resource.py
    └── class ResourceInformation

So, the ResourceInformation is consistently imported via pyspark.resource.ResourceInformation.

2.. Document the new pyspark.resource module

3.. Minor docstring fix e.g.:

-     @param name the name of the resource
-     @param addresses an array of strings describing the addresses of the resource
+     :param name: the name of the resource
+     :param addresses: an array of strings describing the addresses of the resource
+
+     .. versionadded:: 3.0.0

Why are the changes needed?

To document APIs, and move Python modules to fewer and simpler modules.

Does this PR introduce any user-facing change?

No, the changes are in unreleased branches.

How was this patch tested?

Manually tested via:

cd python
./run-tests --python-executables=python3 --modules=pyspark-core

@HyukjinKwon
Copy link
Member Author

cc @dongjoon-hyun, can you take a quick look?

Copy link
Member

@dongjoon-hyun dongjoon-hyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, LGTM. Thanks.

@SparkQA

This comment has been minimized.

@SparkQA
Copy link

SparkQA commented May 20, 2020

Test build #122869 has finished for PR 28586 at commit 1079220.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@HyukjinKwon
Copy link
Member Author

Merged to branch-3.0. Thanks.

HyukjinKwon added a commit that referenced this pull request May 20, 2020
…d rename/move classes

### What changes were proposed in this pull request?

This PR partially backports #28569.

1.. Rename

```
pyspark
└── resourceinformation.py
    └── class ResourceInformation
```

to

```
pyspark
└── resource.py
    └── class ResourceInformation
```

So, the `ResourceInformation` is consistently imported via `pyspark.resource.ResourceInformation`.

2.. Document the new `pyspark.resource` module

3.. Minor docstring fix e.g.:

```diff
-     param name the name of the resource
-     param addresses an array of strings describing the addresses of the resource
+     :param name: the name of the resource
+     :param addresses: an array of strings describing the addresses of the resource
+
+     .. versionadded:: 3.0.0
```

### Why are the changes needed?

To document APIs, and move Python modules to fewer and simpler modules.

### Does this PR introduce _any_ user-facing change?

No, the changes are in unreleased branches.

### How was this patch tested?

Manually tested via:

```bash
cd python
./run-tests --python-executables=python3 --modules=pyspark-core
```

Closes #28586 from HyukjinKwon/SPARK-31748.

Authored-by: HyukjinKwon <[email protected]>
Signed-off-by: HyukjinKwon <[email protected]>
@HyukjinKwon HyukjinKwon deleted the SPARK-31748 branch July 27, 2020 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants