{"action":"created","comment":{"url":"https://api.github.com/repos/VoltDB/voltdb/pulls/comments/49784171","id":49784171,"diff_hunk":"@@ -1217,40 +1231,91 @@ private static Properties checkImportProcessorConfiguration(ImportConfigurationT\n                 is.close();\n             } catch (IOException ex) {\n             }\n-        } else {\n+        } else if (!alwaysBundle) {\n             //Not a URL try as a class\n             try {\n-                CatalogUtil.class.getClassLoader().loadClass(importBundleUrl);\n+                CatalogUtil.class.getClassLoader().loadClass(bundleUrl);\n                 modulePrefix = \"class|\";\n             }\n             catch (ClassNotFoundException ex2) {\n                 String msg =\n                         \"Import failed to configure, failed to load module by URL or classname provided\" +\n-                        \" import module: \" + importBundleUrl;\n+                        \" import module: \" + bundleUrl;\n                 hostLog.error(msg);\n                 throw new DeploymentCheckException(msg);\n             }\n+        } else {\n+            String msg =\n+                    \"Import failed to configure, failed to load module by URL or classname provided\" +\n+                    \" format module: \" + bundleUrl;\n+            hostLog.error(msg);\n+            throw new DeploymentCheckException(msg);\n         }\n-        if (importBundleUrl != null && importBundleUrl.trim().length() > 0) {\n-            processorProperties.setProperty(ImportDataProcessor.IMPORT_MODULE, modulePrefix + importBundleUrl);\n+        return (alwaysBundle ? bundleUrl : modulePrefix + bundleUrl);\n+    }\n+\n+    private static ImportConfiguration checkImportProcessorConfiguration(ImportConfigurationType importConfiguration) {\n+        String importBundleUrl = importConfiguration.getModule();\n+\n+        if (!importConfiguration.isEnabled()) {\n+            return null;\n+        }\n+        switch(importConfiguration.getType()) {\n+            case CUSTOM:\n+                break;\n+            case KAFKA:\n+                importBundleUrl = \"kafkastream.jar\";\n+                break;\n+            default:\n+                throw new DeploymentCheckException(\"Import Configuration type must be specified.\");\n         }\n \n-        List<PropertyType> configProperties = importConfiguration.getProperty();\n-        if (configProperties != null && ! configProperties.isEmpty()) {\n+        Properties moduleProp = new Properties();\n+        Properties formatterProp = new Properties();\n \n-            for( PropertyType configProp: configProperties) {\n-                String key = configProp.getName();\n-                String value = configProp.getValue();\n+        String formatBundle = importConfiguration.getFormat();\n+        if (formatBundle != null && formatBundle.trim().length() > 0) {\n+            if (formatBundle.equalsIgnoreCase(\"csv\") || formatBundle.equalsIgnoreCase(\"tsv\")) {","path":"src/frontend/org/voltdb/utils/CatalogUtil.java","position":142,"original_position":142,"commit_id":"df5a232c87ee884fbb4a97a613394fbc3f0e5cfd","original_commit_id":"df5a232c87ee884fbb4a97a613394fbc3f0e5cfd","user":{"login":"vtkstef","id":662716,"avatar_url":"https://avatars.githubusercontent.com/u/662716?v=3","gravatar_id":"","url":"https://api.github.com/users/vtkstef","html_url":"https://github.com/vtkstef","followers_url":"https://api.github.com/users/vtkstef/followers","following_url":"https://api.github.com/users/vtkstef/following{/other_user}","gists_url":"https://api.github.com/users/vtkstef/gists{/gist_id}","starred_url":"https://api.github.com/users/vtkstef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vtkstef/subscriptions","organizations_url":"https://api.github.com/users/vtkstef/orgs","repos_url":"https://api.github.com/users/vtkstef/repos","events_url":"https://api.github.com/users/vtkstef/events{/privacy}","received_events_url":"https://api.github.com/users/vtkstef/received_events","type":"User","site_admin":false},"body":"```java\r\nif (\"csv\".equalsIgnoreCase(formatBundle) || \"tsv\".equalsIgnoreCase(formatBundle))\r\n```","created_at":"2016-01-14T20:59:39Z","updated_at":"2016-01-14T20:59:39Z","html_url":"https://github.com/VoltDB/voltdb/pull/3129#discussion_r49784171","pull_request_url":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129","_links":{"self":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/comments/49784171"},"html":{"href":"https://github.com/VoltDB/voltdb/pull/3129#discussion_r49784171"},"pull_request":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129"}}},"pull_request":{"url":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129","id":55029417,"html_url":"https://github.com/VoltDB/voltdb/pull/3129","diff_url":"https://github.com/VoltDB/voltdb/pull/3129.diff","patch_url":"https://github.com/VoltDB/voltdb/pull/3129.patch","issue_url":"https://api.github.com/repos/VoltDB/voltdb/issues/3129","number":3129,"state":"open","locked":false,"title":"ENG-9481 add formatter to importer","user":{"login":"dweiss88","id":7559474,"avatar_url":"https://avatars.githubusercontent.com/u/7559474?v=3","gravatar_id":"","url":"https://api.github.com/users/dweiss88","html_url":"https://github.com/dweiss88","followers_url":"https://api.github.com/users/dweiss88/followers","following_url":"https://api.github.com/users/dweiss88/following{/other_user}","gists_url":"https://api.github.com/users/dweiss88/gists{/gist_id}","starred_url":"https://api.github.com/users/dweiss88/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dweiss88/subscriptions","organizations_url":"https://api.github.com/users/dweiss88/orgs","repos_url":"https://api.github.com/users/dweiss88/repos","events_url":"https://api.github.com/users/dweiss88/events{/privacy}","received_events_url":"https://api.github.com/users/dweiss88/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-01-04T22:13:38Z","updated_at":"2016-01-14T20:59:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":{"login":"manjujames","id":12613581,"avatar_url":"https://avatars.githubusercontent.com/u/12613581?v=3","gravatar_id":"","url":"https://api.github.com/users/manjujames","html_url":"https://github.com/manjujames","followers_url":"https://api.github.com/users/manjujames/followers","following_url":"https://api.github.com/users/manjujames/following{/other_user}","gists_url":"https://api.github.com/users/manjujames/gists{/gist_id}","starred_url":"https://api.github.com/users/manjujames/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/manjujames/subscriptions","organizations_url":"https://api.github.com/users/manjujames/orgs","repos_url":"https://api.github.com/users/manjujames/repos","events_url":"https://api.github.com/users/manjujames/events{/privacy}","received_events_url":"https://api.github.com/users/manjujames/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129/commits","review_comments_url":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129/comments","review_comment_url":"https://api.github.com/repos/VoltDB/voltdb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/VoltDB/voltdb/issues/3129/comments","statuses_url":"https://api.github.com/repos/VoltDB/voltdb/statuses/df5a232c87ee884fbb4a97a613394fbc3f0e5cfd","head":{"label":"VoltDB:ENG-9481","ref":"ENG-9481","sha":"df5a232c87ee884fbb4a97a613394fbc3f0e5cfd","user":{"login":"VoltDB","id":703910,"avatar_url":"https://avatars.githubusercontent.com/u/703910?v=3","gravatar_id":"","url":"https://api.github.com/users/VoltDB","html_url":"https://github.com/VoltDB","followers_url":"https://api.github.com/users/VoltDB/followers","following_url":"https://api.github.com/users/VoltDB/following{/other_user}","gists_url":"https://api.github.com/users/VoltDB/gists{/gist_id}","starred_url":"https://api.github.com/users/VoltDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VoltDB/subscriptions","organizations_url":"https://api.github.com/users/VoltDB/orgs","repos_url":"https://api.github.com/users/VoltDB/repos","events_url":"https://api.github.com/users/VoltDB/events{/privacy}","received_events_url":"https://api.github.com/users/VoltDB/received_events","type":"Organization","site_admin":false},"repo":{"id":2445970,"name":"voltdb","full_name":"VoltDB/voltdb","owner":{"login":"VoltDB","id":703910,"avatar_url":"https://avatars.githubusercontent.com/u/703910?v=3","gravatar_id":"","url":"https://api.github.com/users/VoltDB","html_url":"https://github.com/VoltDB","followers_url":"https://api.github.com/users/VoltDB/followers","following_url":"https://api.github.com/users/VoltDB/following{/other_user}","gists_url":"https://api.github.com/users/VoltDB/gists{/gist_id}","starred_url":"https://api.github.com/users/VoltDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VoltDB/subscriptions","organizations_url":"https://api.github.com/users/VoltDB/orgs","repos_url":"https://api.github.com/users/VoltDB/repos","events_url":"https://api.github.com/users/VoltDB/events{/privacy}","received_events_url":"https://api.github.com/users/VoltDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/VoltDB/voltdb","description":"VoltDB","fork":false,"url":"https://api.github.com/repos/VoltDB/voltdb","forks_url":"https://api.github.com/repos/VoltDB/voltdb/forks","keys_url":"https://api.github.com/repos/VoltDB/voltdb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/VoltDB/voltdb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/VoltDB/voltdb/teams","hooks_url":"https://api.github.com/repos/VoltDB/voltdb/hooks","issue_events_url":"https://api.github.com/repos/VoltDB/voltdb/issues/events{/number}","events_url":"https://api.github.com/repos/VoltDB/voltdb/events","assignees_url":"https://api.github.com/repos/VoltDB/voltdb/assignees{/user}","branches_url":"https://api.github.com/repos/VoltDB/voltdb/branches{/branch}","tags_url":"https://api.github.com/repos/VoltDB/voltdb/tags","blobs_url":"https://api.github.com/repos/VoltDB/voltdb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/VoltDB/voltdb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/VoltDB/voltdb/git/refs{/sha}","trees_url":"https://api.github.com/repos/VoltDB/voltdb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/VoltDB/voltdb/statuses/{sha}","languages_url":"https://api.github.com/repos/VoltDB/voltdb/languages","stargazers_url":"https://api.github.com/repos/VoltDB/voltdb/stargazers","contributors_url":"https://api.github.com/repos/VoltDB/voltdb/contributors","subscribers_url":"https://api.github.com/repos/VoltDB/voltdb/subscribers","subscription_url":"https://api.github.com/repos/VoltDB/voltdb/subscription","commits_url":"https://api.github.com/repos/VoltDB/voltdb/commits{/sha}","git_commits_url":"https://api.github.com/repos/VoltDB/voltdb/git/commits{/sha}","comments_url":"https://api.github.com/repos/VoltDB/voltdb/comments{/number}","issue_comment_url":"https://api.github.com/repos/VoltDB/voltdb/issues/comments{/number}","contents_url":"https://api.github.com/repos/VoltDB/voltdb/contents/{+path}","compare_url":"https://api.github.com/repos/VoltDB/voltdb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/VoltDB/voltdb/merges","archive_url":"https://api.github.com/repos/VoltDB/voltdb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/VoltDB/voltdb/downloads","issues_url":"https://api.github.com/repos/VoltDB/voltdb/issues{/number}","pulls_url":"https://api.github.com/repos/VoltDB/voltdb/pulls{/number}","milestones_url":"https://api.github.com/repos/VoltDB/voltdb/milestones{/number}","notifications_url":"https://api.github.com/repos/VoltDB/voltdb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/VoltDB/voltdb/labels{/name}","releases_url":"https://api.github.com/repos/VoltDB/voltdb/releases{/id}","created_at":"2011-09-23T18:46:12Z","updated_at":"2016-01-14T07:30:04Z","pushed_at":"2016-01-14T20:56:27Z","git_url":"git://github.com/VoltDB/voltdb.git","ssh_url":"git@github.com:VoltDB/voltdb.git","clone_url":"https://github.com/VoltDB/voltdb.git","svn_url":"https://github.com/VoltDB/voltdb","homepage":"http://community.voltdb.com/","size":524082,"stargazers_count":712,"watchers_count":712,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":212,"mirror_url":null,"open_issues_count":20,"forks":212,"open_issues":20,"watchers":712,"default_branch":"master"}},"base":{"label":"VoltDB:master","ref":"master","sha":"ff6f96852bbcdf5a9957479ba263aa5609075b10","user":{"login":"VoltDB","id":703910,"avatar_url":"https://avatars.githubusercontent.com/u/703910?v=3","gravatar_id":"","url":"https://api.github.com/users/VoltDB","html_url":"https://github.com/VoltDB","followers_url":"https://api.github.com/users/VoltDB/followers","following_url":"https://api.github.com/users/VoltDB/following{/other_user}","gists_url":"https://api.github.com/users/VoltDB/gists{/gist_id}","starred_url":"https://api.github.com/users/VoltDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VoltDB/subscriptions","organizations_url":"https://api.github.com/users/VoltDB/orgs","repos_url":"https://api.github.com/users/VoltDB/repos","events_url":"https://api.github.com/users/VoltDB/events{/privacy}","received_events_url":"https://api.github.com/users/VoltDB/received_events","type":"Organization","site_admin":false},"repo":{"id":2445970,"name":"voltdb","full_name":"VoltDB/voltdb","owner":{"login":"VoltDB","id":703910,"avatar_url":"https://avatars.githubusercontent.com/u/703910?v=3","gravatar_id":"","url":"https://api.github.com/users/VoltDB","html_url":"https://github.com/VoltDB","followers_url":"https://api.github.com/users/VoltDB/followers","following_url":"https://api.github.com/users/VoltDB/following{/other_user}","gists_url":"https://api.github.com/users/VoltDB/gists{/gist_id}","starred_url":"https://api.github.com/users/VoltDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VoltDB/subscriptions","organizations_url":"https://api.github.com/users/VoltDB/orgs","repos_url":"https://api.github.com/users/VoltDB/repos","events_url":"https://api.github.com/users/VoltDB/events{/privacy}","received_events_url":"https://api.github.com/users/VoltDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/VoltDB/voltdb","description":"VoltDB","fork":false,"url":"https://api.github.com/repos/VoltDB/voltdb","forks_url":"https://api.github.com/repos/VoltDB/voltdb/forks","keys_url":"https://api.github.com/repos/VoltDB/voltdb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/VoltDB/voltdb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/VoltDB/voltdb/teams","hooks_url":"https://api.github.com/repos/VoltDB/voltdb/hooks","issue_events_url":"https://api.github.com/repos/VoltDB/voltdb/issues/events{/number}","events_url":"https://api.github.com/repos/VoltDB/voltdb/events","assignees_url":"https://api.github.com/repos/VoltDB/voltdb/assignees{/user}","branches_url":"https://api.github.com/repos/VoltDB/voltdb/branches{/branch}","tags_url":"https://api.github.com/repos/VoltDB/voltdb/tags","blobs_url":"https://api.github.com/repos/VoltDB/voltdb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/VoltDB/voltdb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/VoltDB/voltdb/git/refs{/sha}","trees_url":"https://api.github.com/repos/VoltDB/voltdb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/VoltDB/voltdb/statuses/{sha}","languages_url":"https://api.github.com/repos/VoltDB/voltdb/languages","stargazers_url":"https://api.github.com/repos/VoltDB/voltdb/stargazers","contributors_url":"https://api.github.com/repos/VoltDB/voltdb/contributors","subscribers_url":"https://api.github.com/repos/VoltDB/voltdb/subscribers","subscription_url":"https://api.github.com/repos/VoltDB/voltdb/subscription","commits_url":"https://api.github.com/repos/VoltDB/voltdb/commits{/sha}","git_commits_url":"https://api.github.com/repos/VoltDB/voltdb/git/commits{/sha}","comments_url":"https://api.github.com/repos/VoltDB/voltdb/comments{/number}","issue_comment_url":"https://api.github.com/repos/VoltDB/voltdb/issues/comments{/number}","contents_url":"https://api.github.com/repos/VoltDB/voltdb/contents/{+path}","compare_url":"https://api.github.com/repos/VoltDB/voltdb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/VoltDB/voltdb/merges","archive_url":"https://api.github.com/repos/VoltDB/voltdb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/VoltDB/voltdb/downloads","issues_url":"https://api.github.com/repos/VoltDB/voltdb/issues{/number}","pulls_url":"https://api.github.com/repos/VoltDB/voltdb/pulls{/number}","milestones_url":"https://api.github.com/repos/VoltDB/voltdb/milestones{/number}","notifications_url":"https://api.github.com/repos/VoltDB/voltdb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/VoltDB/voltdb/labels{/name}","releases_url":"https://api.github.com/repos/VoltDB/voltdb/releases{/id}","created_at":"2011-09-23T18:46:12Z","updated_at":"2016-01-14T07:30:04Z","pushed_at":"2016-01-14T20:56:27Z","git_url":"git://github.com/VoltDB/voltdb.git","ssh_url":"git@github.com:VoltDB/voltdb.git","clone_url":"https://github.com/VoltDB/voltdb.git","svn_url":"https://github.com/VoltDB/voltdb","homepage":"http://community.voltdb.com/","size":524082,"stargazers_count":712,"watchers_count":712,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":212,"mirror_url":null,"open_issues_count":20,"forks":212,"open_issues":20,"watchers":712,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129"},"html":{"href":"https://github.com/VoltDB/voltdb/pull/3129"},"issue":{"href":"https://api.github.com/repos/VoltDB/voltdb/issues/3129"},"comments":{"href":"https://api.github.com/repos/VoltDB/voltdb/issues/3129/comments"},"review_comments":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129/comments"},"review_comment":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/VoltDB/voltdb/pulls/3129/commits"},"statuses":{"href":"https://api.github.com/repos/VoltDB/voltdb/statuses/df5a232c87ee884fbb4a97a613394fbc3f0e5cfd"}}}}