Rails

Rails

Application and Data / Languages & Frameworks / Frameworks (Full Stack)
Avatar of Startouf
CTO at My Job Glasses·

After splitting our monolith into a Rails API + a React Redux.js frontend app, it became a necessity to monitor frontend errors. Our frontend application is not your typical website, and features a lot of interesting SPA mechanics that need to be followed closely (many async flows, redux-saga , etc.) in addition to regular browser incompatibility issues. Rollbar kicks in so that we can monitor every bug that happens on our frontend, and aggregate this with almost 0 work. The number of occurrences and affected browsers on each occurence helps us understand the priority and severity of bugs even when our users don't tell us about them, so we can decide whether we need to fix this bug that was encountered by 1k users in less than a few days days VERSUS telling this SINGLE user to switch browsers because he's using a very outdated version that no one else uses. Now we also use Rollbar with Rails, Sidekiq and even AWS Lambda errors since the interface is quite convenient.

READ MORE
5 upvotes·236.8K views
Avatar of yonasb
CEO at StackShare·
Shared a protip
on
StripeStripe
at

We've been using Stripe for a while to charge our customers (mostly for the ads you see on StackShare), but we only recently realized that you can actually invoice and charge customers all through Stripe's UI 😱

You just need a customer's email address, then you add them as a customer and create a new invoice and send it to the customer- all via the Stripe dashboard. The customer then gets an email with a link to the pay the invoice (via credit card, ACH, or wire transfer). Once the customer clicks the link in the email to pay they're taken to a page hosted at pay.stripe.com where they can download a PDF of the invoice and pay via credit card, or ACH/wire transfer.

Nevermind the fact that we built an entire Rails app to do all this 😒 We'll be sunsetting our payments app soon. I wish someone had told us about these features sooner! I doubt they had this when we first built the app but we could have stopped using/maintaining the app a while ago. Stripe is amazing. That is all.

#invoicing #payments

READ MORE
7 upvotes·5 comments·22.7K views
David Gorcey
David Gorcey
·
July 19th 2019 at 9:31PM

Yeah, even people with no accounts receivable/billing experience like me find it pretty easy. I'd recommend it if you're handling billing for whatever project you're working on as an easy way to make sure you get paid. 🤑

·
Reply
Christopher Wray
Christopher Wray
·
March 12th 2020 at 9:00PM

Wow. Where is the docs for this? Sounds great!!

·
Reply
Yonas Beshawred
Yonas Beshawred
·
March 12th 2020 at 9:56PM

It's amazing! Docs: https://stripe.com/docs/billing/invoices/hosted

·
Reply
Christopher Wray
Christopher Wray
·
March 12th 2020 at 11:02PM

Thank you! And feel honored you responded to my comment. Sweet app you have here.

·
Reply
Yonas Beshawred
Yonas Beshawred
·
March 13th 2020 at 4:20AM

My pleasure! Thanks a lot for being a part of the community :)

·
Reply
Shared insights
at

I'm working as one of the engineering leads in RunaHR. As our platform is a Saas, we thought It'd be good to have an API (We chose Ruby and Rails for this) and a SPA (built with React and Redux ) connected. We started the SPA with Create React App since It's pretty easy to start.

We use Jest as the testing framework and react-testing-library to test React components. In Rails we make tests using RSpec.

Our main database is PostgreSQL, but we also use MongoDB to store some type of data. We started to use Redis  for cache and other time sensitive operations.

We have a couple of extra projects: One is an Employee app built with React Native and the other is an internal back office dashboard built with Next.js for the client and Python in the backend side.

Since we have different frontend apps we have found useful to have Bit to document visual components and utils in JavaScript.

READ MORE
19 upvotes·893.7K views
Avatar of shivambhargava97
AVP - Business at VAYUZ Technologies Pvt. Ltd.·
Needs advice
on
Node.jsNode.jsPythonPython
and
RailsRails

Hi Community! Trust everyone is keeping safe. I am exploring the idea of building a #Neobank (App) with end-to-end banking capabilities. In the process of exploring this space, I have come across multiple Apps (N26, Revolut, Monese, etc) and explored their stacks in detail. The confusion remains to be the Backend Tech to be used?

