[M] Change in asterixdb[master]: [ASTERIXDB-3820][FUN] Require the dimension in isvector

2026-10-01 Thread AsterixDB Code Review
Attention is currently required from: Hongyu Shi.

Anon. E. Moose #1000171 has posted comments on this change by Hongyu Shi. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21957?usp=email )

Change subject: [ASTERIXDB-3820][FUN] Require the dimension in isvector
..


Patch Set 1: Verified-1

https://server.jenkins.couchbase.com/job/asterixdb-restricted-branch-check/7326/artifact/restriction/restricted.html
 : BRANCH RESTRICTED (Please check URL for more information)


--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21957?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://asterix-gerrit.ics.uci.edu/settings?usp=email

Gerrit-MessageType: comment
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Change-Id: I9c430dceeda94efc9ec57883f6ac91739a4f4993
Gerrit-Change-Number: 21957
Gerrit-PatchSet: 1
Gerrit-Owner: Hongyu Shi 
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Attention: Hongyu Shi 
Gerrit-Comment-Date: Thu, 01 Oct 2026 08:26:29 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes


[M] Change in asterixdb[master]: [ASTERIXDB-3820][FUN] Require the dimension in isvector

2026-10-01 Thread AsterixDB Code Review
Attention is currently required from: Hongyu Shi.

Anon. E. Moose #1000171 has posted comments on this change by Hongyu Shi. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21957?usp=email )

Change subject: [ASTERIXDB-3820][FUN] Require the dimension in isvector
..


Patch Set 1:

Analytics Compatibility Compilation Successful
https://cbjenkins.page.link/1GKHVUAdYAyGqUAb8 : SUCCESS


--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21957?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://asterix-gerrit.ics.uci.edu/settings?usp=email

Gerrit-MessageType: comment
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Change-Id: I9c430dceeda94efc9ec57883f6ac91739a4f4993
Gerrit-Change-Number: 21957
Gerrit-PatchSet: 1
Gerrit-Owner: Hongyu Shi 
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Attention: Hongyu Shi 
Gerrit-Comment-Date: Thu, 01 Oct 2026 08:33:22 +
Gerrit-HasComments: No
Gerrit-Has-Labels: No


[M] Change in asterixdb[master]: [ASTERIXDB-3820][FUN] Require the dimension in isvector

2026-10-01 Thread AsterixDB Code Review
>From Hongyu Shi :

Hongyu Shi has uploaded this change for review. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21957?usp=email )


Change subject: [ASTERIXDB-3820][FUN] Require the dimension in isvector
..

[ASTERIXDB-3820][FUN] Require the dimension in isvector

- user model changes: yes
- storage format changes: no
- interface changes: no

Details:
isvector(v) is no longer a user-facing function; callers state the
dimension, since a vector index always has one. The one-argument
form stays registered, privately, for internal use.

A dimension that is not a positive integer gives null and a warning,
as isbitset does.

Generated-by: Claude Opus 5.5 
Change-Id: I9c430dceeda94efc9ec57883f6ac91739a4f4993
---
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.1.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.2.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.3.query.sqlpp
M 
asterixdb/asterix-app/src/test/resources/runtimets/results/types/isvector/isvector.1.adm
A 
asterixdb/asterix-app/src/test/resources/runtimets/results/types/isvector/isvector.3.adm
M asterixdb/asterix-app/src/test/resources/runtimets/sqlpp_queries.xml
M 
asterixdb/asterix-om/src/main/java/org/apache/asterix/om/functions/BuiltinFunctions.java
M 
asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/evaluators/functions/IsVectorDescriptor.java
8 files changed, 89 insertions(+), 16 deletions(-)



  git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb 
refs/changes/57/21957/1

diff --git 
a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.1.query.sqlpp
 
b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.1.query.sqlpp
index 6450c2c..6f20b55 100644
--- 
a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.1.query.sqlpp
+++ 
b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.1.query.sqlpp
@@ -17,10 +17,9 @@
  * under the License.
  */

-// isvector(v) and isvector(v, dimension). Null and missing propagate as for 
the rest of the
-// is_* family, so "k" is null and "l" is absent rather than both being false.
+// isvector(v, dimension). Null and missing propagate as for the rest of the 
is_* family, so "k" is
+// null and "l" is absent rather than both being false.
 {
-  "a_ok":  isvector([0.2, 0.1, 0.4, 0.3]),
   "b_ok_dim":  isvector([0.2, 0.1, 0.4, 0.3], 4),
   "c_mixed":   isvector([0.2, 0.1, "s", 0.3], 4),
   "d_all_string":  isvector(["a", "b", "c", "d"], 4),
@@ -28,10 +27,9 @@
   "f_nested":  isvector([0.2, 0.1, [1], 0.3], 4),
   "g_short":   isvector([0.2, 0.1, 0.3], 4),
   "h_empty_dim":   isvector([], 4),
-  "i_empty_nodim": isvector([]),
-  "j_not_list":isvector("x"),
-  "k_null":isvector(null),
-  "l_missing": isvector(missing),
+  "j_not_list":isvector("x", 4),
+  "k_null":isvector(null, 4),
+  "l_missing": isvector(missing, 4),
   "m_integers":isvector([1, 2, 3], 3),
   "n_underscore":  is_vector([1, 2, 3], 3)
 };
diff --git 
a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.2.query.sqlpp
 
b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.2.query.sqlpp
new file mode 100644
index 000..1df8262
--- /dev/null
+++ 
b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.2.query.sqlpp
@@ -0,0 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+// The dimension is required: the one-argument form is not a user-facing 
function.
+isvector([0.2, 0.1, 0.4, 0.3]);
diff --git 
a/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.3.query.sqlpp
 
b/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/types/isvector/isvector.3.query.sqlpp
new file mode 100644
index 000..25a06e3
--- /dev/null
+++