{"id":1559,"date":"2020-07-28T20:51:15","date_gmt":"2020-07-28T18:51:15","guid":{"rendered":"https:\/\/serengeti.pepwebdigital.hr\/?p=1559"},"modified":"2021-01-04T18:14:29","modified_gmt":"2021-01-04T17:14:29","slug":"twisted-and-tangled-spaghetti-code-loses-you-a-lot-of-money-it-can-be-fixed-though","status":"publish","type":"post","link":"https:\/\/serengetitech.com\/de\/business\/twisted-and-tangled-spaghetti-code-loses-you-a-lot-of-money-it-can-be-fixed-though\/","title":{"rendered":"Twisted and tangled: Spaghetti code loses you a lot of money. It can be fixed, though!"},"content":{"rendered":"\n<h2 class=\"eplus-w1BREv wp-block-heading\"><strong>What is spaghetti code?<\/strong><\/h2>\n\n\n\n<p class=\"eplus-OE7LXq\">It means&nbsp;<a target=\"_blank\" href=\"https:\/\/en.wikipedia.org\/wiki\/Spaghetti_code\" rel=\"noreferrer noopener\">unstructured and difficult-to-maintain source code.<\/a>&nbsp;In other words, it\u2019s a mess.<\/p>\n\n\n\n<p class=\"eplus-OQjmr1\">It looks like a bowl of spaghetti instead of the beauty that code can (and should) be. The term originated in the 1970s and appeared in a 1988 white paper called&nbsp;<a rel=\"noreferrer noopener\" target=\"_blank\" href=\"https:\/\/dl.acm.org\/doi\/10.1109\/2.59\">\u201cA Spiral Model of Software Development and Enhancement,\u201d<\/a>&nbsp;which ended up leading to the waterfall method of development and project management. (Waterfall then got replaced by&nbsp;<a href=\"https:\/\/serengetitech.com\/en\/expertise\/technology-trends\/devops\" target=\"_blank\" rel=\"noreferrer noopener\">more agile approaches<\/a>.)<\/p>\n\n\n\n<h2 class=\"eplus-cnbOeK wp-block-heading\"><strong>Why does this happen?<\/strong><\/h2>\n\n\n\n<p class=\"eplus-52QTRW\">There are lots of potential reasons. Some of the major ones include:<\/p>\n\n\n<ul class=\"eplus-n4v4qS wp-block-list eplus-styles-uid-56b2ba\"><li>Unclear project requirements<\/li><li>Multiple teams have come in and worked on a project<\/li><li>A lack of programming style rules<\/li><li>Lack of ability on the part of those who have touched the code<\/li><li>Lack of experience<\/li><li>Too much control of legacy code from 3-4 senior developers who potentially haven\u2019t learned new coding approaches in years<\/li><li>Some of those same senior developers leave the firm without clear guidelines and context being given about the code, so those who have to work on it make it more confusing<\/li><\/ul>\n\n\n<p class=\"eplus-Zdb7FV\">&nbsp;Those are just some of the reasons.<\/p>\n\n\n\n<p class=\"eplus-uynvVS\">In short: bad communication between developers, lack of expertise, and lack of style rules.<\/p>\n\n\n\n<h2 class=\"eplus-3kr1no wp-block-heading\"><strong>Why Spaghetti code is a problem?<\/strong><\/h2>\n\n\n\n<p class=\"eplus-eKl79X\">Because your code is messy, it\u2019s hard to work on, and your applications may not run properly for the end-user. You are costing yourself money. Maintenance is expensive. Bugs occur more often. Every upgrade, deployment, and connection with a third-party app becomes more complicated and more expensive. Downtime is longer, user experience is bad, and in general spaghetti code is one of the bigger problems your dev team can be facing.<\/p>\n\n\n\n<h2 class=\"eplus-gR5RiU wp-block-heading\"><strong>How can you fix the spaghetti code problem?<\/strong><\/h2>\n\n\n\n<p class=\"eplus-o9ZLXv\">We have talked a bit before about&nbsp;<a href=\"\/blog\/business\/moving-from-legacy-application-to-modern-cost-efficient-application-in-5-steps\">moving from legacy applications to more modern, cost-efficient applications.<\/a>&nbsp;That is part of solving spaghetti code.<\/p>\n\n\n\n<p class=\"eplus-mKSeSM\">Heck, think about how you can eat spaghetti. If you twirl it on the fork, you need to (a) know how to do that and (b) be patient, as well as have the right tools (the fork, in that case). It\u2019s the same with software development. You need knowledge (devs), you need to be patient, and you need tools (programs).<\/p>\n\n\n\n<p class=\"eplus-jjPNTD\">You could also cut the spaghetti into smaller pieces. That\u2019s similar to&nbsp;<a href=\"\/blog\/business\/5-benefits-that-microservices-implementation-can-bring-to-your-business-free-webinar-checklist\">a shift to microservices implementation.<\/a><\/p>\n\n\n\n<h3 class=\"eplus-xbAhb6 wp-block-heading\"><strong>Other ways to reduce spaghetti code:<\/strong><\/h3>\n\n\n<ul class=\"eplus-vhojjq wp-block-list eplus-styles-uid-eac79a\"><li><strong>Use lightweight frameworks:\u00a0<\/strong>Many of these are available in 2020.<\/li><li><strong>Unit test consistently:\u00a0<\/strong>This will allow you to see where code might be getting tangled up like spaghetti.<\/li><li><strong>Use additional layers:\u00a0<\/strong>This can create complexity, but it also allows you to address single layers rather than the full scope of code.<\/li><li><strong>Don\u2019t rush:\u00a0<\/strong>Developers need to focus on the best architecture for a given project and not rush the initial steps.<\/li><li><strong>Hire for actual expertise:\u00a0<\/strong>This is easier to do with outsourcing software development because you can bring in a team with quantified expertise who has worked on\u00a0<a href=\"\/about\/case-studies-and-client-testimonials\">many different types of projects.<\/a>\u00a0Outsourced development teams have become adept over time at cleaning up source code.<\/li><li><strong>\u201cMeasure twice, cut once:\u201d\u00a0<\/strong>This is the same advice you see in construction,\u00a0<a rel=\"noreferrer noopener\" target=\"_blank\" href=\"https:\/\/medium.com\/@brendanpettis\/how-to-avoid-spaghetti-code-8eb6bb3504fe\">but it applies to coding as well.<\/a><\/li><li><strong>Force conversations:\u00a0<\/strong>If a few senior developers \u201cown\u201d the code and they are not providing background and context for what they did with the code when it was first deployed, keep pressing them to talk more about how they wrote it, what they were thinking, what frameworks were in play, etc. Learn the origin story and it\u2019s easier to untangle.<\/li><\/ul>\n\n\n<h2 class=\"eplus-MA0HHY wp-block-heading\"><strong>How Serengeti helps fix spaghetti code<\/strong><\/h2>\n\n\n\n<p class=\"eplus-MCsTuZ\">We come in as an&nbsp;<a href=\"\/about\/team-extension-model\">extension of your overall team<\/a>&nbsp;and take audit of where everything stands with projects and your coding. If we need to work with the internal team to fix the spaghetti code, we will; it is one of the first things we will do. Bad architecture and code framework can doom the rest of a project down the line, so we will fix this for you if it\u2019s a current problem. Our developers are some of&nbsp;<a href=\"https:\/\/www.youtube.com\/watch?v=49HkGMsqO70&amp;t=24s\" target=\"_blank\" rel=\"noreferrer noopener\">the best in the world<\/a>&nbsp;at this.<\/p>\n\n\n\n<p class=\"eplus-SVZNZm\"><strong>Any questions? Let us know. And for a guide to picking the right software development outsourcing partner:<\/strong><\/p>\n\n\n<style>#kt-modal_d7f8cb-f5 .kt-blocks-modal-link{color:#ffffff;background:#43c8a0;border-color:#393335;border-radius:20px;font-size:20px;line-height:1.5em;font-style:normal;font-weight:regular;border-width:0px 0px 4px 0px;padding:16px 32px 16px 32px;margin:32px 0px 48px 0px;}#kt-modal_d7f8cb-f5 .kt-blocks-modal-link:hover, #kt-modal_d7f8cb-f5 .kt-blocks-modal-link:focus{color:#ffffff;background:#393335;border-color:#e3d600;}#kt-modal_d7f8cb-f5 .kt-modal-overlay, #kt-target-modal_d7f8cb-f5 .kt-modal-overlay, .kb-modal-content_d7f8cb-f5 .kt-modal-overlay{background:rgba(0, 0, 0, 0.8);}#kt-modal_d7f8cb-f5 .kt-modal-overlay, #kt-target-modal_d7f8cb-f5 .kt-modal-overlay, .kb-modal-content_d7f8cb-f5 .kt-modal-overlay{-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;}#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{width:100%;max-width:750px;-ms-flex-pack:flex-start;justify-content:flex-start;text-align:left;-ms-flex-align:flex-start;align-items:flex-start;}#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{padding-top:32px;padding-right:32px;padding-bottom:32px;padding-left:32px;margin-top:8px;margin-right:8px;margin-bottom:8px;margin-left:8px;}#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{background:#13181e;border-top:0px solid #ffffff;border-right:0px solid #ffffff;border-bottom:0px solid #ffffff;border-left:0px solid #ffffff;}#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{box-shadow:0px 0px 14px 0px rgba(19, 24, 30, 0.81);}#kt-modal_d7f8cb-f5 .kt-modal-close, #kt-target-modal_d7f8cb-f5 .kt-modal-close, .kb-modal-content_d7f8cb-f5 .kt-modal-close{color:#ffffff;}#kt-modal_d7f8cb-f5 .kt-modal-close svg, #kt-target-modal_d7f8cb-f5 .kt-modal-close svg, .kb-modal-content_d7f8cb-f5 .kt-modal-close svg{width:24px;height:24px;}#kt-modal_d7f8cb-f5 .kt-modal-close:hover, #kt-target-modal_d7f8cb-f5 .kt-modal-close:hover, .kb-modal-content_d7f8cb-f5 .kt-modal-close:hover, body:not(.hide-focus-outline) #kt-modal_d7f8cb-f5 .kt-modal-close:focus, body:not(.hide-focus-outline) #kt-target-modal_d7f8cb-f5 .kt-modal-close:focus,body:not(.hide-focus-outline)  .kb-modal-content_d7f8cb-f5 .kt-modal-close:focus{color:#43c8a0;}@media all and (max-width: 1024px){#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{width:100%;border-top:0px solid #ffffff;border-right:0px solid #ffffff;border-bottom:0px solid #ffffff;border-left:0px solid #ffffff;}}@media all and (max-width: 1024px){#kt-modal_d7f8cb-f5 .kt-modal-close svg, #kt-target-modal_d7f8cb-f5 .kt-modal-close svg, .kb-modal-content_d7f8cb-f5 .kt-modal-close svg{width:24px;height:24px;}}@media all and (max-width: 767px){#kt-modal_d7f8cb-f5 .kt-modal-container, #kt-target-modal_d7f8cb-f5 .kt-modal-container, .kb-modal-content_d7f8cb-f5 .kt-modal-container{width:100%;border-top:0px solid #ffffff;border-right:0px solid #ffffff;border-bottom:0px solid #ffffff;border-left:0px solid #ffffff;}#kt-modal_d7f8cb-f5 .kt-modal-close svg, #kt-target-modal_d7f8cb-f5 .kt-modal-close svg, .kb-modal-content_d7f8cb-f5 .kt-modal-close svg{width:24px;height:24px;}}<\/style>\n<div id=\"kt-modal_d7f8cb-f5\" class=\"wp-block-kadence-modal alignnone kt-modal-linkalign-center\"><div id=\"kt-target-modal_d7f8cb-f5\" class=\"kb-modal-content_d7f8cb-f5 kadence-block-pro-modal kt-m-animate-in-fadeup kt-m-animate-out-fadeout\" aria-hidden=\"true\"><div class=\"kt-modal-overlay\" tabindex=\"-1\" data-modal-close=\"true\"><div class=\"kt-modal-container kt-modal-height-fittocontent kt-close-position-inside\" role=\"dialog\" aria-modal=\"true\"><button class=\"kt-modal-close\" aria-label=\"Close Modal\" data-modal-close=\"true\"><svg viewbox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" xmlns=\"https:\/\/www.w3.org\/2000\/svg\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"><\/line><line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"><\/line><\/svg><\/button><div id=\"kt-modal_d7f8cb-f5-content\" class=\"kt-modal-content\"><p class=\"eplus-mubjY6 has-text-align-center eplus-wrapper eplus-styles-uid-b366b6\" style=\"font-size:20px\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-kb-palette-3-color\">Where can we send you our <strong>Checklist: <strong>How product vendors in Western Europe choose the right nearshoring partner?<\/strong><\/strong><\/mark><\/p>\n\n<style>.wp-block-kadence-spacer.kt-block-spacer-_64cdc4-af .kt-block-spacer{height:6px;}.wp-block-kadence-spacer.kt-block-spacer-_64cdc4-af .kt-divider{border-top-width:1px;height:1px;border-top-color:#43c8a0;width:50%;border-top-style:solid;}<\/style>\n<div class=\"wp-block-kadence-spacer aligncenter kt-block-spacer-_64cdc4-af\"><div class=\"kt-block-spacer kt-block-spacer-halign-center\"><hr class=\"kt-divider\"\/><\/div><\/div>\n\n\n<p class=\"eplus-Upg7I9 has-text-align-center eplus-wrapper eplus-styles-uid-b366b6\" style=\"font-size:14px\"><mark style=\"background-color:rgba(0, 0, 0, 0);color:#929ba7\" class=\"has-inline-color\">By clicking \"Submit\" you confirm the subscription to our newsletter and that you accept and understand our <a rel=\"noreferrer noopener\" href=\"\/privacy-policy\/\" target=\"_blank\">Privacy Policy.<\/a><\/mark><\/p>\n\n<style>.wp-block-kadence-spacer.kt-block-spacer-_e13674-97 .kt-block-spacer{height:16px;}.wp-block-kadence-spacer.kt-block-spacer-_e13674-97 .kt-divider{border-top-width:1px;height:1px;border-top-color:#eee;width:80%;border-top-style:solid;}<\/style>\n<div class=\"wp-block-kadence-spacer aligncenter kt-block-spacer-_e13674-97\"><div class=\"kt-block-spacer kt-block-spacer-halign-center\"><\/div><\/div>\n\n\n<div class='fluentform ff-default fluentform_wrapper_4  ff_guten_block ff_guten_block-4 ffs_default_wrap'><form data-form_id=\"4\" id=\"fluentform_4\" class=\"frm-fluent-form fluent_form_4 ff-el-form-top ff_form_instance_4_1 ff-form-loading ff_has_v3_recptcha ffs_default\" data-form_instance=\"ff_form_instance_4_1\" method=\"POST\" data-recptcha_key=\"6Lc7YbQUAAAAAHi08MlmK6fxaWUX2f0Xe0b4BNC4\" ><fieldset  style=\"border: none!important;margin: 0!important;padding: 0!important;background-color: transparent!important;box-shadow: none!important;outline: none!important; min-inline-size: 100%;\">\n                    <legend class=\"ff_screen_reader_title\" style=\"display: block; margin: 0!important;padding: 0!important;height: 0!important;text-indent: -999999px;width: 0!important;overflow:hidden;\">Checklist Download<\/legend>        <div\n                style=\"display: none!important; position: absolute!important; transform: translateX(1000%)!important;\"\n                class=\"ff-el-group ff-hpsf-container\"\n        >\n            <div class=\"ff-el-input--label asterisk-right\">\n                <label for=\"ff_4_item_sf\" aria-label=\"Newsletter\">\n                    Newsletter                <\/label>\n            <\/div>\n            <div class=\"ff-el-input--content\">\n                <input type=\"text\"\n                       name=\"item_4__fluent_sf\"\n                       class=\"ff-el-form-control\"\n                       id=\"ff_4_item_sf\"\n                \/>\n            <\/div>\n        <\/div>\n        <input type='hidden' name='__fluent_form_embded_post_id' value='1559' \/><input type=\"hidden\" id=\"_fluentform_4_fluentformnonce\" name=\"_fluentform_4_fluentformnonce\" value=\"7454cc272c\" \/><input type=\"hidden\" name=\"_wp_http_referer\" value=\"\/de\/wp-json\/wp\/v2\/posts\/1559\" \/><div data-type=\"name-element\" data-name=\"names\" class=\" ff-field_container ff-name-field-wrapper\" ><div class='ff-t-container'><div class='ff-t-cell '><div class='ff-el-group  ff-el-form-top'><div class=\"ff-el-input--label asterisk-right\"><label for='ff_4_names_first_name_' id='label_ff_4_names_first_name_' >First Name<\/label><\/div><div class='ff-el-input--content'><input type=\"text\" name=\"names[first_name]\" id=\"ff_4_names_first_name_\" class=\"ff-el-form-control\" aria-invalid=\"false\" aria-required=false><\/div><\/div><\/div><div class='ff-t-cell '><div class='ff-el-group  ff-el-form-top'><div class=\"ff-el-input--label asterisk-right\"><label for='ff_4_names_last_name_' id='label_ff_4_names_last_name_' >Last Name<\/label><\/div><div class='ff-el-input--content'><input type=\"text\" name=\"names[last_name]\" id=\"ff_4_names_last_name_\" class=\"ff-el-form-control\" aria-invalid=\"false\" aria-required=false><\/div><\/div><\/div><\/div><\/div><div class='ff-el-group ff-el-form-top'><div class=\"ff-el-input--label ff-el-is-required asterisk-right\"><label for='ff_4_email' id='label_ff_4_email' aria-label=\"Your Business Email\">Your Business Email<\/label><\/div><div class='ff-el-input--content'><input type=\"email\" name=\"email\" id=\"ff_4_email\" class=\"ff-el-form-control\" data-name=\"email\"  aria-invalid=\"false\" aria-required=true><\/div><\/div><div class='ff-el-group ff-text-left ff_submit_btn_wrapper'><button type=\"submit\" class=\"ff-btn ff-btn-submit ff-btn-md ff_btn_style\"  aria-label=\"Submit\">Submit<\/button><\/div><\/fieldset><\/form><div id='fluentform_4_errors' class='ff-errors-in-stack ff_form_instance_4_1 ff-form-loading_errors ff_form_instance_4_1_errors'><\/div><\/div>            <script type=\"text\/javascript\">\n                window.fluent_form_ff_form_instance_4_1 = {\"id\":\"4\",\"ajaxUrl\":\"https:\\\/\\\/serengetitech.com\\\/wp-admin\\\/admin-ajax.php\",\"settings\":{\"layout\":{\"labelPlacement\":\"top\",\"helpMessagePlacement\":\"with_label\",\"errorMessagePlacement\":\"inline\",\"asteriskPlacement\":\"asterisk-right\"},\"restrictions\":{\"denyEmptySubmission\":{\"enabled\":false}}},\"form_instance\":\"ff_form_instance_4_1\",\"form_id_selector\":\"fluentform_4\",\"rules\":{\"names[first_name]\":{\"required\":{\"value\":false,\"message\":\"This field is required\"}},\"names[middle_name]\":{\"required\":{\"value\":false,\"message\":\"This field is required\"}},\"names[last_name]\":{\"required\":{\"value\":false,\"message\":\"This field is required\"}},\"email\":{\"required\":{\"value\":true,\"message\":\"This field is required\"},\"email\":{\"value\":true,\"message\":\"This field must contain a valid email\"}},\"recaptcha\":[]},\"debounce_time\":300};\n                            <\/script>\n            <\/div><\/div><\/div><\/div><button class=\"kt-blocks-modal-link kt-modal-label-show\" data-modal-open=\"kt-target-modal_d7f8cb-f5\"><span class=\"kt-blocks-modal-link-inner\">Download our Checklist<\/span><\/button><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Spaghetti code. It means unstructured and difficult-to-maintain source code. In other words, it\u2019s a mess. It looks like a bowl of spaghetti instead of the beauty that code can (and should) be.<\/p>","protected":false},"author":1,"featured_media":499,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_seopress_robots_primary_cat":"","_seopress_titles_title":"","_seopress_titles_desc":"","_seopress_robots_index":"","inline_featured_image":false,"_kad_blocks_custom_css":"","_kad_blocks_head_custom_js":"","_kad_blocks_body_custom_js":"","_kad_blocks_footer_custom_js":"","editor_plus_copied_stylings":"{}","footnotes":""},"categories":[10],"tags":[],"class_list":["post-1559","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-business"],"acf":[],"taxonomy_info":{"category":[{"value":10,"label":"Business"}]},"featured_image_src_large":["https:\/\/cdn.shortpixel.ai\/spai\/q_glossy+ret_img+to_auto\/serengetitech.com\/wp-content\/uploads\/2020\/12\/spaghetti-code.jpg",992,620,false],"author_info":{"display_name":"Kris","author_link":"https:\/\/serengetitech.com\/de\/author\/kristianpepwebdigital-hr\/"},"comment_info":"","category_info":[{"term_id":10,"name":"Business","slug":"business","term_group":0,"term_taxonomy_id":10,"taxonomy":"category","description":"Business - blog section dedicated to business topics, both traditional ones and trends.","parent":0,"count":187,"filter":"raw","cat_ID":10,"category_count":187,"category_description":"Business - blog section dedicated to business topics, both traditional ones and trends.","cat_name":"Business","category_nicename":"business","category_parent":0}],"tag_info":false,"_links":{"self":[{"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/posts\/1559","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/comments?post=1559"}],"version-history":[{"count":0,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/posts\/1559\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/media\/499"}],"wp:attachment":[{"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/media?parent=1559"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/categories?post=1559"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/serengetitech.com\/de\/wp-json\/wp\/v2\/tags?post=1559"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}