What would you go with considering all of the languages such as Node.js Java Rails Python are suggested by some person or the other. As a general trend, I have noticed the usage of Node with React on the front or Node with a combination of Kotlin and Swift. Please suggest what would be the right approach!

READ MORE
Neobank - Wikipedia (en.wikipedia.org)
22 upvotes·164K views
Replies (9)
Recommends
ServerlessServerless

Use the language which works well for the developers you have or have available. If you're starting, building a first iteration is far more important than worrying about what language might be best to solve a problem you may never have.

When hiring, look for developers, not "node developers" or "java developers" having people who recognise and are willing to adapt means you can have the flexibility you will need to solve as-yet unforeseen issues. Hire people who are wed to a specific language and you will be bound to that language, regardless of whether it's most appropriate or not.

READ MORE
41 upvotes·1 comment·6.6K views
Shivam Bhargava
Shivam Bhargava
·
March 26th 2020 at 7:43AM

Hey! Thanks for the response. I do agree with this line of thought, currently I do have an established team of Folks who are pretty good at NodeJS and related stacks (MEAN, MERN, Meteor etc.) along with expertise in Flutter, Native Apps along with AWS as well. I think this would constitute the core App and then integrations all across can take place. Would you have any reading material on the Serverless front in relation to Neobanks / Digital Banking platforms? Thank you.

·
Reply
Recommends
RailsRails

For online banking, it'll be less computation intensive and more data intensive. So, Rails will be better than Python. I'll not recommend Node.js as it's not as scalable as those. If I had to choose indepently I would took Go.

READ MORE
19 upvotes·5 comments·6.6K views
Mikael Sand
Mikael Sand
·
March 27th 2020 at 9:48PM

What measurements do you base the scalability conclusion / comparison of python, ruby (rails), and nodejs on?

·
Reply
Shaswata Das
Shaswata Das
·
April 1st 2020 at 12:46PM

nodejs maintains concurrency by events, it's common sense that a single thread would never be able to equivalent of multi-thread.

Now, let's talk about Ruby vs Python.

Python requires the developer to be clean about side effects and isolation. With Ruby one can write concurrent programs that operate on multiple cores easily, similar to Python, a developer is responsible for side effects and isolation issues. Python’s concurrency process is more resource-demanding as compared to Ruby. But then again, it boils down to developer coding habits if one has to take the cake offered by both Python and Ruby Performance languages.

·
Reply
Mikael Sand
Mikael Sand
·
April 1st 2020 at 3:55PM

Seems like a banking system would have its scalability depend more on the transactional database in use, rather than the choice of language used for the api layer, which probably just translates from/to http+json or whatever transport and message standards used, to some atomic sql / db query in a transaction and serialising the response. Seem unlikely there would be any need for shared memory multi-threading in the api layer. Node.js could probably be used just fine, e.g. with PostGraphile on top of PostgreSQL. It seems very unlikely to be the bottleneck.

·
Reply
Shaswata Das
Shaswata Das
·
April 2nd 2020 at 8:59AM

In case of online banking, bottleneck may occur. I'd rather prefer isolated hybrid database API, that'll better than PostGraphile. For security issues, I'll not recommend any GraphQL API in online banking application, also it'll not be helpful in this scenario. It's true that "a banking system would have its scalability depend more on the transactional database in use", but when it's about online banking it's not only about transaction, I bet, they've more to offer to their clients. So, scalability on api layer is also important for this case.

·
Reply
Varun Sharma
Varun Sharma
·
April 22nd 2020 at 9:51AM

Brother I have been working in Ruby on rails and nodejs from last 3 years. From my experience it is easy to scale nodejs as compared to Ruby and it even requires less resources for deployment as well. This was one of the reason why linkedin shifted their stack from Ruby on Rails to Nodejs.

·
Reply
View all (9)
Avatar of heardofdezz
FullStack Dev at Nouvelles Donnes·
Needs advice
on
Rails APIRails APIRailsRails
and
Node.jsNode.js

Currently working on my company's new saas, the main goal is to manage content and user. I'm familiar with the rails framework and how it is easy to code and deploy. The thing is I'm the only dev on the project, and in terms of the tech stack, there is no preference. However, because Node.js is everywhere and there is enough dev on the market, I am stuck between choosing Rails or Node.js. I don't mind implementing Vue.js or React on the frontend, but I need a solid argument to explain to people that aren't necessarily tech-savvy as to why we should choose Rails over Nodejs.

READ MORE
3 upvotes·89K views
Replies (6)
Recommends
Node.jsNode.js

You are probably referring to ruby on rails for web development and nodejs for building the backend. Nodejs has frameworks such as express and next which not only provides a minimal code to build a backend but also gives the flexibility to try and experiment with the framework choices. For example you can have express framework + Passport for OAuth .... etc. The flexibility and the constant improvement of the language provides a good reason to opt for nodejs. Nodejs uses javascript which makes your code uniform when you are working full stack i.e react in front end and nodejs in backend.

READ MORE
7 upvotes·2 comments·76.1K views
Max Loua
Max Loua
·
June 17th 2020 at 2:08PM

I'm familiar with Nodejs, express and vue, i have worked on a coupled of project with those stacks. my question was mainly towards how can i explain to a group of people (my supervisors) that arent tech savvy why working on rails is good for such product which is small and im the only dev on it. the goal is to dev it using rails api for the backend with a vuejs frontend.

·
Reply
Niket Kulkarni
Niket Kulkarni
·
June 17th 2020 at 8:58PM

You can tell them by showing the google trends , the manner in which nodejs has taken over ruby on rails over the years. You can show the amount of support that has been gained in the community when nodejs is being used and lastly you can tell them that nodejs is blazing fast due to v8 engine on which it runs.

·
Reply
Recommends
Rails APIRails API

I'd use the following metaphor to non-technical people. Rails is like a prepackaged toolkit, which can get most of the common tasks done fairly with ease. Whereas, node.js with whatever backend framekwork of choice, is like a DIY toolkit assembled by mix-and-match different tools in a large tool shop. Of course, at times DIY toolkit can do better on specific tasks. Given that you are the only dev on the project, I'd assume that the resource is fairly limited. And looks like you are not building some next-gen super duper fast smart application. So Just go with the prepackaged toolkit then. Rails is a very opinionated framework, there're pros and cons to it. But thanks to that, many of the gems are coded with it in mind. For example, they are all designed with same naming convention. Many will work well together out-of-box, for example devise and cancancan. Besides, many stuff are built in the framework. For example, logging utility, csrf protection, session encryption, etc. Yes, many of those stuff may not be useful or necessary at the beginning of the project life-cycle. However, down the road, there is a good chance you will need some of those. And the moment you realize that you already have it, it's so delightful. In addition, it's usually easier to debug a rails app than a node app in my experience. Personally, the cases where I would pick node.js over rails would be projects either require a) high-performance, or b) certain core functionality that has been implemented by some node packages but not by any ruby gems. In term of performance, node has a clear advantage over any other major web frameworks, except the ones built with go. It's simply a language feature. Node allows developer to easily write code that runs db query, external api calls, or other stuff of that nature in parallel. And that is THE MOST COMMON performance bottleneck of web applications.

READ MORE
6 upvotes·76.1K views
View all (6)
Needs advice
on
RubyRuby
and
JavaScriptJavaScript

I'm new to development, and I've been studying JavaScript and Ruby concurrently, but I'm to a point now where I should really be focusing my effort into learning one language. I'd like a solid foundation and understanding, so that I can move forward with confidence. Everywhere I go, I keep hearing that RoR is a dying breed. However, I really have enjoyed Ruby and Rails...a LOT. Its approachable, fun, and readability is great. I just don't want to set myself up for failure by saddling myself in with a stack that will take me nowhere. What is your opinion on the future of RoR and would it be foolish for me to invest too much time in learning it over others?

READ MORE
7 upvotes·30.5K views
Replies (7)
Avatar of juliendefrance
Principal Software Engineer at Tophatter·
Recommends
RubyRuby

Ruby on Rails is far from being dead. In fact, this is a very popular choice in early-stage startups, given how fast and easily it allows them to launch their product and iterate on it.

Even at more mature companies, you'll still find a ton of opportunities. Not for internal tools or legacy codebases, but for actual production workloads: web apps, APIs, etc...

