Skip to content

Commit 4992c4d

Browse files
author
Xuye (Chris) Qin
authored
Merge pull request #119 from hekaisheng/upgrade-0.9.1
2 parents 9dbf6c2 + 2e3c692 commit 4992c4d

File tree

3 files changed

+19
-5
lines changed

3 files changed

+19
-5
lines changed

docs/source/mars.rst

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,9 @@ Mars 使用指南
1010

1111
.. code:: shell
1212
13-
pip install pymars==0.4.0rc1 # install mars
1413
pip install pyarrow==0.11.1
14+
pip install pymars==0.4.0rc1 # install mars
15+
1516
1617
1718
Mars 集群控制
@@ -26,6 +27,7 @@ PyODPS 提供了Mars的使用接口,用户拉起集群后,就可以使用Mar
2627

2728
.. code:: python
2829
30+
>>> options.verbose=True # 通过设置自动打印 logview 以及 Mars endpoint
2931
>>> client = o.create_mars_cluster(5, 4, 16, min_worker_num=3)
3032
3133
@@ -52,7 +54,15 @@ PyODPS 提供了Mars的使用接口,用户拉起集群后,就可以使用Mar
5254
5355
>>> print(client.get_logview_address())
5456
55-
也可以通过设置``options.verbose``为 True,可以自动打印Logview等信息。
57+
获取 Instance id
58+
-----------------
59+
60+
可以获取当前实例的 instance id。
61+
62+
.. code:: python
63+
64+
>>> print(client.instance_id)
65+
5666
5767
5868
释放集群

odps/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
version_info = (0, 9, 0, 1)
15+
version_info = (0, 9, 1)
1616
_num_index = max(idx if isinstance(v, int) else 0
1717
for idx, v in enumerate(version_info))
1818
__version__ = '.'.join(map(str, version_info[:_num_index + 1])) + \

odps/mars_extension/deploy/client.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,10 @@ def notebook_endpoint(self):
7676
def session(self):
7777
return self._mars_session
7878

79+
@property
80+
def instance_id(self):
81+
return self._kube_instance.id
82+
7983
def submit(self, worker_num=1, worker_cpu=8, worker_mem=32, disk_num=1, min_worker_num=None, cache_mem=None,
8084
resources=None, module_path=None, create_session=True, priority=None, running_cluster=None,
8185
scheduler_num=1, **kw):
@@ -99,8 +103,8 @@ def submit(self, worker_num=1, worker_cpu=8, worker_mem=32, disk_num=1, min_work
99103
'worker_mem': worker_mem,
100104
'cache_mem': cache_mem or '',
101105
'disk_num': disk_num,
102-
'resources': resources or ['public.mars-0.4.0b2.zip',
103-
'public.pyodps-0.8.5.zip'],
106+
'resources': resources or ['public.mars-0.4.0rc1.zip',
107+
'public.pyodps-0.9.1.zip'],
104108
'module_path': module_path or ['odps.mars_extension'],
105109
}
106110
if kw.get('mars_app_image', None) is not None:

0 commit comments

Comments
 (0)