You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
DATACMNS-180 - Don't consider Java transient fields transient for persistence.
So far we have considered Java transient fields as transient through the isTransient() method on PersistentProperty. This resulted in the properties not being persisted eventually. We now consider all fields as non-transient by default as we actually have to persist them as the object cannot be re-created completely without doing so as the usage of the transient keyword might rely on the readObject(…) method inside the object which would actually reconstitute the transient field's state but we of course cannot call this method actually.
Copy file name to clipboardExpand all lines: spring-data-commons-core/src/main/java/org/springframework/data/mapping/model/AbstractPersistentProperty.java
+8-6Lines changed: 8 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -1,25 +1,23 @@
1
1
/*
2
-
* Copyright (c) 2011 by the original author(s).
2
+
* Copyright 2011-2012 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
6
6
* You may obtain a copy of the License at
7
7
*
8
-
* http://www.apache.org/licenses/LICENSE-2.0
8
+
* http://www.apache.org/licenses/LICENSE-2.0
9
9
*
10
10
* Unless required by applicable law or agreed to in writing, software
11
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
13
* See the License for the specific language governing permissions and
14
14
* limitations under the License.
15
15
*/
16
-
17
16
packageorg.springframework.data.mapping.model;
18
17
19
18
importjava.beans.PropertyDescriptor;
20
19
importjava.lang.annotation.Annotation;
21
20
importjava.lang.reflect.Field;
22
-
importjava.lang.reflect.Modifier;
23
21
importjava.util.ArrayList;
24
22
importjava.util.List;
25
23
importjava.util.Map;
@@ -34,7 +32,7 @@
34
32
/**
35
33
* Simple impementation of {@link PersistentProperty}.
Copy file name to clipboardExpand all lines: spring-data-commons-core/src/test/java/org/springframework/data/mapping/model/AbstractPersistentPropertyUnitTests.java
+30Lines changed: 30 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,18 @@
1
+
/*
2
+
* Copyright 2011-2012 the original author or authors.
3
+
*
4
+
* Licensed under the Apache License, Version 2.0 (the "License");
5
+
* you may not use this file except in compliance with the License.
6
+
* You may obtain a copy of the License at
7
+
*
8
+
* http://www.apache.org/licenses/LICENSE-2.0
9
+
*
10
+
* Unless required by applicable law or agreed to in writing, software
11
+
* distributed under the License is distributed on an "AS IS" BASIS,
12
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+
* See the License for the specific language governing permissions and
0 commit comments