Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CASSANDRA-19556 Guardrail to block DDL/DCL queries (4.1) #3248

Open
wants to merge 2 commits into
base: cassandra-4.1
Choose a base branch
from

Conversation

Yukei7
Copy link

@Yukei7 Yukei7 commented Apr 11, 2024

Guardrail to block DDL/DCL queries

Guardrail to block DDL/DCL queries

patch by Yuqi Yan; reviewed by <Reviewers> for CASSANDRA-19556

The Cassandra Jira

@Yukei7 Yukei7 changed the title Guardrail to block DDL/DCL queries (4.1) CASSANDRA-19556 Guardrail to block DDL/DCL queries (4.1) Apr 11, 2024
@smiklosovic
Copy link
Contributor

it doesnt compile

checkstyle:
[mkdir] Created dir: /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/build/checkstyle
[checkstyle] Running Checkstyle 8.40 on 2134 files
[checkstyle] [ERROR] /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/src/java/org/apache/cassandra/cql3/statements/schema/AlterSchemaStatement.java:29:8: Unused import - org.apache.cassandra.db.guardrails.Guardrails. [UnusedImports]
[checkstyle] [ERROR] /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/src/java/org/apache/cassandra/db/guardrails/Guardrails.java:21:8: Unused import - java.lang.reflect.Field. [UnusedImports]

I did ant realclean && ant artifacts

@Yukei7
Copy link
Author

Yukei7 commented Apr 15, 2024

it doesnt compile

checkstyle: [mkdir] Created dir: /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/build/checkstyle [checkstyle] Running Checkstyle 8.40 on 2134 files [checkstyle] [ERROR] /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/src/java/org/apache/cassandra/cql3/statements/schema/AlterSchemaStatement.java:29:8: Unused import - org.apache.cassandra.db.guardrails.Guardrails. [UnusedImports] [checkstyle] [ERROR] /home/fermat/dev/cassandra/cassandra-instaclustr/cassandra-4.1/src/java/org/apache/cassandra/db/guardrails/Guardrails.java:21:8: Unused import - java.lang.reflect.Field. [UnusedImports]

I did ant realclean && ant artifacts

Removed those unused import.

I did ant realclean && ant artifacts but it BUILD SUCCESSFUL and didn't complain about this. Not sure why checkstyle was not working on my side

@smiklosovic
Copy link
Contributor

@Yukei7 because you probably compiled it on Java 17 and I think that checkstyle is turned off there. I think you should be sure you develop against 11.

@smiklosovic
Copy link
Contributor

aha wait, this is 4.1 branch which is still on Java 8 .... well, I dont have clue then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants