Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split into submodules #16

Open
jamescarr opened this issue Jan 25, 2012 · 2 comments
Open

Split into submodules #16

jamescarr opened this issue Jan 25, 2012 · 2 comments

Comments

@jamescarr
Copy link
Owner

Currently the module is a little bit of a mess... users get braintree whether they want to use it or not. Plus there is no abstraction on top of the original payment modules as planned. I think the general direction we should take is build submodules with a coherent coding style and then build abstractions on top of those.

So instead of just paynode, we'd wind up with

  • paynode-paypal
  • paynode-chargify
  • paynode-authorizenet

And turn paynode itself into an abstraction layer on top of these different modules. Thoughts?

@andyburke
Copy link

As someone looking around at solutions to this problem, I am fine with an all-in-one as long as I don't need to configure every one of them to get it to work. That is, I don't care if the npm module includes code for a service I don't use, as long as that code is safe for me to ignore in preference to the code I do need. I don't know that it's worth the time and effort of breaking things up into those specific modules.

@PawanWagh
Copy link

@jamescarr : I agree with you. We're also building a similar kind gateway service where you can opt for required payment provider, install corresponding adapter (to enforce a common interface for all providers) of that provider service and start using it.
So even if in future we decide to switch from paypal to braintree or from paypal to chargify, it makes our life easier for such migration.

Same architecture has been adopted by loopback where you can access data from Oracle, MySQL, PostgreSQL, MS SQL Server, MongoDB, SOAP and other with same REST APIs. It provides wrapper for mongodb, mysql, and other as separate packages & uses a datasource config to define which connector to use for current transaction.

I am forking your repo. Lets build it together.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants