{"id":3564,"date":"2022-01-05T08:16:52","date_gmt":"2022-01-05T08:16:52","guid":{"rendered":"http:\/\/the-codest.localhost\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/"},"modified":"2026-04-28T14:05:35","modified_gmt":"2026-04-28T14:05:35","slug":"ruby-on-rails-modularisointi-packwerkin-avulla-episodi-i","status":"publish","type":"post","link":"https:\/\/thecodest.co\/fi\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/","title":{"rendered":"Ruby on Rails:n modulaarisointi Packwerkin avulla Episode I"},"content":{"rendered":"<h2>Johdanto<\/h2>\n<p>Puhuakseni <strong>Packwerk<\/strong>, meid\u00e4n on ensin esitelt\u00e4v\u00e4 muutama k\u00e4site.<\/p>\n<ul>\n<li><b>Koheesio<\/b>: viittaa siihen, kuinka paljon moduulin tai luokan elementit kuuluvat yhteen.<\/li>\n<li><b>Kytkent\u00e4<\/b>: viittaa moduulien tai luokkien v\u00e4lisen riippuvuuden tasoon.<\/li>\n<li><b>Rajat<\/b>: viittaa esteisiin <a href=\"https:\/\/thecodest.co\/fi\/dictionary\/what-is-code-refactoring\/\">koodi<\/a>. T\u00e4ss\u00e4 tapauksessa koodirajalla tarkoitetaan saman koodipohjan eri osa-alueita.<\/li>\n<li><b>Modularisointi<\/b>: Prosessi, jossa ohjelmistoj\u00e4rjestelm\u00e4 jaetaan useisiin erillisiin moduuleihin, joista kukin toimii itsen\u00e4isesti.<\/li>\n<\/ul>\n<h2>Ongelmat<\/h2>\n<p>Kuten tied\u00e4mme, <strong><a href=\"https:\/\/thecodest.co\/fi\/blog\/hire-ror-developer\/\">Ruby<\/a><\/strong> ei tarjoa hyv\u00e4\u00e4 ratkaisua koodirajojen valvomiseksi. Voimme m\u00e4\u00e4ritt\u00e4\u00e4 n\u00e4kyvyyden, mutta kaikki riippuvuudet ladataan globaaliin nimiavaruuteen. Suurissa tai monoliittisissa sovelluksissa t\u00e4m\u00e4 rajojen puuttuminen aiheuttaa seuraavia ongelmia.<\/p>\n<ul>\n<li>V\u00e4h\u00e4inen yhteenkuuluvuus,<\/li>\n<li>Korkea kytkent\u00e4, <\/li>\n<li>Spagettikoodi.<\/li>\n<\/ul>\n<p>Yritt\u00e4ess\u00e4\u00e4n modulaarisoida Shopifyn monoliittia ja asettaa rajoja, he kokeilivat erilaisia ratkaisuja saavuttamatta odotettuja tuloksia:<br \/>\n- Yksityisten vakioiden asettaminen,<br \/>\n- Rajojen asettaminen jalokivien avulla,<br \/>\n- Testien avulla estet\u00e4\u00e4n komponenttien v\u00e4liset yhteydet,<br \/>\n- Rubyn modulaatio-jalokiven k\u00e4ytt\u00e4minen,<br \/>\n- Luominen <a href=\"https:\/\/thecodest.co\/fi\/dictionary\/microservices\/\">mikropalvelut<\/a>.<\/p>\n<p>Aikaisemmista yrityksist\u00e4 saadun tiedon avulla he p\u00e4\u00e4ttiv\u00e4t luoda oman ty\u00f6kalun: <strong>Packwerk<\/strong>.<\/p>\n<h2>Packwerk<\/h2>\n<h3>Mik\u00e4 on Packwerk?<\/h3>\n<p><strong>Packwerk<\/strong> on staattinen analyysity\u00f6kalu, jota k\u00e4ytet\u00e4\u00e4n rajaamaan ryhmien v\u00e4lisi\u00e4 <strong>Ruby<\/strong> tiedostot nimelt\u00e4 <strong>paketit<\/strong>.<\/p>\n<h3>Mik\u00e4 on paketti?<\/h3>\n<p>A <strong>paketti<\/strong> on kansio, joka sis\u00e4lt\u00e4\u00e4 automaattisesti ladattua koodia. Shopifyn <a href=\"https:\/\/thecodest.co\/fi\/blog\/how-to-hire-the-best-outsourced-development-team-for-a-scaleup\/\">joukkue<\/a> kannustaa k\u00e4ytt\u00e4m\u00e4\u00e4n parhaita suunnitteluk\u00e4yt\u00e4nt\u00f6j\u00e4 paketteja luodessaan.<br \/>\n- Meid\u00e4n pit\u00e4isi pakata yhteen asioita, joilla on korkea toiminnallinen <a href=\"https:\/\/en.wikipedia.org\/wiki\/Cohesion_(computer_science)\" rel=\"nofollow\">koheesio<\/a>,<\/p>\n<ul>\n<li>Pakettien tulisi olla suhteellisen l\u00f6yh\u00e4sti kytkettyj\u00e4 toisiinsa.<\/li>\n<\/ul>\n<h3>Rajatarkastusten tyypit<\/h3>\n<p>Voimme valvoa yksityisyyden suojaa ja riippuvuusrajoja, tarkistaa rajojen rikkomista ja syklisi\u00e4 riippuvuuksia.<\/p>\n<h2>Packwerk k\u00e4yt\u00e4nn\u00f6ss\u00e4<\/h2>\n<p>Paketteja luotaessa ei ole olemassa yht\u00e4 tietty\u00e4 tapaa j\u00e4sent\u00e4\u00e4 tai uudelleen j\u00e4sent\u00e4\u00e4 sovellusta. T\u00e4ss\u00e4 artikkelissa noudatamme l\u00e4hestymistapaa, jota ehdottaa<br \/>\nStephan Hagemann vuonna <em>Asteittainen modularisointi Ruby on <a href=\"https:\/\/thecodest.co\/fi\/blog\/ways-to-increase-your-rails-performance\/\">Kiskot<\/a><\/em>.<\/p>\n<h3>Valitse projekti<\/h3>\n<p>Voit luoda uuden <a href=\"https:\/\/thecodest.co\/fi\/dictionary\/why-do-projects-fail\/\">projekti<\/a> tai valitse jokin hankkeistasi. P\u00e4\u00e4tin k\u00e4ytt\u00e4\u00e4 avoimen l\u00e4hdekoodin projektia nimelt\u00e4  <a href=\"https:\/\/github.com\/codetriage\/codetriage\" rel=\"nofollow\">CodeTriage<\/a>. On t\u00e4rke\u00e4\u00e4 mainita, ett\u00e4 tarvitsemme Rails 6 -sovelluksen, koska <strong>Packwerk<\/strong> k\u00e4ytt\u00e4\u00e4 Zeitwerkia.<\/p>\n<h3>Packwerkin alustaminen<\/h3>\n<p>Ensin meid\u00e4n on lis\u00e4tt\u00e4v\u00e4 helmi Gemfileen seuraavasti <code>jalokivi 'packwerk'<\/code> ja aja sitten <code>niputtaa<\/code>konsolissa. Sitten olemme valmiita alustamaan helmi k\u00e4ynniss\u00e4 <code>packwerk init<\/code>.<\/p>\n<p>T\u00e4m\u00e4n j\u00e4lkeen huomaamme, ett\u00e4 <strong>Packwerk<\/strong> tuotti kolme tiedostoa <a href=\"https:\/\/thecodest.co\/fi\/blog\/why-us-companies-are-opting-for-polish-developers\/\">us<\/a>:<\/p>\n<ul>\n<li>\n<p><em>packwerk.yml<\/em><\/p>\n<\/li>\n<li>\n<p><em>package.yml<\/em><\/p>\n<\/li>\n<li>\n<p><em>taivutukset.yml<\/em><\/p>\n<\/li>\n<\/ul>\n<p><em>packwerk.yml<\/em> on konfigurointitiedosto <strong>Packwerk<\/strong> jossa m\u00e4\u00e4ritet\u00e4\u00e4n mukaan otetut ja pois j\u00e4tetyt tiedostot, luetellaan latauspolut, m\u00e4\u00e4ritell\u00e4\u00e4n taivutustiedosto ja muita asioita;<\/p>\n<p><em>package.yml<\/em> on paketin asetustiedosto. T\u00e4ss\u00e4 tiedostossa lis\u00e4\u00e4mme pakettimme rajoja koskevat asetukset. Mik\u00e4 tahansa kansio, jossa on package.yml, tunnistetaan paketiksi seuraavasti <strong>Packwerk<\/strong>. Siin\u00e4 kaikki, <strong>Packwerk<\/strong> loi ensimm\u00e4isen<br \/>\npaketti ja kutsumme sit\u00e4 <em>root<\/em> paketti.<\/p>\n<p><em>taivutukset.yml<\/em> on paikka, johon sijoitamme mukautetut taivutukset ja lyhenteet, jos k\u00e4yt\u00e4mme niit\u00e4.<\/p>\n<p>Lis\u00e4tietoa tiedostoista ja niiden konfiguraatiosta on osoitteessa<br \/>\n<a href=\"https:\/\/github.com\/Shopify\/packwerk\" rel=\"nofollow\">Packwerk<\/a>.<\/p>\n<h3>Packwerk ominaisuudet<\/h3>\n<p>Jotta modularisointi toimisi, tarvitsemme kolme perusominaisuutta: <em>nimetty s\u00e4ili\u00f6<\/em>, sen <em>sis\u00e4lt\u00f6<\/em>ja nimenomaisesti <em>riippuvuudet<\/em> muista <em>s\u00e4ili\u00f6t<\/em>. M\u00e4\u00e4ritell\u00e4\u00e4n siis n\u00e4m\u00e4 ominaisuudet <strong>Packwerk<\/strong>:<\/p>\n<ul>\n<li>\n<p><b>Nimi<\/b>: Paketin nimi on sen suhteellinen polku paketin juuresta.<br \/>\nsovellus.<\/p>\n<\/li>\n<li>\n<p><b>Sis\u00e4lt\u00f6<\/b>: Kun asetamme package.yml-tiedoston kansioon, kaikki kansiossa olevat tiedostot ovat nyt paketin sis\u00e4lt\u00f6\u00e4.<\/p>\n<\/li>\n<li>\n<p><b>Riippuvuudet<\/b>: Voimme m\u00e4\u00e4ritell\u00e4 riippuvuudet muista paketeista lis\u00e4\u00e4m\u00e4ll\u00e4 riippuvuusavaimen tiedostoon <em>package.yml<\/em>.<\/p>\n<\/li>\n<\/ul>\n<p>Toinen tiedosto, jota ei sis\u00e4llytet\u00e4 oletusarvoisesti, mutta jota suositellaan, on README. Siin\u00e4 on t\u00e4rke\u00e4\u00e4 antaa tietoa paketin k\u00e4yt\u00f6st\u00e4.<\/p>\n<p>Jakson I loppu <\/p>\n<p><a href=\"https:\/\/thecodest.co\/contact\"><img decoding=\"async\" src=\"\/app\/uploads\/2024\/05\/cta_2.jpeg\" alt=\"Digitaalisen tuotekehityksen konsultointi\" \/><\/a><\/p>\n<p><strong>Lue lis\u00e4\u00e4<\/strong><\/p>\n<p><a href=\"https:\/\/thecodest.co\/blog\/graphql-ruby-what-about-performance\">GraphQL Ruby. Ent\u00e4 suorituskyky?<\/a><\/p>\n<p><a href=\"https:\/\/thecodest.co\/blog\/rails-and-other-means-of-transport\">Kiskot ja muut liikennev\u00e4lineet<\/a><\/p>\n<p><a href=\"https:\/\/thecodest.co\/blog\/rails-development-with-tmux-vim-fzf-ripgrep\">Rails-kehitys TMUX, Vim, Fzf + Ripgrep -ohjelmilla<\/a><\/p>","protected":false},"excerpt":{"rendered":"<p>Ihmisten on vaikea n\u00e4hd\u00e4 ongelman kokonaiskuvaa ilman, ett\u00e4 he k\u00e4ytt\u00e4v\u00e4t paljon aikaa ja vaivaa. N\u00e4in tapahtuu erityisesti silloin, kun ty\u00f6skennell\u00e4\u00e4n suurten ja monimutkaisten sovellusten parissa. Mitk\u00e4 ovat muutosteni sivuvaikutukset? Miksi t\u00e4m\u00e4 rivi t\u00e4ss\u00e4 vaikuttaa koodipohjan kaukaisen osan testeihin? T\u00e4ydellist\u00e4 tai t\u00e4ydellist\u00e4 ratkaisua ei ole olemassa, mutta Shopify julkaisi ty\u00f6kalun, joka todenn\u00e4k\u00f6isesti auttaa sinua ja tiimi\u00e4si.<\/p>","protected":false},"author":2,"featured_media":3565,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[8],"tags":[],"class_list":["post-3564","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-software-development"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.3 (Yoast SEO v27.3) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Ruby on Rails modularization with Packwerk Episode I - The Codest<\/title>\n<meta name=\"description\" content=\"Humans find it difficult to see the big picture of a problem without devoting a lot of time and effort. This happens especially while working with large and complex applications. What are the side effects of my changes? Why is this line here affecting the tests of a remote part of the codebase? A perfect or complete solution does not exist, but Shopify came out with a tool that will probably help you and your team.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/thecodest.co\/fi\/blogi\/ruby-on-rails-modularisointi-packwerkin-avulla-episodi-i\/\" \/>\n<meta property=\"og:locale\" content=\"fi_FI\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Ruby on Rails modularization with Packwerk Episode I\" \/>\n<meta property=\"og:description\" content=\"Humans find it difficult to see the big picture of a problem without devoting a lot of time and effort. This happens especially while working with large and complex applications. What are the side effects of my changes? Why is this line here affecting the tests of a remote part of the codebase? A perfect or complete solution does not exist, but Shopify came out with a tool that will probably help you and your team.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/thecodest.co\/fi\/blogi\/ruby-on-rails-modularisointi-packwerkin-avulla-episodi-i\/\" \/>\n<meta property=\"og:site_name\" content=\"The Codest\" \/>\n<meta property=\"article:published_time\" content=\"2022-01-05T08:16:52+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-04-28T14:05:35+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png\" \/>\n\t<meta property=\"og:image:width\" content=\"960\" \/>\n\t<meta property=\"og:image:height\" content=\"540\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"thecodest\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"thecodest\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minuuttia\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/\"},\"author\":{\"name\":\"thecodest\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/#\\\/schema\\\/person\\\/7e3fe41dfa4f4e41a7baad4c6e0d4f76\"},\"headline\":\"Ruby on Rails modularization with Packwerk Episode I\",\"datePublished\":\"2022-01-05T08:16:52+00:00\",\"dateModified\":\"2026-04-28T14:05:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/\"},\"wordCount\":650,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/05\\\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png\",\"articleSection\":[\"Software Development\"],\"inLanguage\":\"fi\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/\",\"url\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/\",\"name\":\"Ruby on Rails modularization with Packwerk Episode I - The Codest\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/05\\\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png\",\"datePublished\":\"2022-01-05T08:16:52+00:00\",\"dateModified\":\"2026-04-28T14:05:35+00:00\",\"description\":\"Humans find it difficult to see the big picture of a problem without devoting a lot of time and effort. This happens especially while working with large and complex applications. What are the side effects of my changes? Why is this line here affecting the tests of a remote part of the codebase? A perfect or complete solution does not exist, but Shopify came out with a tool that will probably help you and your team.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#breadcrumb\"},\"inLanguage\":\"fi\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"fi\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#primaryimage\",\"url\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/05\\\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png\",\"contentUrl\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/05\\\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png\",\"width\":960,\"height\":540},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/blog\\\/ruby-on-rails-modularization-with-packwerk-episode-i\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/thecodest.co\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Ruby on Rails modularization with Packwerk Episode I\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/#website\",\"url\":\"https:\\\/\\\/thecodest.co\\\/\",\"name\":\"The Codest\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/thecodest.co\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"fi\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/#organization\",\"name\":\"The Codest\",\"url\":\"https:\\\/\\\/thecodest.co\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"fi\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/03\\\/thecodest-logo.svg\",\"contentUrl\":\"https:\\\/\\\/thecodest.co\\\/app\\\/uploads\\\/2024\\\/03\\\/thecodest-logo.svg\",\"width\":144,\"height\":36,\"caption\":\"The Codest\"},\"image\":{\"@id\":\"https:\\\/\\\/thecodest.co\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/pl.linkedin.com\\\/company\\\/codest\",\"https:\\\/\\\/clutch.co\\\/profile\\\/codest\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/thecodest.co\\\/#\\\/schema\\\/person\\\/7e3fe41dfa4f4e41a7baad4c6e0d4f76\",\"name\":\"thecodest\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"fi\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g\",\"caption\":\"thecodest\"},\"url\":\"https:\\\/\\\/thecodest.co\\\/fi\\\/author\\\/thecodest\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Ruby on Rails modulaarisointi Packwerkin avulla Episode I - The Codest - The Codest","description":"Ihmisten on vaikea n\u00e4hd\u00e4 ongelman kokonaiskuvaa ilman, ett\u00e4 he k\u00e4ytt\u00e4v\u00e4t paljon aikaa ja vaivaa. N\u00e4in tapahtuu erityisesti silloin, kun ty\u00f6skennell\u00e4\u00e4n suurten ja monimutkaisten sovellusten parissa. Mitk\u00e4 ovat muutosteni sivuvaikutukset? Miksi t\u00e4m\u00e4 rivi t\u00e4ss\u00e4 vaikuttaa koodipohjan kaukaisen osan testeihin? T\u00e4ydellist\u00e4 tai t\u00e4ydellist\u00e4 ratkaisua ei ole olemassa, mutta Shopify julkaisi ty\u00f6kalun, joka todenn\u00e4k\u00f6isesti auttaa sinua ja tiimi\u00e4si.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/thecodest.co\/fi\/blogi\/ruby-on-rails-modularisointi-packwerkin-avulla-episodi-i\/","og_locale":"fi_FI","og_type":"article","og_title":"Ruby on Rails modularization with Packwerk Episode I","og_description":"Humans find it difficult to see the big picture of a problem without devoting a lot of time and effort. This happens especially while working with large and complex applications. What are the side effects of my changes? Why is this line here affecting the tests of a remote part of the codebase? A perfect or complete solution does not exist, but Shopify came out with a tool that will probably help you and your team.","og_url":"https:\/\/thecodest.co\/fi\/blogi\/ruby-on-rails-modularisointi-packwerkin-avulla-episodi-i\/","og_site_name":"The Codest","article_published_time":"2022-01-05T08:16:52+00:00","article_modified_time":"2026-04-28T14:05:35+00:00","og_image":[{"width":960,"height":540,"url":"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png","type":"image\/png"}],"author":"thecodest","twitter_card":"summary_large_image","twitter_misc":{"Written by":"thecodest","Est. reading time":"4 minuuttia"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#article","isPartOf":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/"},"author":{"name":"thecodest","@id":"https:\/\/thecodest.co\/#\/schema\/person\/7e3fe41dfa4f4e41a7baad4c6e0d4f76"},"headline":"Ruby on Rails modularization with Packwerk Episode I","datePublished":"2022-01-05T08:16:52+00:00","dateModified":"2026-04-28T14:05:35+00:00","mainEntityOfPage":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/"},"wordCount":650,"commentCount":0,"publisher":{"@id":"https:\/\/thecodest.co\/#organization"},"image":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#primaryimage"},"thumbnailUrl":"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png","articleSection":["Software Development"],"inLanguage":"fi","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/","url":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/","name":"Ruby on Rails modulaarisointi Packwerkin avulla Episode I - The Codest - The Codest","isPartOf":{"@id":"https:\/\/thecodest.co\/#website"},"primaryImageOfPage":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#primaryimage"},"image":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#primaryimage"},"thumbnailUrl":"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png","datePublished":"2022-01-05T08:16:52+00:00","dateModified":"2026-04-28T14:05:35+00:00","description":"Ihmisten on vaikea n\u00e4hd\u00e4 ongelman kokonaiskuvaa ilman, ett\u00e4 he k\u00e4ytt\u00e4v\u00e4t paljon aikaa ja vaivaa. N\u00e4in tapahtuu erityisesti silloin, kun ty\u00f6skennell\u00e4\u00e4n suurten ja monimutkaisten sovellusten parissa. Mitk\u00e4 ovat muutosteni sivuvaikutukset? Miksi t\u00e4m\u00e4 rivi t\u00e4ss\u00e4 vaikuttaa koodipohjan kaukaisen osan testeihin? T\u00e4ydellist\u00e4 tai t\u00e4ydellist\u00e4 ratkaisua ei ole olemassa, mutta Shopify julkaisi ty\u00f6kalun, joka todenn\u00e4k\u00f6isesti auttaa sinua ja tiimi\u00e4si.","breadcrumb":{"@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#breadcrumb"},"inLanguage":"fi","potentialAction":[{"@type":"ReadAction","target":["https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/"]}]},{"@type":"ImageObject","inLanguage":"fi","@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#primaryimage","url":"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png","contentUrl":"https:\/\/thecodest.co\/app\/uploads\/2024\/05\/ruby_on_rails_modularization_with_packwerk_-_episode_1.png","width":960,"height":540},{"@type":"BreadcrumbList","@id":"https:\/\/thecodest.co\/blog\/ruby-on-rails-modularization-with-packwerk-episode-i\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/thecodest.co\/"},{"@type":"ListItem","position":2,"name":"Ruby on Rails modularization with Packwerk Episode I"}]},{"@type":"WebSite","@id":"https:\/\/thecodest.co\/#website","url":"https:\/\/thecodest.co\/","name":"Codest","description":"","publisher":{"@id":"https:\/\/thecodest.co\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/thecodest.co\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"fi"},{"@type":"Organization","@id":"https:\/\/thecodest.co\/#organization","name":"Codest","url":"https:\/\/thecodest.co\/","logo":{"@type":"ImageObject","inLanguage":"fi","@id":"https:\/\/thecodest.co\/#\/schema\/logo\/image\/","url":"https:\/\/thecodest.co\/app\/uploads\/2024\/03\/thecodest-logo.svg","contentUrl":"https:\/\/thecodest.co\/app\/uploads\/2024\/03\/thecodest-logo.svg","width":144,"height":36,"caption":"The Codest"},"image":{"@id":"https:\/\/thecodest.co\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/pl.linkedin.com\/company\/codest","https:\/\/clutch.co\/profile\/codest"]},{"@type":"Person","@id":"https:\/\/thecodest.co\/#\/schema\/person\/7e3fe41dfa4f4e41a7baad4c6e0d4f76","name":"thecodest","image":{"@type":"ImageObject","inLanguage":"fi","@id":"https:\/\/secure.gravatar.com\/avatar\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5dbfe6a1e8c86e432e8812759e34e6fe82ebac75119ae3237a6c1311fa19caf4?s=96&d=mm&r=g","caption":"thecodest"},"url":"https:\/\/thecodest.co\/fi\/author\/thecodest\/"}]}},"_links":{"self":[{"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/posts\/3564","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/comments?post=3564"}],"version-history":[{"count":5,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/posts\/3564\/revisions"}],"predecessor-version":[{"id":7982,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/posts\/3564\/revisions\/7982"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/media\/3565"}],"wp:attachment":[{"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/media?parent=3564"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/categories?post=3564"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/thecodest.co\/fi\/wp-json\/wp\/v2\/tags?post=3564"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}