Skip to content

Commit 9153ccc

Browse files
committed
Remove partial_delete api
1 parent 4b5e50c commit 9153ccc

File tree

6 files changed

+0
-132
lines changed

6 files changed

+0
-132
lines changed

docs/api/api.rst

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,6 @@ tdclient.job\_api
5959
:undoc-members:
6060
:show-inheritance:
6161

62-
tdclient.partial\_delete\_api
63-
------------------------------------
64-
65-
.. automodule:: tdclient.partial_delete_api
66-
:members:
67-
:undoc-members:
68-
:show-inheritance:
6962

7063
tdclient.result\_api
7164
---------------------------

tdclient/api.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
from tdclient.export_api import ExportAPI
2929
from tdclient.import_api import ImportAPI
3030
from tdclient.job_api import JobAPI
31-
from tdclient.partial_delete_api import PartialDeleteAPI
3231
from tdclient.result_api import ResultAPI
3332
from tdclient.schedule_api import ScheduleAPI
3433
from tdclient.server_status_api import ServerStatusAPI
@@ -63,7 +62,6 @@ class API(
6362
ExportAPI,
6463
ImportAPI,
6564
JobAPI,
66-
PartialDeleteAPI,
6765
ResultAPI,
6866
ScheduleAPI,
6967
ServerStatusAPI,

tdclient/client.py

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -421,36 +421,6 @@ def export_data(self, db_name, table_name, storage_type, params=None):
421421
job_id = self.api.export_data(db_name, table_name, storage_type, params)
422422
return models.Job(self, job_id, "export", None)
423423

424-
def partial_delete(self, db_name, table_name, to, _from, params=None):
425-
"""Create a job to partially delete the contents of the table with the given
426-
time range.
427-
428-
Args:
429-
db_name (str): Target database name.
430-
table_name (str): Target table name.
431-
to (int): Time in Unix Epoch format indicating the End date and time of the
432-
data to be deleted. Should be set only by the hour. Minutes and seconds
433-
values will not be accepted.
434-
_from (int): Time in Unix Epoch format indicating the Start date and time of
435-
the data to be deleted. Should be set only by the hour. Minutes and
436-
seconds values will not be accepted.
437-
params (dict, optional): Extra parameters.
438-
439-
- pool_name (str, optional):
440-
Indicates the resource pool to execute this
441-
job. If not provided, the account's default resource pool would be
442-
used.
443-
- domain_key (str, optional):
444-
Domain key that will be assigned to the
445-
partial delete job to be created
446-
447-
Returns:
448-
:class:`tdclient.models.Job`
449-
"""
450-
params = {} if params is None else params
451-
job_id = self.api.partial_delete(db_name, table_name, to, _from, params)
452-
return models.Job(self, job_id, "partialdelete", None)
453-
454424
def create_bulk_import(self, name, database, table, params=None):
455425
"""Create new bulk import session
456426

tdclient/partial_delete_api.py

Lines changed: 0 additions & 49 deletions
This file was deleted.

tdclient/test/client_test.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -313,15 +313,6 @@ def test_kill():
313313
td.api.kill.assert_called_with("12345")
314314

315315

316-
def test_partial_delete():
317-
td = client.Client("APIKEY")
318-
td._api = mock.MagicMock()
319-
td._api.partial_delete = mock.MagicMock(return_value=("12345"))
320-
job = td.partial_delete("db_name", "table_name", 0, 2)
321-
td.api.partial_delete.assert_called_with("db_name", "table_name", 0, 2, {})
322-
assert job.job_id == "12345"
323-
324-
325316
def test_create_bulk_import():
326317
td = client.Client("APIKEY")
327318
td._api = mock.MagicMock()

tdclient/test/partial_delete_api_test.py

Lines changed: 0 additions & 35 deletions
This file was deleted.

0 commit comments

Comments
 (0)