try {
Subject.doAsPrivileged(user, new PrivilegedExceptionAction<Object>() {
public Object run() throws Exception {
AccessController.checkPermission(new JdcpPermission("submitTaskResults"));
service.submitTaskResults(jobId, taskId, results);
return null;
}
}, null);