Description
ArcadeDB version
- Version: 26.8.1
- Build:
727aa4568cdface314ee15cd242f71d6299b2b0c - Standalone server
- Reproduced through the HTTP SQL API; the original application failure was observed through Bolt/OpenCypher.
Description
Dropping a property that previously had a non-null DEFAULT removes the property from the public schema, but appears to leave its name in the type's internal default-property cache. Subsequent record creation for that type fails in LocalDatabase.setDefaultValues() because getPolymorphicProperty() cannot resolve the dropped property.
This was first observed on an edge type after a property had been created in the ArcadeDB console and later deleted.
Minimal reproduction
Run these commands in a fresh database:
CREATE VERTEX TYPE TestVertex;
CREATE PROPERTY TestVertex.id STRING;
CREATE INDEX ON TestVertex (id) UNIQUE;
CREATE EDGE TYPE TestEdge;
CREATE PROPERTY TestEdge.obsolete STRING;
ALTER PROPERTY TestEdge.obsolete DEFAULT 'legacy';
DROP PROPERTY TestEdge.obsolete;
CREATE VERTEX TestVertex SET id = 'source';
CREATE VERTEX TestVertex SET id = 'target';
CREATE EDGE TestEdge
FROM (SELECT FROM TestVertex WHERE id = 'source')
TO (SELECT FROM TestVertex WHERE id = 'target');Actual behavior
The final command fails during transaction commit:
com.arcadedb.exception.SchemaException:
Cannot find property 'obsolete' in type 'TestEdge'
at com.arcadedb.schema.DocumentType.getPolymorphicProperty(DocumentType.java:237)
at com.arcadedb.database.LocalDatabase.setDefaultValues(LocalDatabase.java:2653)
at com.arcadedb.database.LocalDatabase.createRecordNoLock(LocalDatabase.java:1026)
...
After DROP PROPERTY, the schema query below shows that obsolete is no longer a declared property:
SELECT name, properties FROM schema:types WHERE name = 'TestEdge';Expected behavior
The edge is created successfully. A dropped property must no longer participate in default-value processing.
Suspected cause
In this build, LocalDocumentType.dropProperty() removes the property from the declared property map, but does not appear to remove its name from propertiesWithDefaultDefined. Later, LocalDatabase.setDefaultValues() iterates that stale name and calls getPolymorphicProperty(), which raises the exception.
For comparison, removing the whole edge type and recreating it did not reproduce the failure; the minimal trigger is dropping a property that previously had a default value.
Activity
fix(#6799): serialize the default publication and make the cache upda…
fix(#6799): reject a default written through a dropped property handle
fix(#6799): skip a default whose property vanished mid-create, and un…
fix(#6799): refuse a detached handle whatever value it carries, and s…
docs(#6799): say which readers are actually unlocked, and why the cac…
docs(#6799): say why setDefaultValue takes the write lock and its sib…
docs(#6799): note that the fast-path check is a deliberate duplicate
Merge pull request #6861 from ArcadeData/fix/6799-drop-property-defau…
lvca commentedon Aug 28, 2026
Fixed in #6861, merged for 26.9.1.
You were right about the cause.
DROP PROPERTYremoved the property from the schema but left its name in the type's internal list of properties that have aDEFAULT, so the next record created for that type looked for a property that was no longer there and the commit failed. Restarting the server appeared to fix it because the default is stored on the property itself inschema.json, so reloading the schema rebuilt the list correctly.A dropped property now stops taking part in default-value processing immediately, and the two places that maintain that list were merged into one so they cannot disagree again. Two related problems found along the way are fixed too: dropping a property while another connection was setting a default, or saving the schema, could produce the same error or an internal exception.
One note if you use the embedded Java API: calling
setDefaultValue()on aPropertyobject you kept after dropping that property now raises aSchemaExceptioninstead of silently succeeding.❤️ Thanks for helping make ArcadeDB better! ArcadeDB is free and open source, sustained by its community. If it's useful to you or your company, please consider becoming a sponsor to keep development going.
fix(ArcadeData#6799): DROP PROPERTY must clear the type's default-pro…