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
[backend-api] API Product export #1055
Conversation
simara-svatopluk
commented
May 21, 2019
•
edited
edited
Q | A |
---|---|
Description, reason for the PR | We add support for backend API and exporting products in the very moment |
New feature | Yes |
BC breaks | No |
Fixes issues | ... |
Have you read and signed our License Agreement for contributions? | Yes |
0ef9a06
to
a0794e0
Compare
ad8e69e
to
a27cddb
Compare
a27cddb
to
120a282
Compare
120a282
to
8242568
Compare
896bad9
to
0baf7b3
Compare
0740e3a
to
8fbc8b4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, Thanks for the PR. I like the idea 👍 and the separation is very nice.
f9171f8
to
7e1517d
Compare
Hello, I have some points.
|
@LukasHeinz @PetrHeinz Hi, #1055 (comment) suggest that API won't be a default part of project-base and implementator will have to always install it. It makes sense to me because the project-base will be more lightweight by default. On the other hand it would be a first package that is not part of the project-base so I expect unknown amount of troubles. Troubles that comes to my mind right now are complications during testing and continuous integration (we would maybe need a special job that installs the API and it and it would take time to maintain such job). We'll also have to provide special install instructions. It will complicate automatic testing other than unit testing (smoke, functional, performance, acceptance). So not having API in default project-base will add a lot of effort in my opinion. On the other hand it is a step in the right way in my opinion (lightweight SSFW). |
@simara-svatopluk I think not having the API registered by default is a step in right direction and I fully support it 👍 I think that being able to test the Shopsys Framework in different configurations will be essential in the near future. I don't see any benefit in postponing it. As a side note - maybe we'd want to remove product feeds from the default |
@simara-svatopluk From my point of view, I would not like to have different configurations of SSFW unless we have automatic tests for several configurations. I recommend to have it as dependency on project-base and when we improve our quality assurance process and add automatic tests for the installation of project-base in different setups. It is planned within the next few months. Do you see any disadvantage in postponing it until we have improved infrastructure? |
I'm sorry. I miss clicked that. |
@henzigo I disagree.... closing :-D Friday 🐼 |
@LukasHeinz - I would like to point out two disadvantages: confusing upgrade notes and the risk of postponing it for too long... |
And removing database fields which were migrated with API bundle is not that easy. |
I have been informed, that the automatic test of these two configs will be easy. So for me - if the test of the new configuration is part of this new feature (not necessary part of the same PR, but will be deployed at theč same time), I am okay with separation of PB and API. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this style of docs, good job @vitek-rostislav
@henzigo We've just decided that for now the API will be part of project-base and it will be merged to 8.0 master. The separation will be done before the 8.0 is released and @PetrHeinz commited to push this separation. We decided for this approach because this API PR have already taken a lots of effort (and also will take), and we believe that "have something done" is better than "have something in progress for a long time". |
c7f94df
to
76125df
Compare
Hello @grossmannmartin, thank you so much for testing this!
|
This is ehm... not so informative replay. How could Martin have any suggestion? It doesn't make any sense... |
At first it's strange it works with GET. HTTP GET should not contain the message body (well, it is not restricted, so it potentionally could), but what is more important server shouldn't process the GET message body. So in this case the server should reply with an error "no data". But to be honest, I personally don't consider to be a big problem... do you think this is a problem that has to be addressed? |
Thanks for the fixes :)
TLDR: |
@grossmannmartin I could spend time on this issue, but honestly I don't see big added value (as an implementator I would only check the response code) and it would also take time and this PR won't be done today. I know the second argument is forcing... but it's the current state. After this reply... what do you think? Do we have to fix it right now? |
@grossmannmartin, |
|
@simara-svatopluk: Okay, I understand and I'm ok with current state |
a0a0bcf
to
56a0da2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice job guys! Really. The docs are quite complete and easy to understand and read. Nevertheless, I just found something in docs, but only minor things.
9de4534
to
2d7b224
Compare
c1f0b2b
to
65015e7
Compare
- working endpoints - /api/v1/products (includes filter by uuids, pagination) - /api/v1/products/{uuid} - using FOSRestBundle - for finding products from facade is used query so the code is prepared for further extension by extending the ProductQuery and the query method ProductRepository::findByQuery() - routes in project-base must be added for each version - that is a compromise between "routes works automatically when I add the bundle" and "user have to add all routes manually" - api extension works form project-base in a way "what is extended is taken from project-base; what is not extended is taken from framework"
- added phing target "backend-api-oauth-keys-generate" for generating oauth keys and parameters
65015e7
to
b8c0f98
Compare