mastodontech.de ist einer von vielen unabhängigen Mastodon-Servern, mit dem du dich im Fediverse beteiligen kannst.
Offen für alle (über 16) und bereitgestellt von Markus'Blog

Serverstatistik:

1,4 Tsd.
aktive Profile

#activerecord

0 Beiträge0 Beteiligte0 Beiträge heute
Jason Garber<p>With <a href="https://indieweb.social/tags/RubyOnRails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RubyOnRails</span></a>, you can check an <a href="https://indieweb.social/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> object’s validations on an attribute using `object.class.validators_on(attribute)`.</p><p>The result is an array of validator classes, most of which include an `options` method with the configured options from the definition in the model.</p><p>Is it possible to filter out conditional validations from the returned array?</p><p>(I have a conditional validation on an attribute and would like to know when it doesn’t apply to a particular instance of the model.)</p>
WNB.rb<p>⏰ Just one hour away, our June online meetup is starting ⏰ <br>Join us today at 12pm Eastern for An ActiveRecord Rewrite: the Story Behind the Attributes API talk from Tess Griffin! Find us and the meetup link on discord: <a href="https://discord.gg/KfBeRSjK?event=1384536117914894458" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">discord.gg/KfBeRSjK?event=1384</span><span class="invisible">536117914894458</span></a> </p><p><a href="https://ruby.social/tags/online" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>online</span></a> <a href="https://ruby.social/tags/meetup" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>meetup</span></a> <a href="https://ruby.social/tags/ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ruby</span></a> <a href="https://ruby.social/tags/rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rails</span></a> <a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a></p>
postmodern<p>JRuby's activerecord-jdbc-adapter doesn't yet support ActiveRecord 8. How should a gem which depends on ActiveRecord try to best support both CRuby and JRuby?<br><a href="https://rubygems.org/gems/activerecord-jdbc-adapter/versions/71.0-java" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">rubygems.org/gems/activerecord</span><span class="invisible">-jdbc-adapter/versions/71.0-java</span></a></p><p><a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://ruby.social/tags/jruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>jruby</span></a></p>
alexanderadam<p>Now we got Jess Sullivan with her talk "ActiveRecord Unveiled: Mastering Rails' ORM"</p><p><span class="h-card" translate="no"><a href="https://bird.makeup/users/jm_sully" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>jm_sully</span></a></span></p><p><a href="https://ruby.social/tags/HelveticRuby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>HelveticRuby</span></a> <a href="https://ruby.social/tags/HelveticRuby2025" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>HelveticRuby2025</span></a><br><a href="https://ruby.social/tags/rubycommunity" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubycommunity</span></a> <a href="https://ruby.social/tags/rubyconferences" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubyconferences</span></a> <a href="https://ruby.social/tags/rubyconference" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubyconference</span></a> <a href="https://ruby.social/tags/ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ruby</span></a> <a href="https://ruby.social/tags/rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rails</span></a> <a href="https://ruby.social/tags/rubyonrails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubyonrails</span></a> <a href="https://ruby.social/tags/geneva" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>geneva</span></a> <a href="https://ruby.social/tags/switzerland" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>switzerland</span></a> <a href="https://ruby.social/tags/schweiz" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>schweiz</span></a> <a href="https://ruby.social/tags/genf" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>genf</span></a> <a href="https://ruby.social/tags/RubyProgramming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RubyProgramming</span></a> <a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://ruby.social/tags/database" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>database</span></a> <a href="https://ruby.social/tags/databases" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>databases</span></a> <a href="https://ruby.social/tags/activestorage" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activestorage</span></a> <a href="https://ruby.social/tags/orm" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>orm</span></a> <a href="https://ruby.social/tags/objectrelationalmappers" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>objectrelationalmappers</span></a> <a href="https://ruby.social/tags/carrierwave" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>carrierwave</span></a> <a href="https://ruby.social/tags/carrierwaveuploader" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>carrierwaveuploader</span></a></p>
LavX News<p>Navigating Complexity in B2B SaaS Development: The Case for Custom Frameworks</p><p>As the landscape of software development evolves, particularly in the realm of B2B SaaS, developers face unique challenges like multi-tenancy and the 'noisy neighbor' problem. This article explores th...</p><p><a href="https://news.lavx.hu/article/navigating-complexity-in-b2b-saas-development-the-case-for-custom-frameworks" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">news.lavx.hu/article/navigatin</span><span class="invisible">g-complexity-in-b2b-saas-development-the-case-for-custom-frameworks</span></a></p><p><a href="https://ioc.exchange/tags/news" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>news</span></a> <a href="https://ioc.exchange/tags/tech" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>tech</span></a> <a href="https://ioc.exchange/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> <a href="https://ioc.exchange/tags/TigerBeetle" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>TigerBeetle</span></a> <a href="https://ioc.exchange/tags/B2BSaaS" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>B2BSaaS</span></a></p>
Hacker News<p>Shardines: SQLite3 Database-per-Tenant with ActiveRecord</p><p><a href="https://blog.julik.nl/2025/04/a-can-of-shardines" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">blog.julik.nl/2025/04/a-can-of</span><span class="invisible">-shardines</span></a></p><p><a href="https://mastodon.social/tags/HackerNews" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>HackerNews</span></a> <a href="https://mastodon.social/tags/Shardines" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Shardines</span></a> <a href="https://mastodon.social/tags/SQLite3" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SQLite3</span></a> <a href="https://mastodon.social/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> <a href="https://mastodon.social/tags/DatabasePerTenant" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>DatabasePerTenant</span></a> <a href="https://mastodon.social/tags/HackerNews" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>HackerNews</span></a></p>
Esparta :ruby:<p>Wide Models and Active Record custom validation contexts, by <span class="h-card" translate="no"><a href="https://ruby.social/@bensheldon" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>bensheldon</span></a></span></p><p><a href="https://island94.org/2025/04/wide-models-and-active-record-custom-validation-contexts" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">island94.org/2025/04/wide-mode</span><span class="invisible">ls-and-active-record-custom-validation-contexts</span></a></p><p>&gt; This post is a brief description of a pattern I use a lot using when building features in Ruby on Rails apps and that I think needed a name:</p><p>&gt; Wide Models have many attributes (columns in the database) that are updated in multiple places in the application, but not always all at once i.e. different forms will update different subsets of attributes on the same model.</p><p><a href="https://ruby.social/tags/ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ruby</span></a> <a href="https://ruby.social/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a></p>
alexanderadam<p>It's always great to see <span class="h-card" translate="no"><a href="https://tu.social/@rosa" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>rosa</span></a></span> and she talked about her <a href="https://ruby.social/tags/SolidQueue" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SolidQueue</span></a> implementation at <a href="https://ruby.social/tags/rubycommunityconference" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubycommunityconference</span></a> in <a href="https://ruby.social/tags/krakow" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>krakow</span></a>.</p><p>She also gave a shout-out to <span class="h-card" translate="no"><a href="https://ruby.social/@bensheldon" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>bensheldon</span></a></span>'s <a href="https://ruby.social/tags/goodjob" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>goodjob</span></a> and mentioned how <span class="h-card" translate="no"><a href="https://ruby.social/@getajobmike" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>getajobmike</span></a></span>'s <span class="h-card" translate="no"><a href="https://ruby.social/@sidekiq" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>sidekiq</span></a></span> is blazingly fast.</p><p><a href="https://ruby.social/tags/ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ruby</span></a> <a href="https://ruby.social/tags/rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rails</span></a> <a href="https://ruby.social/tags/queue" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>queue</span></a> <a href="https://ruby.social/tags/rubyonrails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubyonrails</span></a> <a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://ruby.social/tags/poland" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>poland</span></a> <a href="https://ruby.social/tags/37signals" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>37signals</span></a> <a href="https://ruby.social/tags/backgroundprocessing" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>backgroundprocessing</span></a> <a href="https://ruby.social/tags/backgroundprocesses" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>backgroundprocesses</span></a> <a href="https://ruby.social/tags/sidekiq" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sidekiq</span></a></p>
Honeybadger.io<p>New from Julie Kent:</p><p>Imaging you have a Rails endpoint that has slow queries AND performs third-party HTTP requests. With Rails async queries, you can perform these operations in parallel—without being an expert in multithreading. 🚀</p><p><a href="https://www.honeybadger.io/blog/rails-async-queries/?utm_source=mastodon&amp;utm_medium=social" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://www.</span><span class="ellipsis">honeybadger.io/blog/rails-asyn</span><span class="invisible">c-queries/?utm_source=mastodon&amp;utm_medium=social</span></a></p><p><a href="https://honeybadger.social/tags/Ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Ruby</span></a> <a href="https://honeybadger.social/tags/RubyOnRails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RubyOnRails</span></a> <a href="https://honeybadger.social/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> <a href="https://honeybadger.social/tags/Performance" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Performance</span></a> <a href="https://honeybadger.social/tags/Programming" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Programming</span></a></p>
Todd A. Jacobs | Rubyist<p>I know <a href="https://ruby.social/tags/SQLite3" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SQLite3</span></a> supports <a href="https://ruby.social/tags/SQL" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SQL</span></a> comments in newer versions with the right flags, but `rails g` for <a href="https://ruby.social/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> ďoesn’t seem to support them except in <a href="https://ruby.social/tags/PostgreSQL" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>PostgreSQL</span></a> or <a href="https://ruby.social/tags/MySQL" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MySQL</span></a> / <a href="https://ruby.social/tags/MariaDB" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MariaDB</span></a>. Is there a workaround?</p>
Clairement crevée<p>ok, <a href="https://social.sitedethib.com/tags/Rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Rails</span></a> <a href="https://social.sitedethib.com/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> thing:</p><p>Some people upgrading to Mastodon 4.3.0 seem to have messed up their migration relating to Active Record Encryption, by changing the secrets at some point after they first used them.</p><p>Of course since the keys have changed, the encrypted columns are irrevocably lost, and nothing can be done about that. But is there something we can do to lessen the risks of people running into that by catching the issue earlier?</p><p>Also, even overwriting those attributes is not possible in normal Rails code because <code>save!</code>ing will call <code>attribute_changed?</code> which will in turn try to decrypt the value to compare it, and raise an exception. Is there a way we can better handle columns that fail to decrypt when we are just interested in overriding them?</p>
:rss: Qiita - 人気の記事<p>Railsで使われるテーブル結合方法について<br><a href="https://qiita.com/k12da/items/2ea1b4196790f3ea9f3a?utm_campaign=popular_items&amp;utm_medium=feed&amp;utm_source=popular_items" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">qiita.com/k12da/items/2ea1b419</span><span class="invisible">6790f3ea9f3a?utm_campaign=popular_items&amp;utm_medium=feed&amp;utm_source=popular_items</span></a></p><p><a href="https://rss-mstdn.studiofreesia.com/tags/qiita" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>qiita</span></a> <a href="https://rss-mstdn.studiofreesia.com/tags/Rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Rails</span></a> <a href="https://rss-mstdn.studiofreesia.com/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> <a href="https://rss-mstdn.studiofreesia.com/tags/SQL" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>SQL</span></a></p>
d33p.js<p>Am I the only one that dont like other ORMs than Rails Active Record? I mean, FastAPI's SQLAlchemy, SQLModel in combination with pydantic as well as Symfonys Doctrine feels a little bit pain in the a** when it comes to complex relations. Active Record just feels smooth compared to the other ones...</p><p><a href="https://infosec.exchange/tags/rubyonrails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rubyonrails</span></a> <a href="https://infosec.exchange/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://infosec.exchange/tags/fastapi" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>fastapi</span></a> <a href="https://infosec.exchange/tags/sqlalchemy" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sqlalchemy</span></a> <a href="https://infosec.exchange/tags/sqlmodel" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sqlmodel</span></a> <a href="https://infosec.exchange/tags/pydantic" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>pydantic</span></a> <a href="https://infosec.exchange/tags/doctrine" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>doctrine</span></a> <a href="https://infosec.exchange/tags/symfony" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>symfony</span></a> <a href="https://infosec.exchange/tags/python" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>python</span></a> <a href="https://infosec.exchange/tags/orm" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>orm</span></a> <a href="https://infosec.exchange/tags/database" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>database</span></a></p>
postmodern<p>Why is ActiveRecord &gt; 7.1 still broken on JRuby? Appears activerecord-jdbc-adapter still hasn't been updated.<br><a href="https://github.com/ronin-rb/ronin-db-activerecord/actions/runs/9264533331/job/25484805001" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">github.com/ronin-rb/ronin-db-a</span><span class="invisible">ctiverecord/actions/runs/9264533331/job/25484805001</span></a><br><a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://ruby.social/tags/jruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>jruby</span></a></p>
postmodern<p>How do you safely close the sqlite3 database file when using ActiveRecord in a Sinatra app? Doling a Ctrl^C results in the sqlite3 lock files being left behind.<br><a href="https://ruby.social/tags/sinatra" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sinatra</span></a> <a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a></p>
postmodern<p>What do people prefer for ensuring that ActiveRecord connections get freed (in a Sinatra app)?<br><a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a> <a href="https://ruby.social/tags/sidekiq" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sidekiq</span></a> <a href="https://ruby.social/tags/sinatra" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>sinatra</span></a></p>
postmodern<p>Why do I keep getting this error with ActiveRecord in this Sinatra+Sidekiq app:</p><p>could not obtain a connection from the pool within 5.000 seconds (waited 5.000 seconds); all pooled connections were in use</p><p>I'm already passing `pool: 4` to `ActiveRecord::Base.establish_connect(...)` to set the connection pool size, which is what Google/StackOverflow recommends, but it's still randomly occurring.<br><a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a></p>
robrich<p><a href="https://dev.to/jordantaylorj/ruby-active-record-2d4b" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">dev.to/jordantaylorj/ruby-acti</span><span class="invisible">ve-record-2d4b</span></a> - <a href="https://hachyderm.io/tags/Ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Ruby</span></a>'s <a href="https://hachyderm.io/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> is elegantly simple and immensely powerful. Thanks for learning in public <a href="https://www.linkedin.com/in/jordantjoseph/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://www.</span><span class="">linkedin.com/in/jordantjoseph/</span><span class="invisible"></span></a></p>
Jack of all trades<p>ActiveRecord's callback hell is worse than JavaScript's callback hell.</p><p>Prove me wrong.</p><p><a href="https://mas.to/tags/rails" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rails</span></a> <a href="https://mas.to/tags/ruby" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ruby</span></a> <a href="https://mas.to/tags/callbacks" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>callbacks</span></a> <a href="https://mas.to/tags/CallbackHell" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>CallbackHell</span></a> <a href="https://mas.to/tags/ActiveRecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>ActiveRecord</span></a> <a href="https://mas.to/tags/javascript" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>javascript</span></a></p>
postmodern<p>Lazy ActiveRecord: can you use query class-methods defined in another model from within where() statements when doing deep joins() from a different model?</p><p>class Bar &lt; ActiveRecord::Base<br> def self.with_baz(value)<br> ...<br> end<br>end</p><p>class Thing &lt; ActiveRecord::Base<br> def self.bars_with_baz(value)<br> joins(foo: [:bar]).where(<br> foo: {<br> bar: {with_baz: value}<br> }<br> )<br> end<br>end</p><p><a href="https://ruby.social/tags/activerecord" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>activerecord</span></a></p>