[
https://issues.apache.org/jira/browse/TAJO-1616?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14597635#comment-14597635
]
ASF GitHub Bot commented on TAJO-1616:
--------------------------------------
Github user jihoonson commented on a diff in the pull request:
https://github.com/apache/tajo/pull/602#discussion_r33039748
--- Diff:
tajo-core/src/main/java/org/apache/tajo/master/exec/QueryExecutor.java ---
@@ -436,14 +476,17 @@ public void executeDistributedQuery(QueryContext
queryContext, Session session,
SubmitQueryResponse.Builder
responseBuilder) throws Exception {
LogicalRootNode rootNode = plan.getRootBlock().getRoot();
- String storeType = PlannerUtil.getStoreType(plan);
- if (storeType != null) {
- Tablespace sm =
TableSpaceManager.getStorageManager(context.getConf(), storeType);
- StorageProperty storageProperty = sm.getStorageProperty();
- if (!storageProperty.isSupportsInsertInto()) {
+ TableDesc tableDesc = PlannerUtil.getTableDesc(catalog,
plan.getRootBlock().getRoot());
+ if (tableDesc != null) {
+
+ Tablespace space = TablespaceManager.get(tableDesc.getUri()).get();
+ FormatProperty formatProperty =
space.getFormatProperty(tableDesc.getMeta());
+
+ if (!formatProperty.isInsertable()) {
throw new VerifyException("Inserting into non-file storage is not
supported.");
--- End diff --
It would be better if the storage name is printed with this exception.
> Implement TablespaceManager to load Tablespaces
> -----------------------------------------------
>
> Key: TAJO-1616
> URL: https://issues.apache.org/jira/browse/TAJO-1616
> Project: Tajo
> Issue Type: Sub-task
> Components: storage
> Reporter: Hyunsik Choi
> Assignee: Hyunsik Choi
> Fix For: 0.11.0
>
>
> TablespaceManager should load Tablespace according to storage-default.json
> and storage-site.json.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)