#142-mockup-room-service #259
Labels
No labels
_CRITICAL_
API
app
backEnd
Blocked, waiting for further changes
bug
cleanup
close
design
duplicate
enhancement
feature request
frontEnd
help wanted
invalid
low priority
needs input
needs review
project documentation
question
research
reviewed
script
security
SQL
style
testing
topLevel
wontfix
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Andras/BoundlessFlowCampus2K!259
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "#142-mockup-room-service"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Har kommit så långt att man kan få fram data till frontend, har exempel View som kan användas för testning
I did briefly review on as I was reading the code for reusing of BookingDbHandler.
I have not run the code on my machine as I have many changes on my local but if someone else can run it then it looks good to me :)
@ -0,0 +4,4 @@using Dapper;using System.Text.Json;string connectionString = "Host=PostgreSQL;Port=5432;Database=sensors;Username=postgres;Password=AFnRTQac7e4c";I have added a environment variable for this in my branch we can reuse that after I have pushed my branch.
@ -0,0 +91,4 @@});Unused spaces can be removed. 94 to 98
@ -0,0 +15,4 @@{"bookingNr":"2","building":"C","roomNr":691,"startTime":"2026-04-18T02:15:00","endTime":"2026-04-18T04:45:00"},{"bookingNr":"1","building":"A","roomNr":462,"startTime":"2026-04-20T23:30:00","endTime":"2026-04-21T00:30:00"}]-----------------------------------------Very good README
@ -0,0 +1,6 @@@roomBookingApiMockup_HostAddress = http://localhost:5226GET {{roomBookingApiMockup_HostAddress}}/weatherforecast/I think this comes when you create the project can be safely removed.
I removed from ParkingService and it works fine:
Andras/BoundlessFlowCampus2K@b4b4a06c4d@ -0,0 +5,4 @@using System.Data.SQLite;namespace SensorReadShall this not be renamed to
namespace RoomBookingReadTesting the build:
The docker file one in the roomBookingApiMockup shall be renamed from
DockerFIle to Dockerfileotherwise this command does not work:docker build -t roombookingapimockup .Add this command
docker build -t roombookingdbhandler .also in the README of the roomBookingDbHandler even though we have the build script since the current buildScript in linux requires that the image exist at least once then the script worksadd this lines to UnixBuild.sh for Linux users: I will send the code below to DM as it here when I paste here it interprets the # as Header :
Before dockerCompose commentAfter adjusting the last comments I'all approve.
@c24elipe @b24johka @a24antej
It looks good to me now approved 👍!
Tested building the Docker image for roomBookingApiMockup. The build completed successfully without errors.
Tested building the Docker image for roomBookingDbHandler. The build completed successfully without errors.
The test was performed using docker compose up --build.The result shows that booking data is generated,sent via MQTT, received by the middleware, and stored in PostgreSQL.This confirms that the system works correctly.
I tried to verify the room booking flow together with the frontend, but I was not able to fully test the frontend end-to-end. From the logs, roomBookingApiMockup keeps printing "no data to upload waiting...", and roomBookingDbHandler eventually hits a HttpClient.Timeout after 100 seconds.
Additionally, when testing the API through nginx using /api/roombooking/all, it returns 404.
I’m not completely sure if I’m testing this correctly or if there is an issue in the setup, but based on the behavior it seems like the room booking backend is not consistently providing data. Because of that, I couldn’t properly verify the frontend part yet.
the backend is set to only provide 4 bookings and the "no data to upload waiting..." is the db handler waiting for potential more data, do not currently know how to work around it because the db hanlder runs in an forever loop.
need to know more how MQTT works before i can come upp with a better solution
when starting the project i used the windowsBuild script, there could be something that you have missed from that.
Thanks, I used the build script as well, but I’ll go through it again to make sure I didn’t miss anything
I ran the setup again using WindowsBuild.bat, and now everything works. The booking data shows up in the frontend, so it seems my previous issue was just due to my local setup.I think the issue earlier was that my local setup wasn’t fully initialized correctly.
A question has been raised regarding this pull request, why would the conf file in entrypoint be changed? we have noticed that the other mockup generator did not change this file.
this is to set this as a api(like tempService), this way you can reach it from the frontend like this "http://localhost/api/roombooking/all"
I just want to mention Parking Api also has this changed in the entry point. This is needed in order to communicate with the frontend.
https://git.webug.se/Andras/BoundlessFlowCampus2K/src/branch/team_1_week_1/entryPoint/nginx.conf
~
It was just not mentioned in the pr comments. My bad. I can update the comment.It was mentioned on point 7Sorry! Apperantly we werent up to date with our branch.
We will merge this pull request soon.
Manually merged to temp branch
Pull request closed