Skip to content

Commit c03f9d1

Browse files
gsmetmarko-bekhta
authored andcommitted
HV-1831 Add some guidance about next step
1 parent 0968f38 commit c03f9d1

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

engine/src/main/java/org/hibernate/validator/internal/engine/PredefinedScopeValidatorFactoryImpl.java

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,20 @@ public PredefinedScopeValidatorFactoryImpl(ConfigurationState configurationState
188188
xmlMetaDataProvider = null;
189189
}
190190

191+
// collect all metadata, I don't think we need this work to be in BeanMetaDataManager contract, it can be a specific class (or private method if simple enough)
192+
// it's basically the content of PredefinedScopeBeanMetaDataManager constructor
193+
// the metadata wouldn't be complete because we want to inject the tracking information
194+
195+
// then you build the tracking information from these incomplete metadata
196+
197+
// finally you create a PredefinedScopeBeanMetaDataManager with the augmented metadata pushed to it
198+
// you will need to augment both BeanMetaData and ExecutableMetaData
199+
// I would prototype BeanMetaData first then discuss it before going further
200+
201+
// Note: we want classes to be immutable
202+
// Might be a good idea to push a default method to BeanMetaData as enabling tracking is the default behavior we want
203+
// Maybe first try composition and benchmark it and if good enough, we keep it
204+
191205
this.beanMetaDataManager = new PredefinedScopeBeanMetaDataManager(
192206
constraintCreationContext,
193207
executableHelper,

0 commit comments

Comments
 (0)