|
7 | 7 | "context"
|
8 | 8 | "log"
|
9 | 9 | "strings"
|
10 |
| - "time" |
11 | 10 |
|
12 | 11 | "github.com/aws/aws-sdk-go-v2/aws"
|
13 | 12 | "github.com/aws/aws-sdk-go-v2/aws/arn"
|
@@ -134,7 +133,6 @@ func resourcePortfolioShareCreate(ctx context.Context, d *schema.ResourceData, m
|
134 | 133 | input.ShareTagOptions = v.(bool)
|
135 | 134 | }
|
136 | 135 |
|
137 |
| - // mutex lock for creation/deletion serialization |
138 | 136 | conns.GlobalMutexKV.Lock(portfolioShareMutexKey)
|
139 | 137 | defer conns.GlobalMutexKV.Unlock(portfolioShareMutexKey)
|
140 | 138 |
|
@@ -181,13 +179,6 @@ func resourcePortfolioShareCreate(ctx context.Context, d *schema.ResourceData, m
|
181 | 179 | }
|
182 | 180 | }
|
183 | 181 |
|
184 |
| - // Only one share create/second is allowed, but unfortunately not all throttling |
185 |
| - // happens as a return from CreatePortfolioShare(). That can succeed and then |
186 |
| - // the throttling can happen as part of the account accepting. If everything |
187 |
| - // else succeeds, sleep a bit to give us time between sequentially executed |
188 |
| - // portfolio shares. |
189 |
| - time.Sleep(15 * time.Second) |
190 |
| - |
191 | 182 | return append(diags, resourcePortfolioShareRead(ctx, d, meta)...)
|
192 | 183 | }
|
193 | 184 |
|
@@ -311,7 +302,6 @@ func resourcePortfolioShareDelete(ctx context.Context, d *schema.ResourceData, m
|
311 | 302 | input.OrganizationNode = orgNode
|
312 | 303 | }
|
313 | 304 |
|
314 |
| - // mutex lock for creation/deletion serialization |
315 | 305 | conns.GlobalMutexKV.Lock(portfolioShareMutexKey)
|
316 | 306 | defer conns.GlobalMutexKV.Unlock(portfolioShareMutexKey)
|
317 | 307 |
|
|
0 commit comments