Ok.  It works now.  Thanks

On Mon, Mar 14, 2022 at 9:35 PM 'Jofre Riba Sánchez' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Your app.js in the prolisting folder of the example repo does not have a
> handler for the /prolisting path. This is why express can't get the
> /prolisting [1].
>
> Fix this by adding an additional handler for the path in app.js:
>
> app.get('/prolisting', (req, res) => {
> res.status(200).send('Hello, world prolisting!').end();
> });
>
> Note that when you dispatch with a path (i.e. /prolisting), the path is
> kept when calling the dispatched service. The dispatch rules do not remove
> the path.
>
> [1] https://expressjs.com/en/guide/routing.html
> On Saturday, March 12, 2022 at 7:43:46 AM UTC+1
> rajesh...@veersoftsolutions.com wrote:
>
>> Hi,
>> I created two simple services based on nodejs and hello-world sample.
>>
>> I am trying to explore dispatch.yaml
>> My dispatch.yaml.
>> dispatch:
>>   # Send all listing traffic to the listing frontend.
>> - url: "*/prolisting/*"
>>   service: prolisting
>> - url: "*/prolisting"
>>   service: prolisting
>> - url: "*/*"
>>   service: default
>>
>>
>> 'prolisting' service app.yaml
>> runtime: nodejs14
>> service: prolisting
>>
>> default service app.yaml
>> runtime: nodejs14
>>
>> I have uploaded to bgsample.appspot.com.
>> The default works: bgsample.appspot.com
>> The prolisting also works:
>> https://prolisting-dot-bgsample.uc.r.appspot.com
>>
>> However, the following URL does not work
>> https://bgsample.appspot.com/prolisting
>>
>> As per the dispatch.yaml, it should route to prolisting service, but
>> gives the following error
>> Cannot GET /prolisting
>>
>> my repo:
>> https://github.com/rajesh99/bgsample
>>
>> Cheers,
>>
>> --
>> Support Team
>> www.servicefolder.com
>> *Field Service Software on Google Cloud Platform and Mobile*
>>
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Google App Engine" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-appengine+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/d77d5b82-4bcb-43ac-821f-91454007a310n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/d77d5b82-4bcb-43ac-821f-91454007a310n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
Support Team
www.servicefolder.com
*Field Service Software on Google Cloud Platform and Mobile*

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CA%2BS7ijZ-8UA%3DuD%3DkyCtfzJRN7YiuhUyLLe8uK0gScMufcO%3D52A%40mail.gmail.com.

Reply via email to