Announcement

Collapse
No announcement yet.

Power Search ERROR: "504 Gateway Time-out nginx" after implementing.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Power Search ERROR: "504 Gateway Time-out nginx" after implementing.

    New to MM5/Mv9, installed latest version of "Power Search" module, and edited "SRCH Search" template accordingly (below), and Assigned "pwrsrch / Power Search" Item to Pages "SRCH Search" and "SFNT Storefront", and browser displayed an error message "504 Gateway Time-out nginx" upon attempting to perform a test search from Storefront Global Header.

    Code:
    <mvt:item name="html_profile" />
    <head>
    <title>&mvt:store:name;: &mvt:page:name;</title>
    <mvt:item name="head" param="head_tag" />
    </head>
    <mvt:item name="body">
        <mvt:item name="hdft" param="global_header" />    
        <div class="row hdft-header">
            <mvt:item name="hdft" param="header" />
        </div>
        <mvt:if expr="NOT ISNULL g.Search">
            <mvt:if expr="l.settings:search_product_count EQ 0">
                <div class="row">
                    <div class="column whole">
                        <p class="italic">No products matched your search criteria</p>
                        <form method="post" action="&mvt:global:sessionurl;Screen=SRCH" class="whole medium-one-third">    
                            <input type="hidden" name="Store_Code" value="&mvte:store:code;" />
                            <div class="form-row">
                                <label for="l-Search" class="bold">Search For:</label>
                                <input type="search" name="Search" value="&mvte:global:Search;" id="l-Search" />
                                <mvt:item name="powrsrch" param="fields" /> 
                            </div>
                            <div class="form-row align-right">
                                <mvt:item name="buttons" param="Search" />
                            </div>
                        </form>
                        <br class="clear" />
                    </div>
                </div>
            <mvt:else>
                <mvt:item name="search_results" />
            </mvt:if>
        <mvt:else>
            <div class="row">
                <form method="post" action="&mvt:global:sessionurl;Screen=SRCH" class="whole medium-one-third">    
                    <input type="hidden" name="Store_Code" value="&mvte:store:code;" />
                    <div class="form-row">
                        <label for="l-Search" class="bold">Search For:</label>
                        <input type="search" name="Search" value="&mvte:global:Search;" id="l-Search" />
                        <mvt:item name="powrsrch" param="fields" /> 
                    </div>
                    <div class="form-row align-right">
                        <mvt:item name="buttons" param="Search" />
                    </div>
                </form>
                <br class="clear" />
            </div>
        </mvt:if>
        <div class="row hdft-footer">
            <mvt:item name="hdft" param="footer" />
        </div>
        <mvt:item name="hdft" param="global_footer" />    
    </mvt:item>
    </html>
    Thank you, Bill Davis

    #2
    Re: Power Search ERROR: &quot;504 Gateway Time-out nginx&quot; after implementing.

    I don't know about the error but it looks like you missed steps. You will need to adjust the form in the header to match what you are trying to do as well but


    <mvt:item name="search_results" />
    gets replaced with
    <mvt:item name="powrsrch" param="prod" />

    Copy the code in the search product display just so you have it and can use it then
    search_results gets unassigned from the SRCH page
    Last edited by Mark Hood; 02-20-15, 06:30 PM.
    Mark Hood
    Vermont Gear

    Comment


      #3
      Re: Power Search ERROR: &quot;504 Gateway Time-out nginx&quot; after implementing.

      Code:
      6) Setting your product layout. It is probably the same as the product layout you have already in your srch page template. However, that layout cannot be used because it runs the search in the background before it displays the products. So there are three steps when you replace the original product layout with the Power Search product layout. 
      a) Put comment tags around the original <mvt:item name="product_list" /> item tag. (fig 8) If using CSSUI the item tag to comment out is <mvt:item name="search_results" /> 
      b) Insert this token just below (outside) those comment tags. (fig 8)
      <mvt:item name="powrsrch" param="prod" /> 
      c) Unassign the product_list (or search_results if using CSSUI) item from the srch page template's item list only. Do not remove it from the master list of items. Do not skip this step as it is critical for the proper function of power search. 
      Mark Hood
      Vermont Gear

      Comment


        #4
        Re: Power Search ERROR: &quot;504 Gateway Time-out nginx&quot; after implementing.

        That error will normally occur at 65 seconds on one of our servers configured with the default settings. We can increase that value, but if your search is taking 65 seconds, no normal customer is going to wait that long, so I wouldn't recommend having us just increase it until we find a value that allows it to complete. It sounds like something else is wrong, or it's searching too many fields in too much data and should be made more specific?
        David Hubbard
        CIO
        Miva
        [email protected]
        http://www.miva.com

        Comment


          #5
          Re: Power Search ERROR: &quot;504 Gateway Time-out nginx&quot; after implementing.

          Originally posted by Mark Hood View Post
          I don't know about the error but it looks like you missed steps. You will need to adjust the form in the header to match what you are trying to do as well but


          <mvt:item name="search_results" />
          gets replaced with
          <mvt:item name="powrsrch" param="prod" />

          Copy the code in the search product display just so you have it and can use it then
          search_results gets unassigned from the SRCH page
          Mark, even after this was corrected and the item unassigned it's still getting the 504 Gateway Time-out nginx error. Think looking at the search fields might be the next step.
          Leslie Kirk
          Miva Certified Developer
          Miva Merchant Specialist since 1997
          Previously of Webs Your Way
          (aka Leslie Nord leslienord)

          Email me: [email protected]
          www.lesliekirk.com

          Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr

          Comment


            #6
            Re: Power Search ERROR: &quot;504 Gateway Time-out nginx&quot; after implementing.

            sounds like strange trickery to me I've had my share this week!
            Mark Hood
            Vermont Gear

            Comment

            Working...
            X