Commit graph

34 commits

Author SHA1 Message Date
Ahmet Alp Balkan
61cf05844d fix go builds after deleting pkg internal
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-07-10 20:11:30 -07:00
JBD
4a82b21b5e add OpenCensus Go support for HTTP and gRPC 2018-07-10 17:36:55 -07:00
Simon Zeltser
7101b6b4fe Changing the order of redis and cart service starting
This should help monitoring probe for cart service to succeed at first run
2018-07-09 21:02:27 -07:00
Ahmet Alp Balkan
0be5e7b1e2 cartservice: rm initContainer, fix probe query ip
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-07-09 12:56:54 -07:00
Ahmet Alp Balkan
0c1068aec6 cartservice: add an exec probe written in Go
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-07-07 16:56:52 -07:00
Simon Zeltser
d457f7ec28 Making cartservice more reliable
1. Making sure we re-create redis connection upon disconnect
2. Fixed local cart store implementation to handle updates (useful for testing w/o redis)
3. Fixed windows scripts to work against redis correctly
2018-07-02 13:26:37 -07:00
Simon Zeltser
989fad7f76 Merge remote-tracking branch 'origin' into createCartService 2018-06-29 11:41:08 -07:00
Simon Zeltser
17ffcb9a6e Merge conflict fix for redis cache exception handling 2018-06-29 11:16:10 -07:00
Ahmet Alp Balkan
84ff69147e frontend: use pkg/errors, show full stacktrace
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-29 11:08:11 -07:00
Ahmet Alp Balkan
307404714b cartservice: add try catch to GetCartAsync
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-29 11:08:10 -07:00
Ahmet Alp Balkan
977c2e5ffd cartservice: dockerfile optimizations
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-29 11:08:10 -07:00
Simon Zeltser
f2ee88a9a2 Changed redis connection opening to be synchronous call
Also added exception handling for GetCartAsync
2018-06-29 11:08:10 -07:00
Simon Zeltser
4ac66b072a Refactored the cart service to add more telemetry
1. Added more telemetry around starting redis cache
2. Now if you don't specify redis cache address via command line
or environment variable, it will run with local cart (no redis).
This is useful for debugging purposes
2018-06-29 11:08:10 -07:00
Ahmet Alp Balkan
878be040e4 cartservice: add net-tools to build
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-29 11:08:09 -07:00
Ahmet Alp Balkan
6c8162eb3d k8s: fix emailservice port mapping
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-29 11:08:09 -07:00
Simon Zeltser
edf1553be9 Renaming cart service env vars
Renaming Cart service environment variables:
CART_SERVICE_ADDR => LISTEN_ADDR
CART_SERVICE_PORT => PORT
2018-06-29 11:08:08 -07:00
Simon Zeltser
546562fe53 Fixing AddItem and adding more tests/cartservice/CartServiceTests
Updated AddItem functionality so it handles update quantities scenario.
Added tests
2018-06-29 11:08:06 -07:00
Ahmet Alp Balkan
ca3ace3f65 frontend: use pkg/errors, show full stacktrace
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-28 22:03:39 -07:00
Ahmet Alp Balkan
f8ddac9c52 cartservice: add try catch to GetCartAsync
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-28 21:46:48 -07:00
Ahmet Alp Balkan
386f497553 cartservice: dockerfile optimizations
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-28 21:45:57 -07:00
Simon Zeltser
c84c5b028b Changed redis connection opening to be synchronous call
Also added exception handling for GetCartAsync
2018-06-28 18:40:22 -07:00
Simon Zeltser
ca6e6647ef Refactored the cart service to add more telemetry
1. Added more telemetry around starting redis cache
2. Now if you don't specify redis cache address via command line
or environment variable, it will run with local cart (no redis).
This is useful for debugging purposes
2018-06-28 17:12:33 -07:00
Ahmet Alp Balkan
c9f2c89b9c cartservice: add net-tools to build
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-28 11:42:12 -07:00
Ahmet Alp Balkan
39fd019343 k8s: fix emailservice port mapping
Signed-off-by: Ahmet Alp Balkan <ahmetb@google.com>
2018-06-28 01:05:12 -07:00
Simon Zeltser
f06bc11dd4 Renaming cart service env vars
Renaming Cart service environment variables:
CART_SERVICE_ADDR => LISTEN_ADDR
CART_SERVICE_PORT => PORT
2018-06-27 22:28:04 -07:00
Simon Zeltser
22762b28bd Fixing AddItem and adding more tests/cartservice/CartServiceTests
Updated AddItem functionality so it handles update quantities scenario.
Added tests
2018-06-27 10:33:18 -07:00
Simon Zeltser
2041bdcb48 Fixing GetCart for non-existing user
Now GetCart returns an empty cart for non-existing user
(user that haven't added anything to the cart before)
Added test to cover that

Also enhanced windows script for running cart service locally.
Now we have two options:
 - Running the service and redis locally (assuming redis emulator is installed)
   This is good for easier local debugging and troubleshooting

   docker_setup local

 - Running the service and redis in two separate docker containers
   This is good for better simulation of what will happen in the cloud
2018-06-26 14:41:00 -07:00
Simon Zeltser
c3c76effea Fixing cache implementation 2018-06-25 09:44:56 -07:00
Simon Zeltser
3262ff82b0 Updating docker file to not include ports. Added scripts folder and script to run docker with env vars passed via command line. Also now the build and packaging is happening in container 2018-06-22 17:17:34 -07:00
Simon Zeltser
5d44d019b3 Fixing docker issues. Now the server can run in linux docker container but doesn't work with real redis yet 2018-06-21 14:53:07 -07:00
Simon Zeltser
d7d9165da6 added gitignore file for .net proj 2018-06-21 11:19:48 -07:00
Simon Zeltser
0ce195bb80 command line arguments handling 2018-06-21 11:10:13 -07:00
Simon Zeltser
8860d8bfdd added redis integration and command line arguments handling to cart service. Didn't test in the cloud yet 2018-06-21 11:09:12 -07:00
Simon Zeltser
2df80b14c9 Initial commit of cart service using .net core 2.0. Working prototype without cache implementation (yet) 2018-06-20 15:40:07 -07:00