From pablofernandezmoniz at gmail.com Tue Oct 27 14:30:59 2015 From: pablofernandezmoniz at gmail.com (=?UTF-8?Q?Pablo_Fern=C3=A1ndez_Moniz?=) Date: Tue, 27 Oct 2015 13:30:59 +0000 Subject: [Fiware-developer-experience] Doubts with authorization management Message-ID: Hi, We have been playing around with the app log in and user authorization. Right now we confirm that the log in seems to works as it was described in previous mails but we are stuck in how to further deal with the authorization from the front end side. Currently, the entry point to authorize users is via http://compose_devguide_1/auth URL. As it can be seen in the site.js file, the result of the backend processing is an HTML page which does not allow for interaction from the front end side. As the current site.js code was made to test the log in process, our questions is: How should we proceed now from the front end side to retrieve the authorization token and the logged user? Kind regards, ULPGC team -------------- next part -------------- An HTML attachment was scrubbed... URL: From alberto.martin at bitergia.com Tue Oct 27 16:20:17 2015 From: alberto.martin at bitergia.com (=?UTF-8?Q?Alberto_Mart=C3=ADn_Casado?=) Date: Tue, 27 Oct 2015 16:20:17 +0100 Subject: [Fiware-developer-experience] Doubts with authorization management In-Reply-To: References: Message-ID: Hi Pablo, You are right. The app.js now redirects to site.js, and that change was made for testing purposes as you said. I've made the main route point to /client (as it was before), so you can continue the front-end development there, as we did in the beggining. Then, to retrieve the access token, as you said is via http://compose_devguide_1/auth and when logged, the token will be accessible in the session. You will not need the actual view to enter any user or password in the application, it should be just a button showing something like "Log in with FIWARE account" and it will redirects to the idm, where the user should write the credentials. After that, the user will be redirected to the app again and the information of that user will be provided as a JSON un a route, /client/user (if you want to change it just let me know). I've just commited the changes. Let me know if you need anything else. Best, Alberto Mart?n On Tue, Oct 27, 2015 at 2:30 PM, Pablo Fern?ndez Moniz < pablofernandezmoniz at gmail.com> wrote: > Hi, > > We have been playing around with the app log in and user authorization. > Right now we confirm that the log in seems to works as it was described in > previous mails but we are stuck in how to further deal with the > authorization from the front end side. > > Currently, the entry point to authorize users is via > http://compose_devguide_1/auth URL. As it can be seen in the site.js > file, the result of the backend processing is an HTML page which does not > allow for interaction from the front end side. > > As the current site.js code was made to test the log in process, our > questions is: > How should we proceed now from the front end side to retrieve the > authorization token and the logged user? > > Kind regards, > > > ULPGC team > > _______________________________________________ > Fiware-developer-experience mailing list > Fiware-developer-experience at lists.fiware.org > https://lists.fiware.org/listinfo/fiware-developer-experience > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From alberto.martin at bitergia.com Tue Oct 27 16:29:33 2015 From: alberto.martin at bitergia.com (=?UTF-8?Q?Alberto_Mart=C3=ADn_Casado?=) Date: Tue, 27 Oct 2015 16:29:33 +0100 Subject: [Fiware-developer-experience] Doubts with authorization management In-Reply-To: References: Message-ID: Hi again, I've forgot to mention also that, we've changed the way to return the data. We've adapted all to schema.org as agreed, so the views you've made for geo-location restaurants probably won't work with the new format. We've detailed in Apiary how to consume the RESTful API and examples of the new schemas: http://docs.devguide.apiary.io/ Hope it helps! Best, Alberto Mart?n On Tue, Oct 27, 2015 at 4:20 PM, Alberto Mart?n Casado < alberto.martin at bitergia.com> wrote: > Hi Pablo, > > You are right. The app.js now redirects to site.js, and that change was > made for testing purposes as you said. > > I've made the main route point to /client (as it was before), so you can > continue the front-end development there, as we did in the beggining. > > Then, to retrieve the access token, as you said is via > http://compose_devguide_1/auth and when logged, the token will be > accessible in the session. You will not need the actual view to enter any > user or password in the application, it should be just a button showing > something like "Log in with FIWARE account" and it will redirects to the > idm, where the user should write the credentials. > > After that, the user will be redirected to the app again and the > information of that user will be provided as a JSON un a route, > /client/user (if you want to change it just let me know). > > I've just commited the changes. Let me know if you need anything else. > > Best, > > > Alberto Mart?n > > On Tue, Oct 27, 2015 at 2:30 PM, Pablo Fern?ndez Moniz < > pablofernandezmoniz at gmail.com> wrote: > >> Hi, >> >> We have been playing around with the app log in and user authorization. >> Right now we confirm that the log in seems to works as it was described in >> previous mails but we are stuck in how to further deal with the >> authorization from the front end side. >> >> Currently, the entry point to authorize users is via >> http://compose_devguide_1/auth URL. As it can be seen in the site.js >> file, the result of the backend processing is an HTML page which does not >> allow for interaction from the front end side. >> >> As the current site.js code was made to test the log in process, our >> questions is: >> How should we proceed now from the front end side to retrieve the >> authorization token and the logged user? >> >> Kind regards, >> >> >> ULPGC team >> >> _______________________________________________ >> Fiware-developer-experience mailing list >> Fiware-developer-experience at lists.fiware.org >> https://lists.fiware.org/listinfo/fiware-developer-experience >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From pablofernandezmoniz at gmail.com Wed Oct 28 11:17:13 2015 From: pablofernandezmoniz at gmail.com (=?UTF-8?Q?Pablo_Fern=C3=A1ndez_Moniz?=) Date: Wed, 28 Oct 2015 10:17:13 +0000 Subject: [Fiware-developer-experience] Issues with images and datasets Message-ID: Hello, We have being detected some problems with the images and the datasets provided and wanted to ask in we are doing something wrong or just notify about them: *Issue with "bitergia/ul20-client" image* We have been experiencing a weird issue with the "bitergia/ul20-client" image: Whenever we stop the fiware-devguide-app stack and start it again we receive an "ERROR: No thermal sensors found using acpi" message. To replicate the poblem, you can follow the next steps: 1. Start the devguide stack with docker-compose up 2. Stop the containers with Ctrl+C 3. Start the devguide again once all the containers are closed (docker-compose up) We also provide you with a screenshot of the error message in the attached image named thermal-error-message.png. So far, the workaround we have been doing is simply docker* rm *and docker *rmi* both the container and the ul20-client image. After the deletion, *docker-compose* up leaves the stack workable again. *Issue about restaurants without coordinates* We have detected some errors related the failure at retrieving the coordinate of some restaurants (approximately 165). We have analyzed some of them and they miss the ?geo? attribute. An example of one of this entities is the restaurant "Otatza Bekoa": {"@context":"http://schema.org","@type":"Restaurant","address":{"streetAddress":"Otatza etxea, 5","addressRegion":"GIPUZKOA","addressLocality":"ZERAIN","postalCode":"200026","@type":"postalAddress"},"aggregateRating":{"ratingValue":5,"reviewCount":86},"department":"Franchise1","description":"La sidrer?a Otatza Bekoa est? rodeada de manzanos, y cuenta con maquinaria moderna para hacer su propia sidra. Dispone de dos comedores, y en ellos, podremos disfrutar del t?pico men? de sidrer?a y degustar la sidra al txotx.","priceRange":"24.0","telephone":"943 801 757","name":"Otatza Bekoa"}, *Issue with incorrect geographical references* Some restaurants have been located outside Pa?s Vasco (even outside Europe). We suspect that it occurs due to a geocoding problem.We have attached an screenshot of the clusters to show this discrepancy in the misplaced-geographical-reference.png file. Kind regards, ULPGC Team -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: thermal-error-message.png Type: image/png Size: 289481 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: misplaced-geographical-references.png Type: image/png Size: 311519 bytes Desc: not available URL: From dmuriel at bitergia.com Wed Oct 28 12:08:41 2015 From: dmuriel at bitergia.com (David Muriel) Date: Wed, 28 Oct 2015 12:08:41 +0100 Subject: [Fiware-developer-experience] Issues with images and datasets In-Reply-To: References: Message-ID: On Wed, Oct 28, 2015 at 11:17 AM, Pablo Fern?ndez Moniz wrote: > Hello, > > We have being detected some problems with the images and the datasets > provided and wanted to ask in we are doing something wrong or just notify > about them: > > Issue with "bitergia/ul20-client" image > > We have been experiencing a weird issue with the "bitergia/ul20-client" > image: > > Whenever we stop the fiware-devguide-app stack and start it again we > receive an "ERROR: No thermal sensors found using acpi" message. That image is a simple Ultralight 2.0 client to generate some testing sensors and readings for IDAS. By default, it uses acpi to get some readings from the host, but you can change that option (--acpi) in docker-compose.yml to any of the other two available, --sys to use the /sys interface or --fake (along with --min and --max) to generate a fake sensor with random readings. Also, you can disable this container altogether by commenting out its section on docker-compose.yml, as no other container depends on this one right now. > To replicate the poblem, you can follow the next steps: > > Start the devguide stack with docker-compose up > Stop the containers with Ctrl+C > Start the devguide again once all the containers are closed (docker-compose > up) > > We also provide you with a screenshot of the error message in the attached > image named thermal-error-message.png. I'll try to replicate the problem. > So far, the workaround we have been doing is simply docker rm and docker > rmi both the container and the ul20-client image. After the deletion, > docker-compose up leaves the stack workable again. Just removing the container should be enough, there's no need to remove the image. We usually do a docker-compose rm to remove the containers after stopping. That way we always start with a clean set of containers. Regards, -- David Muriel. From alberto.martin at bitergia.com Wed Oct 28 12:19:32 2015 From: alberto.martin at bitergia.com (=?UTF-8?Q?Alberto_Mart=C3=ADn_Casado?=) Date: Wed, 28 Oct 2015 12:19:32 +0100 Subject: [Fiware-developer-experience] Issues with images and datasets In-Reply-To: References: Message-ID: Hi! On Wed, Oct 28, 2015 at 11:17 AM, Pablo Fern?ndez Moniz < pablofernandezmoniz at gmail.com> wrote: > Hello, > > We have being detected some problems with the images and the datasets > provided and wanted to ask in we are doing something wrong or just notify > about them: > > *Issue about restaurants without coordinates* > > We have detected some errors related the failure at retrieving the > coordinate of some restaurants (approximately 165). We have analyzed some > of them and they miss the ?geo? attribute. > Thanks for reporting it. I'll check it and give you an answer ASAP. I knew there were some restaurants that the geocoder couldn't locate, but 165 are too much. > > An example of one of this entities is the restaurant "Otatza Bekoa": > > {"@context":"http://schema.org","@type":"Restaurant","address":{"streetAddress":"Otatza > etxea, > 5","addressRegion":"GIPUZKOA","addressLocality":"ZERAIN","postalCode":"200026","@type":"postalAddress"},"aggregateRating":{"ratingValue":5,"reviewCount":86},"department":"Franchise1","description":"La > sidrer?a Otatza Bekoa est? rodeada de manzanos, y cuenta con maquinaria > moderna para hacer su propia sidra. Dispone de dos comedores, y en ellos, > podremos disfrutar del t?pico men? de sidrer?a y degustar la sidra al > txotx.","priceRange":"24.0","telephone":"943 801 757","name":"Otatza > Bekoa"}, > The missing attribute is due to the reason explained below, the geocoder couldn't locate the address and returns an empty response, and that's why the "geo" entity is not being returned. > *Issue with incorrect geographical references* > > Some restaurants have been located outside Pa?s Vasco (even outside > Europe). > > We suspect that it occurs due to a geocoding problem.We have attached an > screenshot of the clusters to show this discrepancy in the > misplaced-geographical-reference.png file. > Thanks a lot! I'll check this also. Best! Alberto Mart?n -------------- next part -------------- An HTML attachment was scrubbed... URL: From alberto.martin at bitergia.com Wed Oct 28 17:58:43 2015 From: alberto.martin at bitergia.com (=?UTF-8?Q?Alberto_Mart=C3=ADn_Casado?=) Date: Wed, 28 Oct 2015 17:58:43 +0100 Subject: [Fiware-developer-experience] Issues with images and datasets In-Reply-To: References: Message-ID: Hello again! I've been doing changes in the feeder and changing the way we were retrieving the geo-coordinates. On Wed, Oct 28, 2015 at 12:19 PM, Alberto Mart?n Casado < alberto.martin at bitergia.com> wrote: > Hi! > > On Wed, Oct 28, 2015 at 11:17 AM, Pablo Fern?ndez Moniz < > pablofernandezmoniz at gmail.com> wrote: > >> Hello, >> >> We have being detected some problems with the images and the datasets >> provided and wanted to ask in we are doing something wrong or just notify >> about them: >> >> *Issue about restaurants without coordinates* >> >> We have detected some errors related the failure at retrieving the >> coordinate of some restaurants (approximately 165). We have analyzed some >> of them and they miss the ?geo? attribute. >> > > Thanks for reporting it. I'll check it and give you an answer ASAP. I knew > there were some restaurants that the geocoder couldn't locate, but 165 are > too much. > With the changes now 688 restaurants are added and all of them with the geo-location element. A new image has been pushed to docker-hub, and changes are already available at Github. Pulling the changes and running the docker-compose should be enough (it will pull the new data image automatically). > > >> >> An example of one of this entities is the restaurant "Otatza Bekoa": >> >> {"@context":"http://schema.org","@type":"Restaurant","address":{"streetAddress":"Otatza >> etxea, >> 5","addressRegion":"GIPUZKOA","addressLocality":"ZERAIN","postalCode":"200026","@type":"postalAddress"},"aggregateRating":{"ratingValue":5,"reviewCount":86},"department":"Franchise1","description":"La >> sidrer?a Otatza Bekoa est? rodeada de manzanos, y cuenta con maquinaria >> moderna para hacer su propia sidra. Dispone de dos comedores, y en ellos, >> podremos disfrutar del t?pico men? de sidrer?a y degustar la sidra al >> txotx.","priceRange":"24.0","telephone":"943 801 757","name":"Otatza >> Bekoa"}, >> > > The missing attribute is due to the reason explained below, the geocoder > couldn't locate the address and returns an empty response, and that's why > the "geo" entity is not being returned. > > >> *Issue with incorrect geographical references* >> >> Some restaurants have been located outside Pa?s Vasco (even outside >> Europe). >> >> We suspect that it occurs due to a geocoding problem.We have attached an >> screenshot of the clusters to show this discrepancy in the >> misplaced-geographical-reference.png file. >> > > Thanks a lot! I'll check this also. > The geocoding issue is now fixed. All the restaurants are now placed inside Pa?s Vasco. What I've found is, some of the restaurants doesn't have a convenient address, and due to that, the geocoder couldn't locate the restaurant perfectly. Still, now it adds the Locality geolocation, which is the finest point the geocoder can find. Thanks for reporting all the issues! Best, Alberto Mart?n -------------- next part -------------- An HTML attachment was scrubbed... URL: From pablofernandezmoniz at gmail.com Thu Oct 29 14:55:20 2015 From: pablofernandezmoniz at gmail.com (=?UTF-8?Q?Pablo_Fern=C3=A1ndez_Moniz?=) Date: Thu, 29 Oct 2015 13:55:20 +0000 Subject: [Fiware-developer-experience] Logout issue Message-ID: Hi, We noticed an unexpected behaviour in the credentials management. Whenever the user is logged in and the */logout* path is requested for logging out, the */auth* path does not redirect to input IDM credentials. In other words, when a user just logs out, the login process does not ask for user and password until the session expires from server side. We suspect that the issue is with the log out mechanism in the IDM as some time ago we had a similar problem with fiware.lab accounts. Kind regards, ULPGC Team -------------- next part -------------- An HTML attachment was scrubbed... URL: From pablofernandezmoniz at gmail.com Thu Oct 29 17:55:02 2015 From: pablofernandezmoniz at gmail.com (=?UTF-8?Q?Pablo_Fern=C3=A1ndez_Moniz?=) Date: Thu, 29 Oct 2015 16:55:02 +0000 Subject: [Fiware-developer-experience] Doubts creating reviews and reservations Message-ID: Hi! We are implementing the create reviews and create reservations functionalities from the front end, and some doubts related to the associated user have arisen. We follow the API specification for the devguide ( http://docs.devguide.apiary.io/#reference/api-especification-for-devguide/review ) and the request bodies of the examples do not contain information about the users. [See *no_undername_in_example.png*] We consulted the reservationsgenerations.js file and we deduce that the request body should be like: [See *create_reservation.png*] *{* * "@type": "FoodEstablishmentReservation",* * "partySize": 2,* * "reservationFor": {* * "@type": "FoodEstablishment",* * "name": "Elizalde"* * },* * "startTime": "2016-12-24T10:10:23.396Z",* * "underName":{* * "@type":"Person",* * "name":"user10"* * }* *}* At this point we can create the reservation but without an associated user. If we retrieve the reservations we get: [See *reservation_without_undername.png*] *{"@context":"http://schema.org ","@type":"FoodEstablishmentReservation","partySize":2,"reservationFor":{"@type":"FoodEstablishment","name":"Elizalde","address":{"streetAddress":"Cuesta de las Cabras Aldapa 2","addressRegion":"Araba","addressLocality":"Alegr?a-Dulantzi","postalCode":"01240","@type":"postalAddress"}},"reservationStatus":"Pending","startTime":"2016-12-24T10:10:23.396Z","underName":{"@type":"Person"},"reservationId":"Elizalde-418lRljWe"}* We have experimented the same issues creating reviews. What are we doing wrong? Regards ULPGC Team -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: create_reservation.png Type: image/png Size: 103923 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: no_undername_in_example.png Type: image/png Size: 77059 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: reservation_without_undername.png Type: image/png Size: 228802 bytes Desc: not available URL: From pablofernandezmoniz at gmail.com Fri Oct 30 14:47:57 2015 From: pablofernandezmoniz at gmail.com (=?UTF-8?Q?Pablo_Fern=C3=A1ndez_Moniz?=) Date: Fri, 30 Oct 2015 13:47:57 +0000 Subject: [Fiware-developer-experience] Doubts about roles and organizations Message-ID: Hi! We are trying to display different restaurant info for each user. At this moment, we can filter using reviews and reservations for each one. But, if we try to show restaurants filtering by the user's organization, we find that all users (from user0 to user9) have an empty array in the organizations field. We inspect the restaurant, and detect some organizations like Franchise1 or Franchise2. We look up for them in IDM but they don't exist. We also have seen that all users have only one role and they are the same: "Restaurant Viewer". For now, we are hardcoding our test assuming that all users are in the "Franchise2" organization, and showing all options if the user has the role "Restaurant Viewer". We suppose that these missing features are not implemented yet by the user feeder. Is that right? ULPGC Team -------------- next part -------------- An HTML attachment was scrubbed... URL: From alberto.martin at bitergia.com Fri Oct 30 15:52:48 2015 From: alberto.martin at bitergia.com (=?UTF-8?Q?Alberto_Mart=C3=ADn_Casado?=) Date: Fri, 30 Oct 2015 15:52:48 +0100 Subject: [Fiware-developer-experience] Doubts about roles and organizations In-Reply-To: References: Message-ID: Hi! On Fri, Oct 30, 2015 at 2:47 PM, Pablo Fern?ndez Moniz < pablofernandezmoniz at gmail.com> wrote: > Hi! > > We are trying to display different restaurant info for each user. At this > moment, we can filter using reviews and reservations for each one. But, if > we try to show restaurants filtering by the user's organization, we find > that all users (from user0 to user9) have an empty array in the > organizations field. > > We inspect the restaurant, and detect some organizations like Franchise1 > or Franchise2. We look up for them in IDM but they don't exist. > That's true. We've been doing several changes but we did not update the default provision yet. We've added "Franchise1-4" for the tests, in order to have like 4 different franchises, and this should be added also the default provision. > We also have seen that all users have only one role and they are the same: > "Restaurant Viewer". > All but 'user0' and 'user1' (as I remember) have the role "Restaurant Viewer". There will be 3 roles to implement: Global Manager, Franchise Manager and End Users (or restaurant viewers). I still have to invest a bit of time on thinking how to design the proxy for protecting the resources. > For now, we are hardcoding our test assuming that all users are in the > "Franchise2" organization, and showing all options if the user has the role > "Restaurant Viewer". > > We suppose that these missing features are not implemented yet by the user > feeder. > > Is that right? > Yes! Actually the missing fields are regarding IdM and the provision file: keystone_provision.py I'll take note of everything. Thanks!! Best, Alberto Mart?n -------------- next part -------------- An HTML attachment was scrubbed... URL: