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

RFC - Implemenatation ideas #16

Closed
liuggio opened this issue Mar 11, 2013 · 7 comments
Closed

RFC - Implemenatation ideas #16

liuggio opened this issue Mar 11, 2013 · 7 comments

Comments

@liuggio
Copy link

liuggio commented Mar 11, 2013

Hi,
I like your project and we are using in production,
some ideas...

  • Writer(external) and reader(web) should not share the same config file, they are conceptually different.
  • The writer 'd have an interface (maybe doctrine common cache) so swapping with other mechanisms as APC/Redis/MYSQL 'll become easy related to Other DB #11
  • Composerize the project vendors
  • uses PSR*

what do you think?

@markstory
Copy link
Member

Abstracting different datastores is going to be a huge amount of work, and make the project more difficult to maintain. What's the upside?

What do you see being different in the configuration files?

I'm not sure there is much of a win to use composer with only one vendor. The only thing I see it doing right now is making the installation more complicated by adding another step. If we start using more vendor libraries it might start to make sense though.

I'm currently working on refactoring some of the global functions so that they are attached to classes, or properly prefixed, this fits into PSR scope as prefixed classnames are acceptable there. When @preinheimer and I originally discussed the project we didn't want to use namespaces as that prevents people still using 5.2 from using xhgui. Was there something else you had in mind?

@jaikdean
Copy link

jaikdean commented Apr 5, 2013

Support for other datastores would be useful for us. We have a few sites on scalable, load-balanced AWS setups. Having to set up, manage and maintain an EC2 instance just to run MongoDB for performance data collection isn't ideal. However, AWS provides a managed NoSQL called DynamoDB which is trivial to set up and maintenance-free.

@preinheimer
Copy link
Contributor

Interesting, supporting the basic feature set on there might not be too bad, the more advanced stuff (like custom searches and reporting) might be trickier.

@markstory
Copy link
Member

Complex queries and aggregation are always tricky in a multiple datastore solution. Building a good testsuite helps, but having multiple datastores always adds complexity.

@dennisdegreef
Copy link

I'm working on a library which has multiple datastores, but currently has not 'frontend'. I'm currently refactoring the internal data structure also keeping in mind that XHGui would work on top of the datastore adapter of Mongo. Is there any way we can work together to complete this common goal? A shared interface for datastructures inside of mongo and/or files would be awesome!

My library is link0/profiler and i'm currently working on link0/profiler#62

@markstory
Copy link
Member

@dennisdegreef I don't see why we couldn't try and share the same mongo data structures. We'll need to figure out a way to make changes in a backwards compatible way on our side though.

@Krinkle
Copy link
Contributor

Krinkle commented Jul 17, 2020

  1. The writer have an to swapping with other backends.

Done per #244. See also #11.

  1. Use compsoer for dependencies.

Done.

  1. Separate writer and reader config.

Done with https://github.com/perftools/php-profiler.

  1. Use PSR*.

There will always be another PSR. But overall I don't think this matters much for XHGui since it has almost no dependencies and the ones it does have, I think, don't benefit being able to swap out (they just work), also since it's not meant to be composed with other apps as library but is itself a finished application.

If this this about autoloading PSR, it uses that now (just PSR0 for now).

If this is about coding style consistency, that isn't done yet. Could set up PHPCS in a separate ticket. I filed #299 for that now.

This ticket can be closed I think?

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

7 participants