[jira] [Comment Edited] (IGNITE-6448) Select * doesn't return new field name after concurrent ALTER TABLE

2017-09-21 Thread Taras Ledkov (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-6448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16173088#comment-16173088
 ] 

Taras Ledkov edited comment on IGNITE-6448 at 9/21/17 8:14 AM:
---

[Tests 
results|https://ci.ignite.apache.org/project.html?projectId=Ignite20Tests=projectOverview_Ignite20Tests=pull%2F2702%2Fhead]
 are OK with me.
[~vozerov], please review the patch.


was (Author: tledkov-gridgain):
Waits for [tests 
results|https://ci.ignite.apache.org/project.html?projectId=Ignite20Tests=projectOverview_Ignite20Tests=pull%2F2702%2Fhead].

> Select * doesn't return new field name after concurrent ALTER TABLE 
> 
>
> Key: IGNITE-6448
> URL: https://issues.apache.org/jira/browse/IGNITE-6448
> Project: Ignite
>  Issue Type: Bug
>  Components: sql
>Affects Versions: 2.1
>Reporter: Ilya Suntsov
>Assignee: Taras Ledkov
>Priority: Critical
> Fix For: 2.3
>
>
> Steps for reproduce:
> 1. Start 3 nodes
> 2. Execute 
> {noformat}CREATE TABLE person (id LONG, name VARCHAR, city_id LONG, PRIMARY 
> KEY (id, city_id)) {noformat}
> to create table Person
> 3. Connect to grid via sqlline (https://github.com/julianhyde/sqlline)
> {noformat}./sqlline -d org.apache.ignite.IgniteJdbcThinDriver --color=true 
> --verbose=true --showWarnings=true --showNestedErrs=true -u 
> jdbc:ignite:thin://127.0.0.1/{noformat}
> 4. Create one more connection {noformat}!connect 
> jdbc:ignite:thin://127.0.0.1/ {noformat}
> 5. Execute ALTER TABLE for both connections {noformat} !all alter table 
> person add field1 varchar;{noformat}
> Result:
> 1. Got exception on coordinator:
> {noformat}[10:59:15,805][SEVERE][client-connector-#55%null%][JdbcRequestHandler]
>  Failed to execute SQL query [reqId=0, req=JdbcQueryExecuteRequest 
> [schemaName=PUBLIC, pageSize=1024, maxRows=0, sqlQry=alter table person add 
> field1 varchar, args=[], stmtType=ANY_STATEMENT_TYPE]]
> class org.apache.ignite.internal.processors.query.IgniteSQLException: Column 
> already exists: FIELD1
>   at 
> org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.convert(DdlStatementsProcessor.java:329)
>   at 
> org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.runDdlStatement(DdlStatementsProcessor.java:273)
>   at 
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.queryDistributedSqlFields(IgniteH2Indexing.java:1383)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor$6.applyx(GridQueryProcessor.java:1918)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor$6.applyx(GridQueryProcessor.java:1914)
>   at 
> org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2396)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFieldsNoCache(GridQueryProcessor.java:1922)
>   at 
> org.apache.ignite.internal.processors.odbc.jdbc.JdbcRequestHandler.executeQuery(JdbcRequestHandler.java:286)
>   at 
> org.apache.ignite.internal.processors.odbc.jdbc.JdbcRequestHandler.handle(JdbcRequestHandler.java:149)
>   at 
> org.apache.ignite.internal.processors.odbc.ClientListenerNioListener.onMessage(ClientListenerNioListener.java:141)
>   at 
> org.apache.ignite.internal.processors.odbc.ClientListenerNioListener.onMessage(ClientListenerNioListener.java:40)
>   at 
> org.apache.ignite.internal.util.nio.GridNioFilterChain$TailFilter.onMessageReceived(GridNioFilterChain.java:279)
>   at 
> org.apache.ignite.internal.util.nio.GridNioFilterAdapter.proceedMessageReceived(GridNioFilterAdapter.java:109)
>   at 
> org.apache.ignite.internal.util.nio.GridNioAsyncNotifyFilter$3.body(GridNioAsyncNotifyFilter.java:97)
>   at 
> org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:110)
>   at 
> org.apache.ignite.internal.util.worker.GridWorkerPool$1.run(GridWorkerPool.java:70)
>   at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>   at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>   at java.lang.Thread.run(Thread.java:745)
> {noformat}
> 2. When I try to get all data from Person:
> {noformat}select * from person;{noformat}
> I get the table without new field but if try to get only this field from 
> table it works.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Comment Edited] (IGNITE-6448) Select * doesn't return new field name after concurrent ALTER TABLE

2017-09-20 Thread Ilya Suntsov (JIRA)

[ 
https://issues.apache.org/jira/browse/IGNITE-6448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16172917#comment-16172917
 ] 

Ilya Suntsov edited comment on IGNITE-6448 at 9/20/17 8:48 AM:
---

I observed the same behavior also for non concurrent ALTER TABLE


was (Author: ustas):
I obsed the same behavior also for non concurrent ALTER TABLE

> Select * doesn't return new field name after concurrent ALTER TABLE 
> 
>
> Key: IGNITE-6448
> URL: https://issues.apache.org/jira/browse/IGNITE-6448
> Project: Ignite
>  Issue Type: Bug
>  Components: sql
>Affects Versions: 2.1
>Reporter: Ilya Suntsov
>Assignee: Taras Ledkov
>Priority: Critical
> Fix For: 2.3
>
>
> Steps for reproduce:
> 1. Start 3 nodes
> 2. Execute 
> {noformat}CREATE TABLE person (id LONG, name VARCHAR, city_id LONG, PRIMARY 
> KEY (id, city_id)) {noformat}
> to create table Person
> 3. Connect to grid via sqlline (https://github.com/julianhyde/sqlline)
> {noformat}./sqlline -d org.apache.ignite.IgniteJdbcThinDriver --color=true 
> --verbose=true --showWarnings=true --showNestedErrs=true -u 
> jdbc:ignite:thin://127.0.0.1/{noformat}
> 4. Create one more connection {noformat}!connect 
> jdbc:ignite:thin://127.0.0.1/ {noformat}
> 5. Execute ALTER TABLE for both connections {noformat} !all alter table 
> person add field1 varchar;{noformat}
> Result:
> 1. Got exception on coordinator:
> {noformat}[10:59:15,805][SEVERE][client-connector-#55%null%][JdbcRequestHandler]
>  Failed to execute SQL query [reqId=0, req=JdbcQueryExecuteRequest 
> [schemaName=PUBLIC, pageSize=1024, maxRows=0, sqlQry=alter table person add 
> field1 varchar, args=[], stmtType=ANY_STATEMENT_TYPE]]
> class org.apache.ignite.internal.processors.query.IgniteSQLException: Column 
> already exists: FIELD1
>   at 
> org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.convert(DdlStatementsProcessor.java:329)
>   at 
> org.apache.ignite.internal.processors.query.h2.ddl.DdlStatementsProcessor.runDdlStatement(DdlStatementsProcessor.java:273)
>   at 
> org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.queryDistributedSqlFields(IgniteH2Indexing.java:1383)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor$6.applyx(GridQueryProcessor.java:1918)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor$6.applyx(GridQueryProcessor.java:1914)
>   at 
> org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2396)
>   at 
> org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFieldsNoCache(GridQueryProcessor.java:1922)
>   at 
> org.apache.ignite.internal.processors.odbc.jdbc.JdbcRequestHandler.executeQuery(JdbcRequestHandler.java:286)
>   at 
> org.apache.ignite.internal.processors.odbc.jdbc.JdbcRequestHandler.handle(JdbcRequestHandler.java:149)
>   at 
> org.apache.ignite.internal.processors.odbc.ClientListenerNioListener.onMessage(ClientListenerNioListener.java:141)
>   at 
> org.apache.ignite.internal.processors.odbc.ClientListenerNioListener.onMessage(ClientListenerNioListener.java:40)
>   at 
> org.apache.ignite.internal.util.nio.GridNioFilterChain$TailFilter.onMessageReceived(GridNioFilterChain.java:279)
>   at 
> org.apache.ignite.internal.util.nio.GridNioFilterAdapter.proceedMessageReceived(GridNioFilterAdapter.java:109)
>   at 
> org.apache.ignite.internal.util.nio.GridNioAsyncNotifyFilter$3.body(GridNioAsyncNotifyFilter.java:97)
>   at 
> org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:110)
>   at 
> org.apache.ignite.internal.util.worker.GridWorkerPool$1.run(GridWorkerPool.java:70)
>   at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>   at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>   at java.lang.Thread.run(Thread.java:745)
> {noformat}
> 2. When I try to get all data from Person:
> {noformat}select * from person;{noformat}
> I get the table without new field but if try to get only this field from 
> table it works.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)