Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,7 @@ byte[] lookup(

void createSupervisorsTable();

void createTaskCheckPointsTable();

void deleteAllRecords(String tableName);
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public class MetadataStorageTablesConfig
{
public static MetadataStorageTablesConfig fromBase(String base)
{
return new MetadataStorageTablesConfig(base, null, null, null, null, null, null, null, null, null, null);
return new MetadataStorageTablesConfig(base, null, null, null, null, null, null, null, null, null, null, null);
}

public static final String TASK_ENTRY_TYPE = "task";
Expand Down Expand Up @@ -75,6 +75,9 @@ public static MetadataStorageTablesConfig fromBase(String base)
@JsonProperty("supervisors")
private final String supervisorTable;

@JsonProperty("taskCheckPoints")
private final String taskCheckPointsTable;

@JsonCreator
public MetadataStorageTablesConfig(
@JsonProperty("base") String base,
Expand All @@ -87,7 +90,8 @@ public MetadataStorageTablesConfig(
@JsonProperty("taskLog") String taskLogTable,
@JsonProperty("taskLock") String taskLockTable,
@JsonProperty("audit") String auditTable,
@JsonProperty("supervisors") String supervisorTable
@JsonProperty("supervisors") String supervisorTable,
@JsonProperty("taskCheckPoints") String taskCheckPointsTable
)
{
this.base = (base == null) ? DEFAULT_BASE : base;
Expand All @@ -105,6 +109,7 @@ public MetadataStorageTablesConfig(
lockTables.put(TASK_ENTRY_TYPE, this.taskLockTable);
this.auditTable = makeTableName(auditTable, "audit");
this.supervisorTable = makeTableName(supervisorTable, "supervisors");
this.taskCheckPointsTable = makeTableName(taskCheckPointsTable, "taskCheckPoints");
}

private String makeTableName(String explicitTableName, String defaultSuffix)
Expand Down Expand Up @@ -193,4 +198,9 @@ public String getTaskLockTable()
{
return taskLockTable;
}

public String getTaskCheckPointsTable()
{
return taskCheckPointsTable;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,13 @@
*/
package io.druid.metadata.storage.sqlserver;

import java.sql.SQLException;

import org.junit.Assert;
import org.junit.Test;

import com.google.common.base.Suppliers;

import io.druid.metadata.MetadataStorageConnectorConfig;
import io.druid.metadata.MetadataStorageTablesConfig;
import org.junit.Assert;
import org.junit.Test;

import java.sql.SQLException;

@SuppressWarnings("nls")
public class SQLServerConnectorTest
Expand All @@ -49,6 +47,7 @@ public void testIsTransientException() throws Exception
null,
null,
null,
null,
null
)
)
Expand Down
Loading