{"action":"created","comment":{"url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/comments/25935087","id":25935087,"diff_hunk":"@@ -106,8 +109,30 @@ public void init() {\n      * @param type type of the asset\n      */\n     public void addAsset(Resource resource, ResourceType type) {\n-        this.kbuilder.add(resource, type);\n-        if (this.kbuilder.hasErrors()) {            \n+        if (resource.getSourcePath() != null ) { \n+            String path = resource.getSourcePath();\n+           \n+            String typeStr = null;\n+            if( path.endsWith(\".csv\") ) { \n+                typeStr = DecisionTableInputType.CSV.toString();\n+            } else if( path.endsWith(\".xls\") ) { \n+                typeStr = DecisionTableInputType.XLS.toString();\n+            } \n+            \n+            if( typeStr != null ) { \n+                Properties prop = new Properties();\n+                prop.setProperty(ResourceTypeImpl.KIE_RESOURCE_CONF_CLASS, DecisionTableConfigurationImpl.class.getName());\n+                prop.setProperty(DecisionTableConfigurationImpl.DROOLS_DT_TYPE, typeStr);\n+                ResourceConfiguration conf = ResourceTypeImpl.fromProperties(prop);\n+                this.kbuilder.add(resource, type, conf);","path":"jbpm-runtime-manager/src/main/java/org/jbpm/runtime/manager/impl/SimpleRuntimeEnvironment.java","position":72,"original_position":72,"commit_id":"efd0cf09ce2466d91557f576324a578f574a71f7","original_commit_id":"efd0cf09ce2466d91557f576324a578f574a71f7","user":{"login":"mswiderski","id":904474,"avatar_url":"https://avatars.githubusercontent.com/u/904474?v=3","gravatar_id":"","url":"https://api.github.com/users/mswiderski","html_url":"https://github.com/mswiderski","followers_url":"https://api.github.com/users/mswiderski/followers","following_url":"https://api.github.com/users/mswiderski/following{/other_user}","gists_url":"https://api.github.com/users/mswiderski/gists{/gist_id}","starred_url":"https://api.github.com/users/mswiderski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mswiderski/subscriptions","organizations_url":"https://api.github.com/users/mswiderski/orgs","repos_url":"https://api.github.com/users/mswiderski/repos","events_url":"https://api.github.com/users/mswiderski/events{/privacy}","received_events_url":"https://api.github.com/users/mswiderski/received_events","type":"User","site_admin":false},"body":"I'll repeat my comment here as the other pr was closed:\r\ncan't we handle that in kbuilder itself? Reason I ask is that other users might run into exactly same issue when not using RuntimeManager API\r\n\r\nor this comment does not make sense at all... I might be missing some context..","created_at":"2015-03-06T09:57:23Z","updated_at":"2015-03-06T09:57:23Z","html_url":"https://github.com/droolsjbpm/jbpm/pull/239#discussion_r25935087","pull_request_url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239","_links":{"self":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/comments/25935087"},"html":{"href":"https://github.com/droolsjbpm/jbpm/pull/239#discussion_r25935087"},"pull_request":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239"}}},"pull_request":{"url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239","id":30627424,"html_url":"https://github.com/droolsjbpm/jbpm/pull/239","diff_url":"https://github.com/droolsjbpm/jbpm/pull/239.diff","patch_url":"https://github.com/droolsjbpm/jbpm/pull/239.patch","issue_url":"https://api.github.com/repos/droolsjbpm/jbpm/issues/239","number":239,"state":"open","locked":false,"title":"SWITCHYARD-2583, BZ-1199256 Switchyard component can not tell difference CSV/XLS","user":{"login":"mrietveld","id":783550,"avatar_url":"https://avatars.githubusercontent.com/u/783550?v=3","gravatar_id":"","url":"https://api.github.com/users/mrietveld","html_url":"https://github.com/mrietveld","followers_url":"https://api.github.com/users/mrietveld/followers","following_url":"https://api.github.com/users/mrietveld/following{/other_user}","gists_url":"https://api.github.com/users/mrietveld/gists{/gist_id}","starred_url":"https://api.github.com/users/mrietveld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrietveld/subscriptions","organizations_url":"https://api.github.com/users/mrietveld/orgs","repos_url":"https://api.github.com/users/mrietveld/repos","events_url":"https://api.github.com/users/mrietveld/events{/privacy}","received_events_url":"https://api.github.com/users/mrietveld/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-03-06T08:12:06Z","updated_at":"2015-03-06T09:57:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a7f8ad49eaec34dcae9be97d577e1877cc2f1c1a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239/commits","review_comments_url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239/comments","review_comment_url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/comments{/number}","comments_url":"https://api.github.com/repos/droolsjbpm/jbpm/issues/239/comments","statuses_url":"https://api.github.com/repos/droolsjbpm/jbpm/statuses/efd0cf09ce2466d91557f576324a578f574a71f7","head":{"label":"mrietveld:csv-xls-differentiation","ref":"csv-xls-differentiation","sha":"efd0cf09ce2466d91557f576324a578f574a71f7","user":{"login":"mrietveld","id":783550,"avatar_url":"https://avatars.githubusercontent.com/u/783550?v=3","gravatar_id":"","url":"https://api.github.com/users/mrietveld","html_url":"https://github.com/mrietveld","followers_url":"https://api.github.com/users/mrietveld/followers","following_url":"https://api.github.com/users/mrietveld/following{/other_user}","gists_url":"https://api.github.com/users/mrietveld/gists{/gist_id}","starred_url":"https://api.github.com/users/mrietveld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrietveld/subscriptions","organizations_url":"https://api.github.com/users/mrietveld/orgs","repos_url":"https://api.github.com/users/mrietveld/repos","events_url":"https://api.github.com/users/mrietveld/events{/privacy}","received_events_url":"https://api.github.com/users/mrietveld/received_events","type":"User","site_admin":false},"repo":{"id":1928804,"name":"jbpm","full_name":"mrietveld/jbpm","owner":{"login":"mrietveld","id":783550,"avatar_url":"https://avatars.githubusercontent.com/u/783550?v=3","gravatar_id":"","url":"https://api.github.com/users/mrietveld","html_url":"https://github.com/mrietveld","followers_url":"https://api.github.com/users/mrietveld/followers","following_url":"https://api.github.com/users/mrietveld/following{/other_user}","gists_url":"https://api.github.com/users/mrietveld/gists{/gist_id}","starred_url":"https://api.github.com/users/mrietveld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrietveld/subscriptions","organizations_url":"https://api.github.com/users/mrietveld/orgs","repos_url":"https://api.github.com/users/mrietveld/repos","events_url":"https://api.github.com/users/mrietveld/events{/privacy}","received_events_url":"https://api.github.com/users/mrietveld/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mrietveld/jbpm","description":"a Business Process Management (BPM) Suite","fork":true,"url":"https://api.github.com/repos/mrietveld/jbpm","forks_url":"https://api.github.com/repos/mrietveld/jbpm/forks","keys_url":"https://api.github.com/repos/mrietveld/jbpm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mrietveld/jbpm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mrietveld/jbpm/teams","hooks_url":"https://api.github.com/repos/mrietveld/jbpm/hooks","issue_events_url":"https://api.github.com/repos/mrietveld/jbpm/issues/events{/number}","events_url":"https://api.github.com/repos/mrietveld/jbpm/events","assignees_url":"https://api.github.com/repos/mrietveld/jbpm/assignees{/user}","branches_url":"https://api.github.com/repos/mrietveld/jbpm/branches{/branch}","tags_url":"https://api.github.com/repos/mrietveld/jbpm/tags","blobs_url":"https://api.github.com/repos/mrietveld/jbpm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mrietveld/jbpm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mrietveld/jbpm/git/refs{/sha}","trees_url":"https://api.github.com/repos/mrietveld/jbpm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mrietveld/jbpm/statuses/{sha}","languages_url":"https://api.github.com/repos/mrietveld/jbpm/languages","stargazers_url":"https://api.github.com/repos/mrietveld/jbpm/stargazers","contributors_url":"https://api.github.com/repos/mrietveld/jbpm/contributors","subscribers_url":"https://api.github.com/repos/mrietveld/jbpm/subscribers","subscription_url":"https://api.github.com/repos/mrietveld/jbpm/subscription","commits_url":"https://api.github.com/repos/mrietveld/jbpm/commits{/sha}","git_commits_url":"https://api.github.com/repos/mrietveld/jbpm/git/commits{/sha}","comments_url":"https://api.github.com/repos/mrietveld/jbpm/comments{/number}","issue_comment_url":"https://api.github.com/repos/mrietveld/jbpm/issues/comments{/number}","contents_url":"https://api.github.com/repos/mrietveld/jbpm/contents/{+path}","compare_url":"https://api.github.com/repos/mrietveld/jbpm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mrietveld/jbpm/merges","archive_url":"https://api.github.com/repos/mrietveld/jbpm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mrietveld/jbpm/downloads","issues_url":"https://api.github.com/repos/mrietveld/jbpm/issues{/number}","pulls_url":"https://api.github.com/repos/mrietveld/jbpm/pulls{/number}","milestones_url":"https://api.github.com/repos/mrietveld/jbpm/milestones{/number}","notifications_url":"https://api.github.com/repos/mrietveld/jbpm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mrietveld/jbpm/labels{/name}","releases_url":"https://api.github.com/repos/mrietveld/jbpm/releases{/id}","created_at":"2011-06-21T11:47:06Z","updated_at":"2014-07-24T14:39:58Z","pushed_at":"2015-03-06T08:10:47Z","git_url":"git://github.com/mrietveld/jbpm.git","ssh_url":"git@github.com:mrietveld/jbpm.git","clone_url":"https://github.com/mrietveld/jbpm.git","svn_url":"https://github.com/mrietveld/jbpm","homepage":"http://www.jboss.org/jbpm","size":35929,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"droolsjbpm:master","ref":"master","sha":"8124e78726a25c2ba4979034392536be8a54275d","user":{"login":"droolsjbpm","id":517980,"avatar_url":"https://avatars.githubusercontent.com/u/517980?v=3","gravatar_id":"","url":"https://api.github.com/users/droolsjbpm","html_url":"https://github.com/droolsjbpm","followers_url":"https://api.github.com/users/droolsjbpm/followers","following_url":"https://api.github.com/users/droolsjbpm/following{/other_user}","gists_url":"https://api.github.com/users/droolsjbpm/gists{/gist_id}","starred_url":"https://api.github.com/users/droolsjbpm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/droolsjbpm/subscriptions","organizations_url":"https://api.github.com/users/droolsjbpm/orgs","repos_url":"https://api.github.com/users/droolsjbpm/repos","events_url":"https://api.github.com/users/droolsjbpm/events{/privacy}","received_events_url":"https://api.github.com/users/droolsjbpm/received_events","type":"Organization","site_admin":false},"repo":{"id":930571,"name":"jbpm","full_name":"droolsjbpm/jbpm","owner":{"login":"droolsjbpm","id":517980,"avatar_url":"https://avatars.githubusercontent.com/u/517980?v=3","gravatar_id":"","url":"https://api.github.com/users/droolsjbpm","html_url":"https://github.com/droolsjbpm","followers_url":"https://api.github.com/users/droolsjbpm/followers","following_url":"https://api.github.com/users/droolsjbpm/following{/other_user}","gists_url":"https://api.github.com/users/droolsjbpm/gists{/gist_id}","starred_url":"https://api.github.com/users/droolsjbpm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/droolsjbpm/subscriptions","organizations_url":"https://api.github.com/users/droolsjbpm/orgs","repos_url":"https://api.github.com/users/droolsjbpm/repos","events_url":"https://api.github.com/users/droolsjbpm/events{/privacy}","received_events_url":"https://api.github.com/users/droolsjbpm/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/droolsjbpm/jbpm","description":"a Business Process Management (BPM) Suite","fork":false,"url":"https://api.github.com/repos/droolsjbpm/jbpm","forks_url":"https://api.github.com/repos/droolsjbpm/jbpm/forks","keys_url":"https://api.github.com/repos/droolsjbpm/jbpm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/droolsjbpm/jbpm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/droolsjbpm/jbpm/teams","hooks_url":"https://api.github.com/repos/droolsjbpm/jbpm/hooks","issue_events_url":"https://api.github.com/repos/droolsjbpm/jbpm/issues/events{/number}","events_url":"https://api.github.com/repos/droolsjbpm/jbpm/events","assignees_url":"https://api.github.com/repos/droolsjbpm/jbpm/assignees{/user}","branches_url":"https://api.github.com/repos/droolsjbpm/jbpm/branches{/branch}","tags_url":"https://api.github.com/repos/droolsjbpm/jbpm/tags","blobs_url":"https://api.github.com/repos/droolsjbpm/jbpm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/droolsjbpm/jbpm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/droolsjbpm/jbpm/git/refs{/sha}","trees_url":"https://api.github.com/repos/droolsjbpm/jbpm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/droolsjbpm/jbpm/statuses/{sha}","languages_url":"https://api.github.com/repos/droolsjbpm/jbpm/languages","stargazers_url":"https://api.github.com/repos/droolsjbpm/jbpm/stargazers","contributors_url":"https://api.github.com/repos/droolsjbpm/jbpm/contributors","subscribers_url":"https://api.github.com/repos/droolsjbpm/jbpm/subscribers","subscription_url":"https://api.github.com/repos/droolsjbpm/jbpm/subscription","commits_url":"https://api.github.com/repos/droolsjbpm/jbpm/commits{/sha}","git_commits_url":"https://api.github.com/repos/droolsjbpm/jbpm/git/commits{/sha}","comments_url":"https://api.github.com/repos/droolsjbpm/jbpm/comments{/number}","issue_comment_url":"https://api.github.com/repos/droolsjbpm/jbpm/issues/comments{/number}","contents_url":"https://api.github.com/repos/droolsjbpm/jbpm/contents/{+path}","compare_url":"https://api.github.com/repos/droolsjbpm/jbpm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/droolsjbpm/jbpm/merges","archive_url":"https://api.github.com/repos/droolsjbpm/jbpm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/droolsjbpm/jbpm/downloads","issues_url":"https://api.github.com/repos/droolsjbpm/jbpm/issues{/number}","pulls_url":"https://api.github.com/repos/droolsjbpm/jbpm/pulls{/number}","milestones_url":"https://api.github.com/repos/droolsjbpm/jbpm/milestones{/number}","notifications_url":"https://api.github.com/repos/droolsjbpm/jbpm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/droolsjbpm/jbpm/labels{/name}","releases_url":"https://api.github.com/repos/droolsjbpm/jbpm/releases{/id}","created_at":"2010-09-22T13:19:52Z","updated_at":"2015-03-03T17:49:34Z","pushed_at":"2015-03-05T16:11:49Z","git_url":"git://github.com/droolsjbpm/jbpm.git","ssh_url":"git@github.com:droolsjbpm/jbpm.git","clone_url":"https://github.com/droolsjbpm/jbpm.git","svn_url":"https://github.com/droolsjbpm/jbpm","homepage":"http://www.jbpm.org","size":66184,"stargazers_count":344,"watchers_count":344,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":489,"mirror_url":null,"open_issues_count":10,"forks":489,"open_issues":10,"watchers":344,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239"},"html":{"href":"https://github.com/droolsjbpm/jbpm/pull/239"},"issue":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/issues/239"},"comments":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/issues/239/comments"},"review_comments":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239/comments"},"review_comment":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/pulls/239/commits"},"statuses":{"href":"https://api.github.com/repos/droolsjbpm/jbpm/statuses/efd0cf09ce2466d91557f576324a578f574a71f7"}}}}