A full-stack video sharing platform built with modern web technologies.
-
Next.js 14
- React framework for production
- Server-side rendering
- File-based routing
/appdirectory structure
-
TypeScript
- Static type checking
- Enhanced code reliability
- Type definitions for data models
-
Firebase
- User authentication with Google Sign-In
- Cloud Functions for serverless operations
- Security Rules for data protection
-
Firestore
- NoSQL database for scalable storage
- Video metadata management
- User data persistence
- Collections: 'videos', 'users'
-
Cloud Storage
- Raw videos bucket for uploads
- Processed videos bucket for transcoded content
- Signed URLs for secure file handling
-
Cloud Run
- Containerized video processing service
- Automatic scaling
- Managed infrastructure
-
Pub/Sub
- Asynchronous message handling
- Video processing event triggers
- FFmpeg
- Video transcoding capabilities
- Resolution standardization
- Format conversion
- Playwright
- End-to-end testing
- Navigation flow verification
- UI interaction testing
- Docker
- Application containerization
- Cross-platform compatibility
- npm/Node.js
- Package management
- JavaScript runtime environment
When loading up the website, users are introduced with all videos added. Videos are able to be viewed whether the user is logged in or not logged in.
This is what the user sees when logging into the website. When the user pressed Sign In, the user is redirected to log in with Google. Log in information of the user is stored in Firebase authentication and a Firestore collection named "users". Videos are able to be uploaded by the user when logged in.
When videos are uploaded by the users, the video is stored onto Google Cloud in a raw bucket. The user is then notified on the website that the upload was successful. After being uploaded to the raw bucket, the video begins to process in 360p. After done processing the video is placed in a new bucket on Firestore as seen below.
After the video is processed and stored into the processed bucket, the video information is stored into Firestore and is ready to be displayed on the webclient.
The video is now rendered and ready to view on the website.
Just to introduce myself to Playwright and Typescript, I created a simple test that clicks the website and functionality of navigating the website.
Because the project covers the bare bones of a full stack development project, Pub/Sub has many limitations. An example would be, if the video processing takes longer than 600 seconds, Pub/Sub will close the HTTP connection. Becuase of this we will never be able to send the acknowledgement to Pub/Sub. We can fix this in future development by using a pull subscription instead of a push subscription.