Skip to content

Commit 0cda1cd

Browse files
committed
revert(schema): restore writeOnly and persist annotations
Restore field annotations that were removed in 447e339. These annotations are needed for correct patch generation - writeOnly fields must be included in every update patch since cloud providers don't return them on Read operations. This reverts the writeOnly/persist removal while keeping the nonprovisionable removal (which is being sunset in formae).
1 parent 3f15e19 commit 0cda1cd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+152
-69
lines changed

schema/pkl/apigateway/apikey.pkl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ open class ApiKey extends formae.Resource {
4646

4747
@aws.FieldHint{
4848
createOnly = true
49+
writeOnly = true
4950
}
5051
generateDistinctId: Boolean?
5152

schema/pkl/apigateway/deployment.pkl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ open class Deployment extends formae.Resource {
8383

8484
@aws.FieldHint{
8585
createOnly = true
86+
writeOnly = true
8687
}
8788
deploymentCanarySettings: CanarySetting?
8889

@@ -94,11 +95,13 @@ open class Deployment extends formae.Resource {
9495

9596
@aws.FieldHint{
9697
createOnly = true
98+
writeOnly = true
9799
}
98100
stageDescription: StageDescription?
99101

100102
@aws.FieldHint{
101103
createOnly = true
104+
writeOnly = true
102105
}
103106
stageName: String?
104107

schema/pkl/apigateway/restapi.pkl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,16 +57,19 @@ open class RestApi extends formae.Resource {
5757

5858
@aws.FieldHint{
5959
createOnly = true
60+
writeOnly = true
6061
}
6162
body: Dynamic?
6263

6364
@aws.FieldHint{
6465
createOnly = true
66+
writeOnly = true
6567
}
6668
bodyS3Location: BodyS3Location?
6769

6870
@aws.FieldHint{
6971
createOnly = true
72+
writeOnly = true
7073
}
7174
cloneFrom: String?
7275

@@ -80,20 +83,23 @@ open class RestApi extends formae.Resource {
8083
endpointConfiguration: EndpointConfiguration?
8184

8285
@aws.FieldHint{
86+
writeOnly = true
8387
}
8488
failOnWarnings: Boolean?
8589

8690
@aws.FieldHint
8791
minimumCompressionSize: Int?
8892

8993
@aws.FieldHint{
94+
writeOnly = true
9095
}
9196
mode: String?
9297

9398
@aws.FieldHint
9499
name: String?
95100

96101
@aws.FieldHint{
102+
writeOnly = true
97103
}
98104
parameters: Mapping<String, Any>?
99105

schema/pkl/dynamodb/globaltable.pkl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ open class AttributeDefinition extends formae.SubResource {
2121
open class CapacityAutoScalingSettings extends formae.SubResource {
2222
maxCapacity: Int
2323
minCapacity: Int
24-
@aws.FieldHint{}
24+
@aws.FieldHint{writeOnly = true}
2525
seedCapacity: Int?
2626
targetTrackingScalingPolicyConfiguration: TargetTrackingScalingPolicyConfiguration
2727
}

schema/pkl/dynamodb/table.pkl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ open class Table extends formae.Resource {
160160

161161
@aws.FieldHint{
162162
createOnly = true
163+
writeOnly = true
163164
}
164165
importSourceSpecification: ImportSourceSpecification?
165166

schema/pkl/ec2/capacityreservation.pkl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,6 @@ open class CapacityReservation extends formae.Resource {
6767
@aws.FieldHint
6868
tenancy: String?
6969

70-
@aws.FieldHint{}
70+
@aws.FieldHint{writeOnly = true}
7171
unusedReservationBillingOwnerId: String?
7272
}

schema/pkl/ec2/eip.pkl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ open class EIP extends formae.Resource {
3131

3232
@aws.FieldHint{
3333
createOnly = true
34+
writeOnly = true
3435
}
3536
address: String?
3637

@@ -42,6 +43,7 @@ open class EIP extends formae.Resource {
4243

4344
@aws.FieldHint{
4445
createOnly = true
46+
writeOnly = true
4547
}
4648
ipamPoolId: String?
4749

@@ -59,6 +61,7 @@ open class EIP extends formae.Resource {
5961

6062
@aws.FieldHint{
6163
createOnly = true
64+
writeOnly = true
6265
}
6366
transferAddress: String?
6467

schema/pkl/ec2/instance.pkl

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ open class BlockDeviceMapping extends formae.SubResource {
2424
deviceName: String
2525
ebs: EBS?
2626

27-
@aws.FieldHint{}
27+
@aws.FieldHint{writeOnly = true}
2828
noDevice: Dynamic?
2929

30-
@aws.FieldHint{}
30+
@aws.FieldHint{writeOnly = true}
3131
virtualName: String?
3232
}
3333

@@ -157,7 +157,7 @@ open class InstanceResolvable extends formae.Resolvable {
157157
}
158158
open class Instance extends formae.Resource {
159159

160-
@aws.FieldHint{}
160+
@aws.FieldHint{writeOnly = true}
161161
additionalInfo: String?
162162

163163
@aws.FieldHint
@@ -213,11 +213,13 @@ open class Instance extends formae.Resource {
213213

214214
@aws.FieldHint{
215215
createOnly = true
216+
writeOnly = true
216217
}
217218
ipv6AddressCount: Int?
218219

219220
@aws.FieldHint{
220221
createOnly = true
222+
writeOnly = true
221223
}
222224
ipv6Addresses: Listing<Ipv6Address>?
223225

@@ -229,6 +231,7 @@ open class Instance extends formae.Resource {
229231

230232
@aws.FieldHint{
231233
createOnly = true
234+
writeOnly = true
232235
}
233236
launchTemplate: Dynamic?
234237

@@ -250,7 +253,7 @@ open class Instance extends formae.Resource {
250253
@aws.FieldHint{createOnly = true}
251254
privateIpAddress: String?
252255

253-
@aws.FieldHint{}
256+
@aws.FieldHint{writeOnly = true}
254257
propagateTagsToVolumeOnCreation: Boolean?
255258

256259
@aws.FieldHint

schema/pkl/ec2/instanceconnectendpoint.pkl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ open class InstanceConnectEndpoint extends formae.Resource {
1919

2020
@aws.FieldHint{
2121
createOnly = true
22+
writeOnly = true
2223
}
2324
clientToken: String?
2425

schema/pkl/ec2/ipamallocation.pkl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ open class IPAMAllocation extends formae.Resource {
3030

3131
@aws.FieldHint{
3232
createOnly = true
33+
writeOnly = true
3334
}
3435
netmaskLength: Int?
3536
}

0 commit comments

Comments
 (0)