-
Notifications
You must be signed in to change notification settings - Fork 8k
Added MySQL support back to ratings microservice #811
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
Conversation
…oints to return JSON
Hi @ErikWittern. Thanks for your PR. I'm waiting for a istio member to verify that this patch is reasonable to test. If it is, they should reply with I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Assign the PR to them by writing The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these OWNERS Files:
You can indicate your approval by writing |
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.
Thanks!
don't merge yet |
/ok-to-test |
@@ -1,2 +1,2 @@ | |||
{rating: 5} | |||
{rating: 6} |
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.
it's fine to have something different so you can visually tell which one you get
@@ -10,4 +10,4 @@ CREATE TABLE `ratings` ( | |||
PRIMARY KEY (`ReviewID`) | |||
); | |||
INSERT INTO ratings (ReviewID, Rating) VALUES (1, 5); | |||
INSERT INTO ratings (ReviewID, Rating) VALUES (2, 6); | |||
INSERT INTO ratings (ReviewID, Rating) VALUES (2, 4); |
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.
is 6 breaking the UI in some way ?
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.
@ldemailly Yes, the UI only shows up to 5 "empty" stars. So, while the UI can display more than five "filled" stars, it would exceed the maximum a user would expect.
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.
Yes, it looks pretty bad. May be use blue stars as next iteration?
if (process.env.SERVICE_VERSION === 'v2') { | ||
var MongoClient = require('mongodb').MongoClient | ||
var url = process.env.MONGO_DB_URL | ||
if (process.env.DB_TYPE === 'mysql') { |
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.
thanks!
is this mostly reverting to what it was before ?
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.
yes. Reverting and cleaning up. We can now use API driven tests and no longer need html comparators
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.
@ldemailly In this implementation, the DB_TYPE
variable needs to be set to mysql
for MySQL to be used. This is in line with changes @rshriram did here: 22014c8#diff-6a25b9bedba073dde47bfc3559d560a1
* revised source code of microservices so they communicate in JSON and expose an API * make API accessible via ingress controller * added swagger definition of new API * removed HTML status pages of microservices; aligned their health endpoints to return JSON * do not display anything when ratings data is not present to address comment by @frankbu on pull request #693 * added back support for MySQL into ratings microservice * fixed trailing line * fixed space * fixed ratings data in mongo db * fixed ratings data in mysql db Former-commit-id: 584ab1b
* revised source code of microservices so they communicate in JSON and expose an API * make API accessible via ingress controller * added swagger definition of new API * removed HTML status pages of microservices; aligned their health endpoints to return JSON * do not display anything when ratings data is not present to address comment by @frankbu on pull request istio#693 * added back support for MySQL into ratings microservice * fixed trailing line * fixed space * fixed ratings data in mongo db * fixed ratings data in mysql db Former-commit-id: 584ab1b
* revised source code of microservices so they communicate in JSON and expose an API * make API accessible via ingress controller * added swagger definition of new API * removed HTML status pages of microservices; aligned their health endpoints to return JSON * do not display anything when ratings data is not present to address comment by @frankbu on pull request #693 * added back support for MySQL into ratings microservice * fixed trailing line * fixed space * fixed ratings data in mongo db * fixed ratings data in mysql db Former-commit-id: 584ab1b
* Doc fixes. * Add high-level overview and diagrams for MCP (istio#805) * document MCP * add additional note on NACK behavior * add a note about ignoring stale nonces * Add envoy metrics service configuration to ProxyConfig (istio#803) * Add envoy metrics service configuration to ProxyConfig Similar to the statsd sink config, this change is in preparation for adding support for the envoy metrics service API. * Update proto.lock * Reorder metrics_service_address just after statsd_udp_address * Update comment in the authN API to match with 1.1 behavior (istio#808) * Rename metrics_service_address to clarify that it is for Envoy's API (istio#809) Since "metrics service" is so ambiguous, this change specifically denotes that the config is for Envoy's metrics service API. The comments also now link to detailed info about the metrics service API. * Generate separate HTML page per proto under networking (istio#811) * Generate separate pages for each networking proto Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * update Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * tweaks Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * Fix interdoc references * separate doc and go gen * change dash to underscore * fix * more fixes * makefile fix Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * remove bad target * Revert "change dash to underscore" This reverts commit 7fbced66f620fb60b0d5e18af916567e313a0109. * final update Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * Revert "Generate separate HTML page per proto under networking (istio#811)" This reverts commit 5f14eadd since it breaks the ability to generate reference docs in istio.io * Update to latest tools. * Revert "Update to latest tools." This reverts commit 231fadc5 which I accidentally pushed to the wrong place. * fix mcp update error diagram (istio#810) * update istio/tools (istio#815) * Revert "Revert "Generate separate HTML page per proto under networking (istio#811)"" (istio#818) * Minor updates for building docker images. (istio#817) * Add spell checking for docs. (istio#819) * Add a bunch of words to the custom dictionary. * Document exportTo restrictions (istio#820) * Doc fixes. (istio#821) * Proxy config: Add tls_certs_to_watch field (istio#824) * Proxy config: Add tls_certs_to_watch field * Address PR comment * Revert "Proxy config: Add tls_certs_to_watch field (istio#824)" (istio#825) This reverts commit e613e358ae8d4f331dd48904b0a2b176e11bf7f5. * Update gateway and sidecar hosts doc (istio#826) * Update gateway and sidecar hosts doc * regen * review comments * Update API docs (service entry, gateway, sidecar) (istio#831) * Update sidecar and gateway docs Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * gen docs Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * update service entry Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * updates Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * add configurable dns refresh rate to mesh for strict dns cluster, (istio#832) * add configurable dns refresh rate to mesh for strict dns cluster, issue istio#12181 * add lock file * Post-merge generation
* Doc fixes. * Add high-level overview and diagrams for MCP (istio#805) * document MCP * add additional note on NACK behavior * add a note about ignoring stale nonces * Add envoy metrics service configuration to ProxyConfig (istio#803) * Add envoy metrics service configuration to ProxyConfig Similar to the statsd sink config, this change is in preparation for adding support for the envoy metrics service API. * Update proto.lock * Reorder metrics_service_address just after statsd_udp_address * Update comment in the authN API to match with 1.1 behavior (istio#808) * Rename metrics_service_address to clarify that it is for Envoy's API (istio#809) Since "metrics service" is so ambiguous, this change specifically denotes that the config is for Envoy's metrics service API. The comments also now link to detailed info about the metrics service API. * Generate separate HTML page per proto under networking (istio#811) * Generate separate pages for each networking proto Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * update Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * tweaks Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * Fix interdoc references * separate doc and go gen * change dash to underscore * fix * more fixes * makefile fix Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * remove bad target * Revert "change dash to underscore" This reverts commit 7fbced66f620fb60b0d5e18af916567e313a0109. * final update Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * Revert "Generate separate HTML page per proto under networking (istio#811)" This reverts commit 5f14eadd since it breaks the ability to generate reference docs in istio.io * Update to latest tools. * Revert "Update to latest tools." This reverts commit 231fadc5 which I accidentally pushed to the wrong place. * fix mcp update error diagram (istio#810) * update istio/tools (istio#815) * Revert "Revert "Generate separate HTML page per proto under networking (istio#811)"" (istio#818) * Minor updates for building docker images. (istio#817) * Add spell checking for docs. (istio#819) * Add a bunch of words to the custom dictionary. * Document exportTo restrictions (istio#820) * Doc fixes. (istio#821) * Proxy config: Add tls_certs_to_watch field (istio#824) * Proxy config: Add tls_certs_to_watch field * Address PR comment * Revert "Proxy config: Add tls_certs_to_watch field (istio#824)" (istio#825) This reverts commit e613e358ae8d4f331dd48904b0a2b176e11bf7f5. * Update gateway and sidecar hosts doc (istio#826) * Update gateway and sidecar hosts doc * regen * review comments * Update API docs (service entry, gateway, sidecar) (istio#831) * Update sidecar and gateway docs Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * gen docs Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * update service entry Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * updates Signed-off-by: Shriram Rajagopalan <shriramr@vmware.com> * add configurable dns refresh rate to mesh for strict dns cluster, (istio#832) * add configurable dns refresh rate to mesh for strict dns cluster, issue istio#12181 * add lock file * Hosts are not ignored in ServiceEntry for HTTPs (istio#833) * Hosts are not ignored in ServiceEntry for HTTPs * Clarify * Reword * Generate protos * Address code review comments * Fix typo * generate * make mixer config marshal deterministic (istio#846) Signed-off-by: Kuat Yessenov <kuat@google.com> * Fix some doc errors. (istio#854) This started out to just fix a bad link to unblock work on istio.io, but I ended up fixing a bunch of typos/incorrect format throughout. * Fix two more broken links. (istio#856) * Fix CRD examples for release-1.1 (istio#859) * fix MeshNetworks demo (istio#841) * fix MeshNetworks demo * generate * update * last minute doc fixes (istio#865) Signed-off-by: Shriram Rajagopalan <rshriram@gmail.com> * Clarify comment for server_name field in Mixer oop auth config (istio#800) * add mixerclient config to istio.io reference docs (istio#827) * Envoyfilter docs fix (istio#867) * Tweaks to get the mixer client config docs to be published. (istio#868) * Change where the Mixer client docs are published.
Release note: