http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/product/src/main/java/org/apache/oodt/product/LargeProductQueryHandler.java ---------------------------------------------------------------------- diff --git a/product/src/main/java/org/apache/oodt/product/LargeProductQueryHandler.java b/product/src/main/java/org/apache/oodt/product/LargeProductQueryHandler.java index 58f3d7c..029e9ce 100644 --- a/product/src/main/java/org/apache/oodt/product/LargeProductQueryHandler.java +++ b/product/src/main/java/org/apache/oodt/product/LargeProductQueryHandler.java @@ -53,5 +53,5 @@ public interface LargeProductQueryHandler extends QueryHandler { * @param id Product ID. * @throws ProductException if an error occurs. */ - void close(String id) throws ProductException; + void close(String id); }
http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/product/src/main/java/org/apache/oodt/product/handlers/ofsn/OFSNFileHandler.java ---------------------------------------------------------------------- diff --git a/product/src/main/java/org/apache/oodt/product/handlers/ofsn/OFSNFileHandler.java b/product/src/main/java/org/apache/oodt/product/handlers/ofsn/OFSNFileHandler.java index ab5c447..31a3218 100644 --- a/product/src/main/java/org/apache/oodt/product/handlers/ofsn/OFSNFileHandler.java +++ b/product/src/main/java/org/apache/oodt/product/handlers/ofsn/OFSNFileHandler.java @@ -171,7 +171,7 @@ public class OFSNFileHandler implements LargeProductQueryHandler, * * @see org.apache.oodt.product.LargeProductQueryHandler#close(java.lang.String) */ - public void close(String id) throws ProductException { + public void close(String id) { // nothing to do } @@ -249,7 +249,7 @@ public class OFSNFileHandler implements LargeProductQueryHandler, return cfg.getType().equals(LISTING_CMD); } - private boolean isGetCmd(String cmd) throws ProductException { + private boolean isGetCmd(String cmd) { OFSNHandlerConfig cfg = this.conf.getHandlerConfig(cmd); return cfg.getType().equals(GET_CMD); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/profile/src/main/java/org/apache/oodt/profile/handlers/DatabaseProfileManager.java ---------------------------------------------------------------------- diff --git a/profile/src/main/java/org/apache/oodt/profile/handlers/DatabaseProfileManager.java b/profile/src/main/java/org/apache/oodt/profile/handlers/DatabaseProfileManager.java index f2b1eb4..28a9b9c 100755 --- a/profile/src/main/java/org/apache/oodt/profile/handlers/DatabaseProfileManager.java +++ b/profile/src/main/java/org/apache/oodt/profile/handlers/DatabaseProfileManager.java @@ -64,7 +64,7 @@ public abstract class DatabaseProfileManager implements ProfileManager * @return The profiles in the database, as a list. * @throws ProfileException If an error occurs. */ - public abstract List getProfiles(Connection conn) throws ProfileException; + public abstract List getProfiles(Connection conn); Connection conn; Properties props; @@ -107,7 +107,7 @@ public abstract class DatabaseProfileManager implements ProfileManager } } - public abstract List findProfiles(Connection conn, XMLQuery query) throws DOMException, ProfileException; + public abstract List findProfiles(Connection conn, XMLQuery query) throws DOMException; public void add(Profile profile) throws ProfileException { @@ -122,7 +122,7 @@ public abstract class DatabaseProfileManager implements ProfileManager throw new ProfileSQLException (e); } } - public abstract void add(Connection conn, Profile profile) throws ProfileException ; + public abstract void add(Connection conn, Profile profile); public void addAll(Collection collection) throws ProfileException @@ -143,9 +143,9 @@ public abstract class DatabaseProfileManager implements ProfileManager } } - public abstract void addAll(Connection conn,Collection collection) throws ProfileException; + public abstract void addAll(Connection conn,Collection collection); - public abstract void clear(Connection conn) throws ProfileException ; + public abstract void clear(Connection conn); public void clear() throws ProfileException { @@ -161,14 +161,14 @@ public abstract class DatabaseProfileManager implements ProfileManager throw new ProfileSQLException (e); } } - public boolean contains(Profile profile) throws ProfileException { + public boolean contains(Profile profile) { throw new UnsupportedOperationException("Not yet implemented"); } - public boolean containsAll(Collection collection) throws ProfileException { + public boolean containsAll(Collection collection) { throw new UnsupportedOperationException("Not yet implemented"); } - public abstract Profile get(Connection conn, String profID) throws ProfileException; + public abstract Profile get(Connection conn, String profID); public Profile get(String profId) throws ProfileException { // Create database connection @@ -183,20 +183,20 @@ public abstract class DatabaseProfileManager implements ProfileManager } } - public Collection getAll() throws ProfileException { + public Collection getAll() { throw new UnsupportedOperationException("Not yet implemented"); } - public boolean isEmpty() throws ProfileException { + public boolean isEmpty() { throw new UnsupportedOperationException("Not yet implemented"); } - public Iterator iterator() throws ProfileException { + public Iterator iterator() { throw new UnsupportedOperationException("Not yet implemented"); } public abstract boolean remove(Connection conn, String profId, String version) - throws ProfileException; + ; - public abstract boolean remove(Connection conn, String profId) throws ProfileException; + public abstract boolean remove(Connection conn, String profId); public boolean remove(String profId, String version) throws ProfileException @@ -242,7 +242,7 @@ public abstract class DatabaseProfileManager implements ProfileManager } - public abstract int size(Connection conn) throws ProfileException ; + public abstract int size(Connection conn); public void replace(Profile profile) throws ProfileException { // Create database connection @@ -257,7 +257,7 @@ public abstract class DatabaseProfileManager implements ProfileManager throw new ProfileException(e.getMessage()); } } - public abstract void replace(Connection conn, Profile profile) throws ProfileException ; + public abstract void replace(Connection conn, Profile profile); protected static Connection openConnection(Properties props) throws SQLException, ProfileException { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/profile/src/main/java/org/apache/oodt/profile/handlers/ProfileManager.java ---------------------------------------------------------------------- diff --git a/profile/src/main/java/org/apache/oodt/profile/handlers/ProfileManager.java b/profile/src/main/java/org/apache/oodt/profile/handlers/ProfileManager.java index c5aa987..13d0ba6 100755 --- a/profile/src/main/java/org/apache/oodt/profile/handlers/ProfileManager.java +++ b/profile/src/main/java/org/apache/oodt/profile/handlers/ProfileManager.java @@ -66,7 +66,7 @@ public interface ProfileManager extends ProfileHandler { * @return True if <var>profile</var> is present in the server, false otherwise. * @throws ProfileException If any error occurs. */ - boolean contains(Profile profile) throws ProfileException; + boolean contains(Profile profile); /** * Tell if the given collection of profiles are managed by this server. @@ -76,7 +76,7 @@ public interface ProfileManager extends ProfileHandler { * the server, false otherwise. * @throws ProfileException If any error occurs. */ - boolean containsAll(Collection collection) throws ProfileException; + boolean containsAll(Collection collection); /** * Get all profiles. @@ -84,7 +84,7 @@ public interface ProfileManager extends ProfileHandler { * @return A collection of profiles * @throws ProfileException If any error occurs. */ - Collection getAll() throws ProfileException; + Collection getAll(); /** * Tell if the set of profiles managed by this server is empty. @@ -92,7 +92,7 @@ public interface ProfileManager extends ProfileHandler { * @return True if there are no profiles in this server. * @throws ProfileException If any error occurs. */ - boolean isEmpty() throws ProfileException; + boolean isEmpty(); /** * Iterate over the available profiles. @@ -104,7 +104,7 @@ public interface ProfileManager extends ProfileHandler { * @return An iterator over {@link Profile}s. * @throws ProfileException If any error occurs. */ - Iterator iterator() throws ProfileException; + Iterator iterator(); /** * Remove the profile with the given ID. http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/protocol/api/src/main/java/org/apache/oodt/cas/protocol/cli/action/DownloadCliAction.java ---------------------------------------------------------------------- diff --git a/protocol/api/src/main/java/org/apache/oodt/cas/protocol/cli/action/DownloadCliAction.java b/protocol/api/src/main/java/org/apache/oodt/cas/protocol/cli/action/DownloadCliAction.java index 7ed0b64..9497d02 100644 --- a/protocol/api/src/main/java/org/apache/oodt/cas/protocol/cli/action/DownloadCliAction.java +++ b/protocol/api/src/main/java/org/apache/oodt/cas/protocol/cli/action/DownloadCliAction.java @@ -68,7 +68,7 @@ public class DownloadCliAction extends ProtocolCliAction { return usedProtocol; } - protected ProtocolFile createProtocolFile() throws URISyntaxException { + protected ProtocolFile createProtocolFile() { return new ProtocolFile(uri.getPath(), false); } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/protocol/imaps/src/main/java/org/apache/oodt/cas/protocol/imaps/ImapsProtocol.java ---------------------------------------------------------------------- diff --git a/protocol/imaps/src/main/java/org/apache/oodt/cas/protocol/imaps/ImapsProtocol.java b/protocol/imaps/src/main/java/org/apache/oodt/cas/protocol/imaps/ImapsProtocol.java index 8ee8e87..b09a4d7 100644 --- a/protocol/imaps/src/main/java/org/apache/oodt/cas/protocol/imaps/ImapsProtocol.java +++ b/protocol/imaps/src/main/java/org/apache/oodt/cas/protocol/imaps/ImapsProtocol.java @@ -304,7 +304,7 @@ public class ImapsProtocol implements Protocol { } private String getContentFromPlainText(Part p) throws MessagingException, - IOException, DecoderException { + IOException { StringBuilder content = new StringBuilder(""); if (p.isMimeType("text/plain")) { content.append((String) p.getContent()); @@ -322,7 +322,7 @@ public class ImapsProtocol implements Protocol { } private String getContentFromHTML(Part p) throws MessagingException, - IOException, DecoderException, SAXException, TikaException { + IOException, SAXException, TikaException { StringBuilder content = new StringBuilder(""); if (p.isMimeType("multipart/*")) { Multipart mp = (Multipart) p.getContent(); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/config/Config.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/config/Config.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/config/Config.java index ddf35de..790f51b 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/config/Config.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/config/Config.java @@ -173,8 +173,7 @@ public class Config implements ConfigMetKeys { * @throws ClassNotFoundException * @throws ClassNotFoundException */ - void loadProperties() throws ConfigException, InstantiationException, - IOException, ClassNotFoundException { + void loadProperties() throws ConfigException, InstantiationException { this.loadExternalConfigFiles(); this.loadProtocolTypes(); this.loadParserInfo(); @@ -228,7 +227,7 @@ public class Config implements ConfigMetKeys { } } - void loadIngester() throws InstantiationException, ConfigException { + void loadIngester() throws ConfigException { try { String fmUrlStr = PropertiesUtils.getProperties(INGESTER_FM_URL, new String[] { NO_FM_SPECIFIED })[0]; http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/Daemon.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/Daemon.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/Daemon.java index 5ff5e0e..135c6e5 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/Daemon.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/Daemon.java @@ -115,8 +115,7 @@ public class Daemon extends UnicastRemoteObject implements DaemonRmiInterface, * @throws SecurityException */ public Daemon(int rmiRegPort, int daemonID, Config config, - DaemonInfo daemonInfo, SiteInfo siteInfo) throws RemoteException, - InstantiationException { + DaemonInfo daemonInfo, SiteInfo siteInfo) throws RemoteException { super(); this.rmiRegPort = rmiRegPort; @@ -155,8 +154,7 @@ public class Daemon extends UnicastRemoteObject implements DaemonRmiInterface, return "Daemon" + this.getDaemonID(); } - private void registerRMIServer() throws RemoteException, - MalformedURLException, NotBoundException, AlreadyBoundException { + private void registerRMIServer() throws RemoteException { try { Naming.bind("//localhost:" + this.rmiRegPort + "/daemon" + this.getDaemonID(), this); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/DaemonController.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/DaemonController.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/DaemonController.java index 284e4ee..264e7cd 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/DaemonController.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/daemon/DaemonController.java @@ -43,7 +43,7 @@ public class DaemonController { * * @throws InstantiationException */ - public DaemonController(String rmiUrl) throws RemoteException { + public DaemonController(String rmiUrl) { try { daemon = (DaemonRmiInterface) Naming.lookup(rmiUrl); System.out.println(!daemon.getHasBeenToldToQuit()); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/filerestrictions/parsers/GenericEmailParser.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/filerestrictions/parsers/GenericEmailParser.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/filerestrictions/parsers/GenericEmailParser.java index e9c6318..3f74407 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/filerestrictions/parsers/GenericEmailParser.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/filerestrictions/parsers/GenericEmailParser.java @@ -108,7 +108,7 @@ public class GenericEmailParser implements Parser { return emailText.toString(); } - private List<String> generateFilePaths(String emailText) throws ParserException { + private List<String> generateFilePaths(String emailText) { List<String> filePaths = Lists.newArrayList(); Pattern pattern = Pattern.compile(filePattern); Matcher m = pattern.matcher(emailText); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolHandler.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolHandler.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolHandler.java index 3bc9a3c..6a41dbb 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolHandler.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolHandler.java @@ -122,7 +122,7 @@ public class ProtocolHandler { } private Protocol getAppropriateProtocol(RemoteSiteFile pFile, - boolean allowReuse) throws ProtocolException, MalformedURLException { + boolean allowReuse) throws ProtocolException { return this.getAppropriateProtocolBySite(pFile.getSite(), allowReuse); } @@ -238,8 +238,7 @@ public class ProtocolHandler { } private boolean passesDynamicDetection(PagingInfo pgInfo, - List<RemoteSiteFile> newLS) throws MalformedURLException, - ProtocolException { + List<RemoteSiteFile> newLS) { return !(pgInfo.getSizeOfLastLS() != -1 && (pgInfo.getSizeOfLastLS() != newLS.size() || (newLS.size() != 0 && pgInfo.getPageLoc() < newLS.size() && (newLS.get(pgInfo @@ -381,8 +380,7 @@ public class ProtocolHandler { protocol.cdHome(); } - public boolean isProtocolConnected(Protocol protocol) - throws ProtocolException { + public boolean isProtocolConnected(Protocol protocol) { return protocol.connected(); } @@ -396,8 +394,7 @@ public class ProtocolHandler { return this.getProtocolFileByProtocol(site, protocol, file, isDir); } - public synchronized boolean delete(Protocol protocol, RemoteSiteFile file) - throws MalformedURLException, ProtocolException { + public synchronized boolean delete(Protocol protocol, RemoteSiteFile file) { try { PagingInfo pgInfo = this.getPagingInfo(file.getRemoteParent()); List<RemoteSiteFile> fileList = this.ls(protocol, file.getRemoteParent()); @@ -565,8 +562,7 @@ public class ProtocolHandler { this.pFileAtPageLoc = null; } - synchronized void updatePageInfo(int newPageLoc, List<RemoteSiteFile> ls) - throws MalformedURLException, ProtocolException { + synchronized void updatePageInfo(int newPageLoc, List<RemoteSiteFile> ls) { this.sizeOfLastLS = ls.size(); this.pageLoc = newPageLoc < 0 ? 0 : newPageLoc; this.pFileAtPageLoc = (this.sizeOfLastLS > 0 && newPageLoc < ls.size()) ? ls http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolPath.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolPath.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolPath.java index d2aaf8e..7235e82 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolPath.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/protocol/ProtocolPath.java @@ -116,7 +116,7 @@ public class ProtocolPath implements Serializable { return false; } - public String getParentDirPath() throws MalformedURLException { + public String getParentDirPath() { if (path.length() <= 1) return null; return path.substring(0, path.lastIndexOf("/")); @@ -126,7 +126,7 @@ public class ProtocolPath implements Serializable { return (path + " isDir=" + this.isDir); } - public ProtocolPath getParentPath() throws MalformedURLException { + public ProtocolPath getParentPath() { return new ProtocolPath(path.substring(0, path.lastIndexOf("/")), true); } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/FileRetrievalSystem.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/FileRetrievalSystem.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/FileRetrievalSystem.java index 4dcaf97..3ccb510 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/FileRetrievalSystem.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/FileRetrievalSystem.java @@ -226,7 +226,7 @@ public class FileRetrievalSystem { * * @throws ThreadEvaluatorException */ - void resetVariables() throws ThreadEvaluatorException { + void resetVariables() { numberOfSessions = 0; stagingAreas = new HashSet<File>(); avaliableSessions = new Vector<Protocol>(); @@ -277,7 +277,7 @@ public class FileRetrievalSystem { } public void changeToRoot(RemoteSite remoteSite) throws - MalformedURLException, org.apache.oodt.cas.protocol.exceptions.ProtocolException { + org.apache.oodt.cas.protocol.exceptions.ProtocolException { if (validate(remoteSite)) protocolHandler.cdToROOT(protocolHandler .getAppropriateProtocolBySite(remoteSite, true)); @@ -285,8 +285,7 @@ public class FileRetrievalSystem { throw new ProtocolException("Not a valid remote site " + remoteSite); } - public void changeToHOME(RemoteSite remoteSite) throws ProtocolException, - MalformedURLException { + public void changeToHOME(RemoteSite remoteSite) throws ProtocolException { if (validate(remoteSite)) protocolHandler.cdToHOME(protocolHandler .getAppropriateProtocolBySite(remoteSite, true)); @@ -305,8 +304,7 @@ public class FileRetrievalSystem { throw new ProtocolException("Not a valid remote site " + remoteSite); } - public void changeToDir(RemoteSiteFile pFile) throws ProtocolException, - MalformedURLException { + public void changeToDir(RemoteSiteFile pFile) throws ProtocolException { RemoteSite remoteSite = pFile.getSite(); if (validate(remoteSite)) protocolHandler.cd(protocolHandler.getAppropriateProtocolBySite( @@ -335,8 +333,7 @@ public class FileRetrievalSystem { } public ProtocolFile getCurrentFile(RemoteSite remoteSite) - throws ProtocolFileException, ProtocolException, - MalformedURLException { + throws ProtocolException { if (validate(remoteSite)) return protocolHandler.pwd(remoteSite, protocolHandler .getAppropriateProtocolBySite(remoteSite, true)); @@ -349,7 +346,7 @@ public class FileRetrievalSystem { String renamingString, File downloadToDir, String uniqueMetadataElement, boolean deleteAfterDownload, Metadata fileMetadata) throws ToManyFailedDownloadsException, RemoteConnectionException, - ProtocolFileException, ProtocolException, + ProtocolException, AlreadyInDatabaseException, UndefinedTypeException, CatalogException, IOException { if (validate(remoteSite)) { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/RetrievalSetup.java ---------------------------------------------------------------------- diff --git a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/RetrievalSetup.java b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/RetrievalSetup.java index c74ff20..147781e 100644 --- a/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/RetrievalSetup.java +++ b/pushpull/src/main/java/org/apache/oodt/cas/pushpull/retrievalsystem/RetrievalSetup.java @@ -71,8 +71,7 @@ public class RetrievalSetup { linker = new DataFileToPropFileLinker(); } - public void retrieveFiles(PropFilesInfo pfi, final DataFilesInfo dfi) - throws RetrievalMethodException { + public void retrieveFiles(PropFilesInfo pfi, final DataFilesInfo dfi) { FileRetrievalSystem dataFilesFRS = null; try { @@ -147,8 +146,7 @@ public class RetrievalSetup { } } - private void startPropFileDownload(final PropFilesInfo pfi) - throws IOException { + private void startPropFileDownload(final PropFilesInfo pfi) { if (pfi.needsToBeDownloaded()) { this.downloadingProps = true; new Thread(new Runnable() { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobQueue.java ---------------------------------------------------------------------- diff --git a/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobQueue.java b/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobQueue.java index 41ff6f4..8c6cdbc 100644 --- a/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobQueue.java +++ b/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobQueue.java @@ -65,7 +65,7 @@ public interface JobQueue { * @throws JobQueueException * If there is any error obtaining the queued jobs. */ - List getQueuedJobs() throws JobQueueException; + List getQueuedJobs(); /** * Purges all {@link JobSpec}s from the queue. @@ -73,7 +73,7 @@ public interface JobQueue { * @throws JobQueueException * If there is any error purging all the {@link JobSpec}s. */ - void purge() throws JobQueueException; + void purge(); /** * Returns a boolean value representing whether or not the queue is empty. @@ -90,7 +90,7 @@ public interface JobQueue { * @throws JobQueueException * If there is any error getting the next {@link JobSpec}. */ - JobSpec getNextJob() throws JobQueueException; + JobSpec getNextJob(); /** http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobStack.java ---------------------------------------------------------------------- diff --git a/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobStack.java b/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobStack.java index bc95c23..5118a72 100644 --- a/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobStack.java +++ b/resource/src/main/java/org/apache/oodt/cas/resource/jobqueue/JobStack.java @@ -102,7 +102,7 @@ public class JobStack implements JobQueue { * * @see org.apache.oodt.cas.resource.jobqueue.JobQueue#getQueuedJobs() */ - public List getQueuedJobs() throws JobQueueException { + public List getQueuedJobs() { return queue; } @@ -111,7 +111,7 @@ public class JobStack implements JobQueue { * * @see org.apache.oodt.cas.resource.jobqueue.JobQueue#purge() */ - public void purge() throws JobQueueException { + public void purge() { queue.removeAllElements(); //TODO: think about whether or not it makes //sense to do something with the JobRepository @@ -128,7 +128,7 @@ public class JobStack implements JobQueue { /* (non-Javadoc) * @see org.apache.oodt.cas.resource.jobqueue.JobQueue#getNextJob() */ - public JobSpec getNextJob() throws JobQueueException { + public JobSpec getNextJob() { JobSpec spec = (JobSpec)queue.remove(0); // update its status since getNextJob is // called by the scheduler when it is going http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/resource/src/main/java/org/apache/oodt/cas/resource/monitor/ganglia/GangliaResourceMonitor.java ---------------------------------------------------------------------- diff --git a/resource/src/main/java/org/apache/oodt/cas/resource/monitor/ganglia/GangliaResourceMonitor.java b/resource/src/main/java/org/apache/oodt/cas/resource/monitor/ganglia/GangliaResourceMonitor.java index 60343c9..5725a83 100644 --- a/resource/src/main/java/org/apache/oodt/cas/resource/monitor/ganglia/GangliaResourceMonitor.java +++ b/resource/src/main/java/org/apache/oodt/cas/resource/monitor/ganglia/GangliaResourceMonitor.java @@ -238,8 +238,7 @@ public class GangliaResourceMonitor implements Monitor { return node; } - private void initGmetaNodes(String host, int port) - throws MalformedURLException { + private void initGmetaNodes(String host, int port) { this.addGmetadNode(host, port); } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/resource/src/main/java/org/apache/oodt/cas/resource/scheduler/QueueManager.java ---------------------------------------------------------------------- diff --git a/resource/src/main/java/org/apache/oodt/cas/resource/scheduler/QueueManager.java b/resource/src/main/java/org/apache/oodt/cas/resource/scheduler/QueueManager.java index d05430f..c6a7522 100644 --- a/resource/src/main/java/org/apache/oodt/cas/resource/scheduler/QueueManager.java +++ b/resource/src/main/java/org/apache/oodt/cas/resource/scheduler/QueueManager.java @@ -62,7 +62,7 @@ public class QueueManager { this.queueToNodesMapping.put(queueName, nodes); } - public synchronized void addQueue(String queueName) throws QueueManagerException { + public synchronized void addQueue(String queueName) { if (queueName != null && !this.queueToNodesMapping.containsKey(queueName)) this.queueToNodesMapping.put(queueName, new LinkedHashSet<String>()); } @@ -74,11 +74,11 @@ public class QueueManager { throw new QueueManagerException("Queue '" + queueName + "' does not exist"); } - public synchronized List<String> getQueues() throws QueueManagerException { + public synchronized List<String> getQueues() { return new Vector<String>(this.queueToNodesMapping.keySet()); } - public synchronized List<String> getQueues(String nodeId) throws QueueManagerException { + public synchronized List<String> getQueues(String nodeId) { Vector<String> queueNames = new Vector<String>(); for (String queueName : this.queueToNodesMapping.keySet()) if (this.queueToNodesMapping.get(queueName).contains(nodeId)) @@ -93,7 +93,7 @@ public class QueueManager { throw new QueueManagerException("Queue '" + queueName + "' does not exist"); } - public synchronized void removeQueue(String queueName) throws QueueManagerException { + public synchronized void removeQueue(String queueName) { if (queueName != null) this.queueToNodesMapping.remove(queueName); } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/resource/src/main/java/org/apache/oodt/cas/resource/system/extern/XmlRpcBatchStub.java ---------------------------------------------------------------------- diff --git a/resource/src/main/java/org/apache/oodt/cas/resource/system/extern/XmlRpcBatchStub.java b/resource/src/main/java/org/apache/oodt/cas/resource/system/extern/XmlRpcBatchStub.java index 5e614ae..835aba9 100644 --- a/resource/src/main/java/org/apache/oodt/cas/resource/system/extern/XmlRpcBatchStub.java +++ b/resource/src/main/java/org/apache/oodt/cas/resource/system/extern/XmlRpcBatchStub.java @@ -62,7 +62,7 @@ public class XmlRpcBatchStub { private static Map jobThreadMap = null; - public XmlRpcBatchStub(int port) throws Exception { + public XmlRpcBatchStub(int port) { webServerPort = port; // start up the web server @@ -129,8 +129,7 @@ public class XmlRpcBatchStub { return true; } - private boolean genericExecuteJob(Hashtable jobHash, Object jobInput) - throws JobException { + private boolean genericExecuteJob(Hashtable jobHash, Object jobInput) { JobInstance exec = null; JobInput in = null; try { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/CASProductHandler.java ---------------------------------------------------------------------- diff --git a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/CASProductHandler.java b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/CASProductHandler.java index edcdd19..7de8e20 100644 --- a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/CASProductHandler.java +++ b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/CASProductHandler.java @@ -105,7 +105,7 @@ public class CASProductHandler implements LargeProductQueryHandler { * * @see org.apache.product.LargeProductQueryHandler#close(java.lang.String) */ - public void close(String id) throws ProductException { + public void close(String id) { // doesn't really have to do anything b/c we're not going // to keep anything open http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFDatasetServlet.java ---------------------------------------------------------------------- diff --git a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFDatasetServlet.java b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFDatasetServlet.java index 58aba8d..5b4eb3b 100644 --- a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFDatasetServlet.java +++ b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFDatasetServlet.java @@ -140,7 +140,7 @@ public class RDFDatasetServlet extends HttpServlet { } public void doIt(HttpServletRequest req, HttpServletResponse resp) - throws ServletException, java.io.IOException { + throws ServletException { // need to know the type of product to get products for String productTypeName = req.getParameter("type"); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFProductServlet.java ---------------------------------------------------------------------- diff --git a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFProductServlet.java b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFProductServlet.java index 00f3293..d2fb2ac 100644 --- a/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFProductServlet.java +++ b/webapp/fmprod/src/main/java/org/apache/oodt/cas/product/rdf/RDFProductServlet.java @@ -144,7 +144,7 @@ public class RDFProductServlet extends HttpServlet { } public void doIt(HttpServletRequest req, HttpServletResponse resp) - throws ServletException, java.io.IOException { + throws ServletException { // need to know the type of product to get products for String productTypeName = req.getParameter("type"); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/processor/WorkflowProcessorQueue.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/processor/WorkflowProcessorQueue.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/processor/WorkflowProcessorQueue.java index 6c9dff8..4cd8121 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/processor/WorkflowProcessorQueue.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/processor/WorkflowProcessorQueue.java @@ -126,8 +126,7 @@ public class WorkflowProcessorQueue { } } - private WorkflowProcessor fromWorkflowInstance(WorkflowInstance inst) - throws EngineException { + private WorkflowProcessor fromWorkflowInstance(WorkflowInstance inst) { WorkflowProcessor processor = null; if (processorCache.containsKey(inst.getId())) { return processorCache.get(inst.getId()); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/AsynchronousLocalEngineRunner.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/AsynchronousLocalEngineRunner.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/AsynchronousLocalEngineRunner.java index eb99322..595c43a 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/AsynchronousLocalEngineRunner.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/AsynchronousLocalEngineRunner.java @@ -69,7 +69,7 @@ public class AsynchronousLocalEngineRunner extends AbstractEngineRunnerBase { * .oodt.cas.workflow.engine.processor.TaskProcessor) */ @Override - public void execute(final TaskProcessor taskProcessor) throws Exception { + public void execute(final TaskProcessor taskProcessor) { Thread worker = new Thread() { @Override @@ -129,7 +129,7 @@ public class AsynchronousLocalEngineRunner extends AbstractEngineRunnerBase { * @see org.apache.oodt.cas.workflow.engine.EngineRunner#shutdown() */ @Override - public void shutdown() throws Exception { + public void shutdown() { for (Thread worker : this.workerMap.values()) { if (worker != null) { worker.interrupt(); @@ -147,7 +147,7 @@ public class AsynchronousLocalEngineRunner extends AbstractEngineRunnerBase { * .apache.oodt.cas.workflow.engine.processor.TaskProcessor) */ @Override - public boolean hasOpenSlots(TaskProcessor taskProcessor) throws Exception { + public boolean hasOpenSlots(TaskProcessor taskProcessor) { // TODO Auto-generated method stub return true; } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/EngineRunner.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/EngineRunner.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/EngineRunner.java index 9bf4f94..cb1d17e 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/EngineRunner.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/EngineRunner.java @@ -44,7 +44,7 @@ public abstract class EngineRunner { * If any error occurs. */ public abstract void execute(TaskProcessor taskProcessor) - throws Exception; + ; /** * Shuts this runner down and frees its resources. @@ -53,7 +53,7 @@ public abstract class EngineRunner { * If any error occurs while freeing resources. * */ - public abstract void shutdown() throws Exception; + public abstract void shutdown(); /** * Decides whether or not there are available slots within this runner @@ -63,7 +63,7 @@ public abstract class EngineRunner { * @return True if there is an open slot, false otherwise. * @throws Exception If any error occurs. */ - public abstract boolean hasOpenSlots(TaskProcessor taskProcessor) throws Exception; + public abstract boolean hasOpenSlots(TaskProcessor taskProcessor); public abstract void setInstanceRepository(WorkflowInstanceRepository instRep); http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/ResourceRunner.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/ResourceRunner.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/ResourceRunner.java index 4366d2d..1f5267a 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/ResourceRunner.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/engine/runner/ResourceRunner.java @@ -63,7 +63,7 @@ public class ResourceRunner extends AbstractEngineRunnerBase implements CoreMetK * @see org.apache.oodt.cas.workflow.engine.runner.EngineRunner#execute(org.apache.oodt.cas.workflow.engine.processor.TaskProcessor) */ @Override - public void execute(TaskProcessor taskProcessor) throws Exception { + public void execute(TaskProcessor taskProcessor) { Job workflowTaskJob = new Job(); WorkflowTask workflowTask = getTaskFromProcessor(taskProcessor); workflowTaskJob.setName(workflowTask.getTaskId()); @@ -102,7 +102,7 @@ public class ResourceRunner extends AbstractEngineRunnerBase implements CoreMetK * @see org.apache.oodt.cas.workflow.engine.EngineRunner#shutdown() */ @Override - public void shutdown() throws Exception { + public void shutdown() { // TODO Auto-generated method stub } @@ -112,7 +112,7 @@ public class ResourceRunner extends AbstractEngineRunnerBase implements CoreMetK * @see org.apache.oodt.cas.workflow.engine.runner.EngineRunner#hasOpenSlots(org.apache.oodt.cas.workflow.engine.processor.TaskProcessor) */ @Override - public boolean hasOpenSlots(TaskProcessor taskProcessor) throws Exception { + public boolean hasOpenSlots(TaskProcessor taskProcessor) { // TODO Auto-generated method stub return false; } http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/repository/PackagedWorkflowRepository.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/repository/PackagedWorkflowRepository.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/repository/PackagedWorkflowRepository.java index dd90b60..a93bb73 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/repository/PackagedWorkflowRepository.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/repository/PackagedWorkflowRepository.java @@ -390,7 +390,7 @@ public class PackagedWorkflowRepository implements WorkflowRepository { } } - private void computeWorkflowConditions() throws Exception { + private void computeWorkflowConditions() { if (this.workflows != null && this.workflows.values().size() > 0) { for (ParentChildWorkflow w : this.workflows.values()) { if (w.getConditions() != null && w.getConditions().size() > 0) { @@ -579,7 +579,7 @@ public class PackagedWorkflowRepository implements WorkflowRepository { } private void expandWorkflowTasksAndConditions(Graph graph, - Metadata staticMetadata) throws Exception { + Metadata staticMetadata) { if (graph.getExecutionType().equals("workflow") || graph.getExecutionType().equals("sequential") || graph.getExecutionType().equals("parallel")) { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/main/java/org/apache/oodt/cas/workflow/system/XmlRpcWorkflowManager.java ---------------------------------------------------------------------- diff --git a/workflow/src/main/java/org/apache/oodt/cas/workflow/system/XmlRpcWorkflowManager.java b/workflow/src/main/java/org/apache/oodt/cas/workflow/system/XmlRpcWorkflowManager.java index 8945059..2d4c9db 100644 --- a/workflow/src/main/java/org/apache/oodt/cas/workflow/system/XmlRpcWorkflowManager.java +++ b/workflow/src/main/java/org/apache/oodt/cas/workflow/system/XmlRpcWorkflowManager.java @@ -108,8 +108,7 @@ public class XmlRpcWorkflowManager { return false; } - public boolean refreshRepository() - throws RepositoryException { + public boolean refreshRepository() { repo = getWorkflowRepositoryFromProperty(); return true; } @@ -318,8 +317,7 @@ public class XmlRpcWorkflowManager { return false; } - public Hashtable getWorkflowInstanceById(String wInstId) - throws EngineException { + public Hashtable getWorkflowInstanceById(String wInstId) { WorkflowInstance inst = null; try { http://git-wip-us.apache.org/repos/asf/oodt/blob/ed6be8c7/workflow/src/test/java/org/apache/oodt/cas/workflow/repository/MockWorkflowRepository.java ---------------------------------------------------------------------- diff --git a/workflow/src/test/java/org/apache/oodt/cas/workflow/repository/MockWorkflowRepository.java b/workflow/src/test/java/org/apache/oodt/cas/workflow/repository/MockWorkflowRepository.java index 7d8bea5..1265f2f 100644 --- a/workflow/src/test/java/org/apache/oodt/cas/workflow/repository/MockWorkflowRepository.java +++ b/workflow/src/test/java/org/apache/oodt/cas/workflow/repository/MockWorkflowRepository.java @@ -272,8 +272,7 @@ public class MockWorkflowRepository implements WorkflowRepository { return tasks.get(taskId); } - public WorkflowTask getWorkflowTaskByName(String taskName) - throws RepositoryException { + public WorkflowTask getWorkflowTaskByName(String taskName) { Validate.notNull(taskName); for (WorkflowTask task : tasks.values()) {
