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

EmbeddedDatabaseBuilder should load data.sql instead of test-data.sql by default [SPR-6020] #10689

Closed
spring-projects-issues opened this issue Aug 17, 2009 · 1 comment
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: enhancement A general enhancement
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

Sam Brannen opened SPR-6020 and commented

The embedded database support in the new jdbc XML namespace is intended to be generic (i.e., not specific to testing), and as such, it resides in the org.springframework.jdbc bundle instead of the test bundle.

By default (i.e., in EmbeddedDatabaseBuilder.buildDefault()), the DDL script is loaded from schema.xml. In contrast, the default name of the DML script is test-data.sql. This is inconsistent and misleading. Consider, for example, that an embedded database is used in a simple application which loads an initial data set (e.g., reference data). Calling this file test-data.sql in such a scenario would be inappropriate.

My recommendation is to rename the default from test-data.sql to data.sql.


Affects: 3.0 M4

Referenced from: commits e56aa91, c802253

@spring-projects-issues
Copy link
Collaborator Author

Juergen Hoeller commented

Good point. I've renamed this to "data.sql" as suggested.

Juergen

@spring-projects-issues spring-projects-issues added type: enhancement A general enhancement in: core Issues in core modules (aop, beans, core, context, expression) labels Jan 11, 2019
@spring-projects-issues spring-projects-issues added this to the 3.0 RC1 milestone Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants