Jump to content

 

billr578

Member Since 05 Feb 2020
Offline Last Active Oct 14 2020 01:50 PM
*****

Topics I've Started

Varnish & Edge Side Includes

16 April 2020 - 09:45 PM

Hey Everyone -

 

Looking for some help with Varnish configs in front of a couple AWS ec2 instances that run our CS-Cart MV servers.

 

We're using Varnish in front of our CS Cart MV setup (NGINX terminated ssl proxy to Varnish then load balanced to 2 CS Cart servers running NGINX).  I've noticed if I leave this in my vcl_backend_response for Varnish that for any user signed in CS Cart MV gets REALLY slow:

 

if (beresp.http.X-Do-ESI) {
   set beresp.do_esi = true;
}
 
Basically if ESI is on, the backend gets super slow.  I see waterfall response times of 12s+ which is absolutely crazy.  If I comment the set beresp.do_esi = true; out, then I get something int he 3s - 4s range, which is still slow, but not 12s+ slow.
 
When properly cached, we'll get a page back in 30ms or so, which is what we're after in most cases.
 
Does anyone have any experience trouble shooting Varnish response times in Amazon EC2 environments?  I'm also seeing some really inconsistent hit rates on most pages (home page, category pages, etc.). I'm looking for some help with configs, etc. so I can learn and start managing this on my own.
 
Thanks in advance!
 
-Bill

Disabling Fields For Product Form

01 March 2020 - 09:04 PM

Hi -

 

I'm trying, based on some guidance from CS-Cart, to remove some of the fields in the Product form page.  The guidance said leverage the "my_changes" add-on (which is enabled) to disable the content based on the logged in user_type.  So, for example I've created this directory within our install:

/design/themes/thin_theme/templates/addons/my_changes/hooks/products

then to disable the "zero action" field I've created this template in that directory:

update_product_zero_price_action.override.tpl

and put this content inside:

{if $auth.user_type != 'V'}
<div class="control-group">
    <label class="control-label" for="elm_zero_price_action">{__("zero_price_action")}:</label>
    <div class="controls">
        <select class="span5" name="product_data[zero_price_action]" id="elm_zero_price_action">
            <option value="R" {if $product_data.zero_price_action == "R"}selected="selected"{/if}>{__("zpa_refuse")}</option>
            <option value="P" {if $product_data.zero_price_action == "P"}selected="selected"{/if}>{__("zpa_permit")}</option>
            <option value="A" {if $product_data.zero_price_action == "A"}selected="selected"{/if}>{__("zpa_ask_price")}</option>
        </select>
    </div>
</div>
{/if}

Again, the add-on "My changes" is enabled, but even with this setup the field still shows up.  Is there something I've missed here?  I've also thread through the help page on TPL Hooks and it looks like I'm doing it correctly.  Would love some help here as I could have sworn this would work, but its not.  Thanks!

 

-Bill

 


Field Character Count Limitations

01 March 2020 - 07:13 PM

Hi -

 

I'm curious if there's a way to limit the number of characters that a vendor can use when configuring their store.  For example, the description a vendor can set on their store, it appears the amount of content is limitless.  That can cause some layout issues if vendors abuse it, so I was looking for an easy way to set a limit.  Thanks!

 

-Bill


Hide A Category Page Based On Product Count

01 March 2020 - 07:05 PM

Hi -

 

Does anyone know if there's a way to hide a category from the menus on the site if the number of products doesn't meet a certain threshold?  At the minimum I'd like to be able to hide categories in our navigation that don't have at least 1 product.  Thanks!

 

-Bill


Vendor Admin Menus

09 February 2020 - 08:23 PM

Hi -

 

Is there a way to hide any of the menus found in Vendor admin?  We have a few that we think will be confusing/not needed to our vendors as we get started.  Thanks!

 

-Bill