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

Failure to support deeply nested structured datatypes by REST API (in SGv2) #2061

Closed
tatu-at-datastax opened this issue Sep 9, 2022 · 4 comments
Assignees
Milestone

Comments

@tatu-at-datastax
Copy link
Collaborator

Data stored in a table defined as:

CREATE TABLE test_keyspace.conv_timeline (
  conv_id bigint PRIMARY KEY,
  data map<text, frozen<list<frozen<tuple<double, double>>>>>
)

seems to trigger a failure with stack trace like:

java.lang.IllegalArgumentException: Internal problem: failed to create converter for column #2/2 ('data'): Invalid/unsupported ColumnSpec TypeSpec SPEC_NOT_SET for column 'data'

at io.stargate.sgv2.restsvc.grpc.BridgeProtoValueConverters.fromProtoConverter(BridgeProtoValueConverters.java:41)
at io.stargate.sgv2.restsvc.resources.ResourceBase.convertRows(ResourceBase.java:155)
at io.stargate.sgv2.restsvc.resources.ResourceBase.toHttpResponse(ResourceBase.java:148)
at io.stargate.sgv2.restsvc.resources.ResourceBase.fetchRows(ResourceBase.java:140)
at io.stargate.sgv2.restsvc.resources.Sgv2RowsResourceImpl.getAllRows(Sgv2RowsResourceImpl.java:195)

with Stargate V2 REST API implementation. Same likely works in Stargate V1 REST; would make sense to add test for both if feasible.

@jmon-ds
Copy link

jmon-ds commented Sep 9, 2022

A user tried testing again recently and got the same error on 09/07/2022. He also showed the same error on many other tables too with diff data while when he queried the same data via CQL it worked just fine. He confirmed the same queries worked for Java applications. It's just the REST API (both swagger & curl calls failed).

We (two DataStax engineers) had tried but can't reproduce it in our local environments.

@tatu-at-datastax
Copy link
Collaborator Author

yes, this would only be for REST service. As to local environments, this would affect builds from v2.0.0, not master (Stargate V2 vs V1), so that could explain the difference.

@tatu-at-datastax
Copy link
Collaborator Author

Found the issue, verifying the fix (see #2063).

@tatu-at-datastax tatu-at-datastax changed the title Possible failure to support deeply nested datatypes by REST API (in SGv2) Failure to support deeply nested structured datatypes by REST API (in SGv2) Sep 12, 2022
@tatu-at-datastax tatu-at-datastax added this to the 1.0.65 milestone Sep 12, 2022
@tatu-at-datastax
Copy link
Collaborator Author

Fix merged after successful test runs, closing.

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

No branches or pull requests

2 participants