Skip to content

Commit

Permalink
Work on REST API
Browse files Browse the repository at this point in the history
  • Loading branch information
gwilmer committed Nov 7, 2012
1 parent 828a19f commit e02bf2e
Showing 1 changed file with 18 additions and 3 deletions.
Expand Up @@ -20,7 +20,6 @@
*/
package org.jumpmind.symmetric.web.rest;

import java.io.IOException;
import java.lang.annotation.Annotation;
import java.util.Collection;
import java.util.List;
Expand Down Expand Up @@ -255,6 +254,19 @@ public final void dropTriggers(@PathVariable("engine") String engineName) {
dropTriggersImpl(getSymmetricEngine(engineName));
}

/**
* Removes instances of triggers for the specified table for the single engine on the node
* @param engineName
*/
@RequestMapping(value = "engine/{engine}/table/{table}/droptriggers", method = RequestMethod.POST)
@ResponseStatus( HttpStatus.NO_CONTENT )
@ResponseBody
public final void dropTriggers(
@PathVariable("engine") String engineName,
@PathVariable("table") String tableName) {
dropTriggersImpl(getSymmetricEngine(engineName), tableName);
}

/**
* Uninstalls all SymmetricDS objects from the given node (database) for the single engine on the node
*/
Expand Down Expand Up @@ -434,6 +446,10 @@ private void dropTriggersImpl(ISymmetricEngine engine) {
//TODO: implement
}

private void dropTriggersImpl(ISymmetricEngine engine, String tableName) {
//TODO: implement
}

private void uninstallImpl(ISymmetricEngine engine) {
engine.uninstall();
}
Expand Down Expand Up @@ -472,9 +488,8 @@ private void loadProfileImpl(ISymmetricEngine engine, MultipartFile file) {
inError = true;
}
if (inError) {
throw new RuntimeException("Error loading profile.");
throw new InternalServerErrorException();
}
// TODO: Add error handling
}

private NodeList childrenImpl(ISymmetricEngine engine) {
Expand Down

0 comments on commit e02bf2e

Please sign in to comment.