<< Back to previous view

[JDBC-15] resultset-seq uses structmap which has been deprecated Created: 13/Aug/11  Updated: 01/Jun/16  Resolved: 16/Oct/11

Status: Closed
Project: java.jdbc
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Major
Reporter: Sean Corfield Assignee: Sean Corfield
Resolution: Completed Votes: 0
Labels: None


structmap has been deprecated. The open question is whether to replace its use with record or regular map (I'd expect the latter would be less surprising?).

Comment by Sean Corfield [ 12/Oct/11 4:29 PM ]

See JDBC-3 for some background on this.

Comment by Sean Corfield [ 16/Oct/11 3:41 PM ]

The way resultset-seq uses create-struct and struct doesn't seem to leverage any inherent functionality of structmaps except perhaps some vague guarantee of ordering of columns in rows. Replacing the create-struct / struct calls with

(into {} (map vector keys (row-values)))

maintains the order up to 16 columns (PersistentArrayMap) so that seems a reasonable compromise.

I'm not sure that preserving order is something that should be documented or supported?

Comment by Sean Corfield [ 16/Oct/11 4:32 PM ]

No longer uses structmap. Attempts to provide column order (up to 16 columns) but don't rely on that... it was never documented as a guarantee!

Generated at Mon Jan 22 06:53:49 CST 2018 using JIRA 4.4#649-r158309.