<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Jonathan Julian's Blog - Latest Comments</title><link>http://jonathanjulian.disqus.com/</link><description></description><atom:link href="https://jonathanjulian.disqus.com/comments.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 08 Apr 2025 16:55:58 -0000</lastBuildDate><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-6684908797</link><description>&lt;p&gt;WhatsApp&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Arvind kr </dc:creator><pubDate>Tue, 08 Apr 2025 16:55:58 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-4804511179</link><description>&lt;p&gt;Still a very helpful post :D&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Francisco Quintero</dc:creator><pubDate>Fri, 21 Feb 2020 13:12:38 -0000</pubDate></item><item><title>Re: Testing SNMP traps with snmptrapd</title><link>http://jonathanjulian.com/2008/07/testing-snmp-traps-with-snmptrapd/#comment-4386436219</link><description>&lt;p&gt;For Example -&amp;gt; I have requirement where I need to receive snmp traps from two different source and write those traps messages in two different log files? Please suggest what is the best way to do this?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Arun Sunny T M</dc:creator><pubDate>Wed, 20 Mar 2019 08:08:07 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-3981346970</link><description>&lt;p&gt;Yes, I approve.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jjulian</dc:creator><pubDate>Mon, 09 Jul 2018 22:37:45 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-3981326936</link><description>&lt;p&gt;8 year latter... This honors options hash:&lt;br&gt;def as_json(options={})&lt;br&gt;  super({ only: [:email, :avatar] }.merge(options))&lt;br&gt;end&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Isaac Franco Fernandes</dc:creator><pubDate>Mon, 09 Jul 2018 22:18:35 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-3879543449</link><description>&lt;p&gt;Quick tip, you need to have the `options = {}` param when you use this method, otherwise you get the following error:&lt;/p&gt;&lt;p&gt;`wrong number of arguments (given 1, expected 0)`&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">joshuapinter</dc:creator><pubDate>Mon, 30 Apr 2018 12:50:40 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-3007482643</link><description>&lt;p&gt;Broken link – that page has moved to &lt;a href="http://ternarylabs.com/2010/09/07/migrating-to-rails-3-0-gotchas-as_json-bug/" rel="nofollow noopener" target="_blank" title="http://ternarylabs.com/2010/09/07/migrating-to-rails-3-0-gotchas-as_json-bug/"&gt;http://ternarylabs.com/2010...&lt;/a&gt;.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Rory</dc:creator><pubDate>Thu, 17 Nov 2016 17:08:01 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-1856901945</link><description>&lt;p&gt;5 years later and still a valuable article. Thank you for posting, Jonathan.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stan Carver II</dc:creator><pubDate>Sun, 15 Feb 2015 13:56:04 -0000</pubDate></item><item><title>Re: Fastly and Rails - Jonathan Julian</title><link>http://jonathanjulian.com/2015/01/fastly-rails/#comment-1817978509</link><description>&lt;p&gt;Setting Cache-Control: no-store tells browsers to re-fetch the resource on *every* page view. This makes pages slow for end users. Using Cache-Control: no-cache makes sense for *dynamic* content (HTML, JSON), but it's better to use max-age=86400 for *static* content (images, scripts, etc.). Adding Stale-While-Revalidate makes pages even faster.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">souders</dc:creator><pubDate>Mon, 26 Jan 2015 13:04:38 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-1782988351</link><description>&lt;p&gt;Thanks! Really helpful and clear explanation.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">latazzajones</dc:creator><pubDate>Fri, 09 Jan 2015 14:02:45 -0000</pubDate></item><item><title>Re: Testing SNMP traps with snmptrapd</title><link>http://jonathanjulian.com/2008/07/testing-snmp-traps-with-snmptrapd/#comment-1184376405</link><description>&lt;p&gt;Hey Jonathan, atlantageek here.  Could you change the link you reference to this: &lt;a href="http://www.atlantageek.com/2008/02/27/snmp-and-ruby/" rel="nofollow noopener" target="_blank" title="http://www.atlantageek.com/2008/02/27/snmp-and-ruby/"&gt;http://www.atlantageek.com/...&lt;/a&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">atlantageek</dc:creator><pubDate>Thu, 02 Jan 2014 12:13:00 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-1169971422</link><description>&lt;p&gt;to_json&lt;br&gt;That's the reason I got lost my parameters when I tested my Restful API&lt;br&gt;After changing it to as_json, all problems are gone.&lt;br&gt;Really helpful. Thanks.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">sgwanlee</dc:creator><pubDate>Thu, 19 Dec 2013 06:49:12 -0000</pubDate></item><item><title>Re: Testing SNMP traps with snmptrapd</title><link>http://jonathanjulian.com/2008/07/testing-snmp-traps-with-snmptrapd/#comment-950480423</link><description>&lt;p&gt;Thank you very much, even if the post is a bit old, it helped me a lot ! =)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Ata</dc:creator><pubDate>Wed, 03 Jul 2013 08:30:41 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-859133491</link><description>&lt;p&gt;You saved me a ton of nerves with as_json :)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Иван</dc:creator><pubDate>Wed, 10 Apr 2013 19:25:45 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-754788376</link><description>&lt;p&gt;"Winners: working prototype, signed up users, contracts signed. Not winners: slide decks, mock-ups, great ideas with zero execution." &lt;/p&gt;&lt;p&gt;This is an excellent point—winners should be selected as a proper reflection of the weekend's work and their use/misuse of the time to actually make something. Embedded in that critique is also a clue to why winners often get selected without prototypes or users. It's a reward for their presentation and perceived polish. I think it is a judging panel's job to weight things more appropriately like what you're suggesting. To not just award the presentation, but the current stage of executed product (and its evolution over the course of the event). After the recent Startup Weekend EDU I was thinking about how if it had been a 48 hour film competition, instead of screening a short film some of the winners had stood up at the end with a script for a feature and some cool concept art... but NOT a movie. That makes me sound a bit like a sore loser (since I was not on a winning team). I'm not that. I liked the winners' ideas and execution, but I saw a disconnect between an award for the weekend and an award for the scope of the idea and the presentation.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Chris Coy</dc:creator><pubDate>Thu, 03 Jan 2013 14:38:25 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-741954757</link><description>&lt;p&gt;I can't agree more with you Shawn! It was my first hackathon too, but I wasn't able to fully experience it from the attendee point of view since I was one of the four organizers. I think back to the key tenants of that event: Meet People, Build Stuff, Have Fun. My expectations of every other event are driven by those. We had great people, excellent projects, and we all had a fantastic weekend.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jjulian</dc:creator><pubDate>Tue, 18 Dec 2012 13:07:18 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-741948724</link><description>&lt;p&gt;Ah yes, Groundwork should be on the list. Are there any other events I've missed?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jjulian</dc:creator><pubDate>Tue, 18 Dec 2012 13:02:00 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-741947600</link><description>&lt;p&gt;That's a great point, Kate. Not every event can be inviting to youth (I'm thinking Startup Weekend), but the more exploratory and "fun" events should definitely make children welcome. The kids at ArtBytes seemed to have fun exploring the museum and 3D printing.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jjulian</dc:creator><pubDate>Tue, 18 Dec 2012 13:01:01 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-741284467</link><description>&lt;p&gt;So many good points in this article.  My favorite event that was ever held was the First Baltimore Hackathon.  It was my introduction to the Baltimore Tech Community (despite having lived here all my life and being in the tech field professionally for 12 years by that point).  It was exactly what I wanted to get out of an event as a developer: Low pressure, more about hanging out and working on cool things than building a business or winning a competition.  It gave me a chance to set aside time to work on something that I thought was cool but I didn't feel any pressure if I totally bombed at it.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Shawn Grimes</dc:creator><pubDate>Mon, 17 Dec 2012 21:51:28 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-740880787</link><description>&lt;p&gt;Sage counsel. I second Kate's recommendation about youth involvement. At Groundwork (another one for your list at the end &lt;a href="http://gb.tc/events/groundwork" rel="nofollow noopener" target="_blank" title="http://gb.tc/events/groundwork"&gt;http://gb.tc/events/groundwork&lt;/a&gt; ) Eliot Pearson's son and my daughter played a lot of Minecraft, but also soaked up the geeky atmosphere while creating artwork that went to award-winning teams.&lt;br&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andrew Hazlett</dc:creator><pubDate>Mon, 17 Dec 2012 11:42:32 -0000</pubDate></item><item><title>Re: How to get Developers and Designers to go to your Hackathon</title><link>http://jonathanjulian.com/2012/12/how-to-get-developers-and-designers-to-go-to-your-hackathon/#comment-740841272</link><description>&lt;p&gt;Jonathan - The one piece that you missed and that I didn't think of until I saw Adam's name at the bottom is that events should make an effort to get youth involved. I'm pretty certain that he's more likely to come to an event where his children are welcomed and entertained than one were he feels like they'll clash with the environment or structure. - K&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Kate Bladow</dc:creator><pubDate>Mon, 17 Dec 2012 10:49:50 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-734187401</link><description>&lt;p&gt;#as_json generates a hash. Excellent.&lt;br&gt;There is no equivalent #as_xml to generate an xml-intended hash, so presumably you use #as_json chained with #to_xml.  Why isn't #as_json called #as_hash instead?&lt;br&gt;Coupling the default intended rails behavior with the actual behavior of the method itself in the name of the method is not a good idea, and it confuses me why Rails did this.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Aaron Oman</dc:creator><pubDate>Wed, 12 Dec 2012 14:37:03 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-519262570</link><description>&lt;p&gt;Great post jjulian!&lt;/p&gt;&lt;p&gt;any chance you can help with &lt;a href="http://stackoverflow.com/questions/10433194/rails-format-json" rel="nofollow noopener" target="_blank" title="http://stackoverflow.com/questions/10433194/rails-format-json"&gt;http://stackoverflow.com/qu...&lt;/a&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Rafael Revi</dc:creator><pubDate>Fri, 04 May 2012 13:52:36 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-458669385</link><description>&lt;p&gt;So helpful! thanks. Didn't know about as_json before.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Magnemg</dc:creator><pubDate>Wed, 07 Mar 2012 07:58:47 -0000</pubDate></item><item><title>Re: Rails to_json or as_json?</title><link>http://jonathanjulian.com/2010/04/rails-to_json-or-as_json/#comment-386307685</link><description>&lt;p&gt;Oops, I had a typo in my MyController pseudo code.  &lt;/p&gt;&lt;p&gt;It should be this:&lt;/p&gt;&lt;p&gt;class MyController &amp;lt; ApplicationControllerrespond_to :jsondef show@user = User.find(params[:id])&lt;br&gt; respond_with(@user , :include =&amp;gt; {:addresses =&amp;gt; {:include =&amp;gt; :email}})&lt;br&gt;end&lt;/p&gt;&lt;p&gt;Which I want to refactor with something like this in the model:&lt;br&gt;def as_json(options={})super(:only =&amp;gt; [:email, :avatar], :include =&amp;gt;[:addresses =&amp;gt; {:include =&amp;gt; :email}])end&lt;/p&gt;&lt;p&gt;But I get an &lt;br&gt;undefined method `macro' for nil:NilClass&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">pseudo_rails</dc:creator><pubDate>Wed, 14 Dec 2011 05:36:51 -0000</pubDate></item></channel></rss>