René's URL Explorer Experiment


Title: [Proposal] Enable Lombok.toBuilder annotation flag in ResourceModel template · Issue #331 · aws-cloudformation/cloudformation-cli-java-plugin · GitHub

Open Graph Title: [Proposal] Enable Lombok.toBuilder annotation flag in ResourceModel template · Issue #331 · aws-cloudformation/cloudformation-cli-java-plugin

X Title: [Proposal] Enable Lombok.toBuilder annotation flag in ResourceModel template · Issue #331 · aws-cloudformation/cloudformation-cli-java-plugin

Description: Dear team, I wonder if you folks would have any concerns about enabling toBuilder attribute for Lombok @Builder by default or with an additional schema flag? At the moment, ResourceModel template generates non-parametrized @Builder: http...

Open Graph Description: Dear team, I wonder if you folks would have any concerns about enabling toBuilder attribute for Lombok @Builder by default or with an additional schema flag? At the moment, ResourceModel template g...

X Description: Dear team, I wonder if you folks would have any concerns about enabling toBuilder attribute for Lombok @Builder by default or with an additional schema flag? At the moment, ResourceModel template g...

Opengraph URL: https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[Proposal] Enable Lombok.toBuilder annotation flag in ResourceModel template","articleBody":"Dear team,\r\n\r\nI wonder if you folks would have any concerns about enabling `toBuilder` attribute for Lombok @\u003c!-- -->Builder by default or with an additional schema flag?\r\n\r\nAt the moment, `ResourceModel` template generates non-parametrized @\u003c!-- -->Builder: https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/blob/master/python/rpdk/java/templates/init/guided_aws/ResourceModel.java#L20\r\n\r\nOne of the reasons I would like to see this flag enabled is a significant simplification of overriding massive resource model definitions in testing, especially in testing an `UpdateHandler`.\r\n\r\nHere is an example:\r\n\r\n```java\r\npublic class AbstractTestBase {\r\n  protected static final ResourceModel MODEL_BEFORE;\r\n  protected static final ResourceModel MODEL_AFTER;\r\n\r\n  static {\r\n    MODEL_BEFORE = ResourceModel.builder()\r\n      .foo(\"foo-before\")\r\n      .bar(\"bar-before\")\r\n      .baz(\"baz-before\")\r\n      .build();\r\n    MODEL_AFTER = ResourceModel.builder()\r\n      .foo(\"foo-before\")\r\n      .bar(\"bar-before\")\r\n      .baz(\"totally-different-baz\")\r\n      .build();\r\n  }\r\n}\r\n```\r\n\r\nAssume I'm using these models in `UpdateHandler` test suite. If the update flow has a broad branching based on model attribute invariants, one has to initiate separate model instances for each branch case. It's completely fine for a 5-10 attribute models, but the burden of carrying things around grows once one has to deal with a 30-50 attribute model.\r\n\r\nHaving `toBuilder = true` enabled in `ResourceModel` definition would let one define models like\r\n```java\r\npublic class AbstractTestBase {\r\n  protected static final ResourceModel MODEL_BEFORE;\r\n  protected static final ResourceModel MODEL_AFTER;\r\n\r\n  static {\r\n    MODEL_BEFORE = ResourceModel.builder()\r\n      .foo(\"foo-before\")\r\n      .bar(\"bar-before\")\r\n      .baz(\"baz-before\")\r\n      .build();\r\n    MODEL_AFTER = MODEL_BEFORE.toBuilder()\r\n      .baz(\"totally-different-baz\")\r\n      .build();\r\n  }\r\n}\r\n```\r\n\r\nIn fact, being able to override a static model locally within the current test case scope is even better, it could look like:\r\n```java\r\npublic class UpdateHandlerTest extends AbstractTestBase {\r\n  //...\r\n  public void handleRequest_SimpleSuccess() {\r\n    final ResourceModel modelWithUpdatedBaz = MODEL_BEFORE.toBuilder()\r\n      .baz(\"totally-different-baz\")\r\n      .build();\r\n      //...\r\n  }\r\n}\r\n```","author":{"url":"https://github.com/osdrv","@type":"Person","name":"osdrv"},"datePublished":"2020-11-23T14:28:52Z","url":"https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:7be0332e-da5c-ac89-41dd-5ff3b40c14eb
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id8358:20702:5D3082:8618B2:6AFD8AAB
html-safe-nonce519368b6783d996a6d3a300085d7ad0aac9c8de6fadc2074552ec3de47afac8e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MzU4OjIwNzAyOjVEMzA4Mjo4NjE4QjI6NkFGRDhBQUIiLCJ2aXNpdG9yX2lkIjoiMjQyNjQxNTAzOTQ5ODc4MzQwMyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac93cb6cac686d4dd7184c33df431b0cb0f7c43483b0402422577bd24fd7772698
hovercard-subject-tagissue:748849165
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/aws-cloudformation/cloudformation-cli-java-plugin/331/issue_layout
twitter:imagehttps://opengraph.githubassets.com/715af84b1c68b133d79bd52737a679ef8fc48021e76f55987201daa8f82a2464/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/715af84b1c68b133d79bd52737a679ef8fc48021e76f55987201daa8f82a2464/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
og:image:altDear team, I wonder if you folks would have any concerns about enabling toBuilder attribute for Lombok @Builder by default or with an additional schema flag? At the moment, ResourceModel template g...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameosdrv
hostnamegithub.com
expected-hostnamegithub.com
Nonebc86424ef34a73b386237872800e922d149d65ba907f63d6f150a2dcb8433bea
turbo-cache-controlno-preview
go-importgithub.com/aws-cloudformation/cloudformation-cli-java-plugin git https://github.com/aws-cloudformation/cloudformation-cli-java-plugin.git
octolytics-dimension-user_id19900777
octolytics-dimension-user_loginaws-cloudformation
octolytics-dimension-repository_id152624998
octolytics-dimension-repository_nwoaws-cloudformation/cloudformation-cli-java-plugin
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id152624998
octolytics-dimension-repository_network_root_nwoaws-cloudformation/cloudformation-cli-java-plugin
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release927a6c5ab1c32b38830f1b9d3050c0b9e9aa92e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Faws-cloudformation%2Fcloudformation-cli-java-plugin%2Fissues%2F331
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Faws-cloudformation%2Fcloudformation-cli-java-plugin%2Fissues%2F331
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=aws-cloudformation%2Fcloudformation-cli-java-plugin
Reloadhttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
Reloadhttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
Reloadhttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
aws-cloudformationhttps://github.com/aws-cloudformation
cloudformation-cli-java-pluginhttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin
Codehttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin
Issues30 (30)https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues
Pull requests13 (13)https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/pulls
Actionshttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/actions
Projectshttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/projects
Security and quality1 (1)https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/security
Insightshttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/insights
https://github.com/aws-cloudformation/cloudformation-cli-java-plugin
New issuehttps://github.com/login?return_to=https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
New issuehttps://github.com/login?return_to=https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
[Proposal] Enable Lombok.toBuilder annotation flag in ResourceModel templatehttps://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331#top
https://github.com/osdrv
osdrvhttps://github.com/osdrv
on Nov 23, 2020https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331#issue-748849165
https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/blob/master/python/rpdk/java/templates/init/guided_aws/ResourceModel.java#L20https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/blob/master/python/rpdk/java/templates/init/guided_aws/ResourceModel.java#L20
Sign up for freehttps://github.com/signup?return_to=https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
Sign in to commenthttps://github.com/login?return_to=https://github.com/aws-cloudformation/cloudformation-cli-java-plugin/issues/331
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.