官术网_书友最值得收藏!

DSLs and generators

DSLs and generators can be a point of hot debate among infrastructure coders. Some love them, some hate them. Some of the reasons why people love them include the following:

  • They allow CloudFormation to be written in a language that is more native to them or their team.
  • They allow the use some advanced programming constructs. Iteration is a particularly well-cited example.
  • Until YAML was supported by CloudFormation, using a DSL usually resulted in code that was easier to read and far less verbose.

Some of the reasons people dislike them are:

  • DSLs have a history of becoming abandonware or significantly lagging behind CloudFormation, although there are a couple of well-supported DSLs out there
  • Developers are potentially required to learn a new language and navigate another new set of documentation, on top of learning CloudFormation and navigating the AWS documentation
  • Google and Stack Overflow become a little less useful because one needs to translate questions and answers

Beyond what is written here, this topic won't come up again in this book. We can't give specific advice as to which road you should take because it's almost always a highly personal and situational choice. However, a sensible approach, especially while coming to grips with AWS and CloudFormation, would be to stick with YAML (or JSON) until you get to the point where you think a DSL or generator might be useful.

主站蜘蛛池模板: 朔州市| 重庆市| 湄潭县| 志丹县| 裕民县| 桃源县| 高安市| 灵武市| 织金县| 新巴尔虎左旗| 湛江市| 安庆市| 蓬溪县| 化德县| 竹溪县| 娱乐| 五莲县| 民丰县| 永新县| 岳阳市| 长泰县| 静宁县| 繁昌县| 遂宁市| 游戏| 西乌珠穆沁旗| 毕节市| 刚察县| 阿拉善盟| 松滋市| 龙川县| 武宣县| 咸阳市| 仁怀市| 墨竹工卡县| 新田县| 江口县| 蓝山县| 台前县| 宜城市| 明溪县|