Some may tell you that Ruby doesn't scale, but is it really Ruby that doesn't scale, or the code they wrote?

Languages have trends. Sometimes, recruiters will try to take you one way or another to meet their own agenda. Don't always listen to what you hear. Long live Ruby! Long live Rails!

READ MORE
We Asked the Industry: "Is Ruby on Rails Dead?" | Netguru Blog on Ruby (netguru.com)
6 upvotes·1 comment·22K views
Matt Williams
Matt Williams
·
October 15th 2020 at 9:37PM

Thank you so much for the advice!

·
Reply
Recommends
RubyRuby

You can’t directly compare RnR and Javascript, since the first is a framework (Ruby would be the language), and Javascript is a language. RnR even uses quite an amount of Javascript. I think that Ruby, and Rails, are design by improving on previous languages, and shifting the perspective from speed to readability and general developer friendliness. Opposed to that, Javascript did not have any design goals at all, and seems to be repeating the errors of all language designs that existed before. “Knowing Javascript” would not be a selling point to me when hiring someone, there should be mentioned specific javascript frameworks. And I’d always try to find someone who has experience in multiple languages. So my advice is to to learn RnR first, you get a head start, Javascript will just come along with it. And you can distinct yourself from other people that claim web development knowledge because they have done one javascript tutorial :-)

READ MORE
5 upvotes·1 comment·21.9K views
Matt Williams
Matt Williams
·
October 15th 2020 at 9:37PM

Thank you so much for the advice!

·
Reply
View all (7)
Needs advice
on
ReactReactRailsRails
and
DigitalOceanDigitalOcean

Hi there,

I'm looking to build up my own Auto Deployment tool for internal purposes (example deployhq.com, deploybot.com). I'm confused as to what tech stack I should use for the entire platform. My primary concerns are running parallel and concurrent builds to different targets (servers).

I have been researching and thinking of using Rails as backend and React as front-end (both deployhq.com and deploybot.com are built on these stacks).

Please advise.

READ MORE
6 upvotes·11.1K views
Replies (3)
Recommends
ReactReactJenkinsJenkins

Hi Akshay,

If the goal is to have a system that is purely to be used within your company, then it would be a good idea to have something scrappy. However, lot more has to be considered if you are planning to offer it as a SaaS or PaaS.

In either situations, the first factor I would consider is Return of Investment. You can build a really fabulous system, but if it is only going to help you little bit in the overall scheme of things, it may not be worth the effort. In other words, you can build - job management, scheduling, progress tracking, auto recovery, maintaining container state etc all by yourselves, but it may be worthwhile not reinventing the wheel when these solutions are already available (Jenkins or Team City for example).

If I were you, I will offload majority of the features like triggering jobs (build jobs), monitoring progress, errors etc to Jenkins. Every deployable unit can be dockerized, so that you get an uniform interface to validate whether the service is up and running.

You can build a thin vanilla UI on top of Jenkins' apis using React, or simply jQuery or Svelte. My personal preference would be Svelte.

If Jenkins is not a viable option, Go is the perfect backend for anything related to devops. You can use any Golang frameworks (Gin or Beego for instance) and have a front end in React / jQuery / Svelte. Hope this helps.

READ MORE
4 upvotes·4.8K views
Recommends
RailsRails

I guess the bigger question is why are you building your own auto deployment tool for internal use? Assuming that is a good idea, I think this depends on how quickly you can develop what you need in a language and framework that you are comfortable with, choose that over everything at this stage. You could build what you need using rails easily and anything that needs to run as a backend process for builds etc can be farmed out as a job somewhere and can be as simple of complex as you like. You can even have those jobs spooling up docker tasks with an entire rails stack in to to do what you need. In summary, have your front end create jobs with enough data in to go build stuff, then queue up those builds with something job like. The jobs can be simple rake tasks or entire docker containers doing anything you like. Perhaps take a look at rails, shoryuken for queueing on AWS, AWS Elastic Container service for actually doing the jobs.

READ MORE
3 upvotes·4.8K views
View all (3)
Needs advice
on
RailsRailsPythonPython
and
DjangoDjango

Hi, I'm kinda confused here. Need to know which is better for a Secure Future. Django or Rails. Thank you!

READ MORE
2 upvotes·85 views