CS-499 Capstone Project Static Demonstration
For the full interactive experience with real database operations:
git clone https://github.com/annjessicatan/annjessicatan.github.io.gitcd annjessicatan.github.io/capstone-project/animal-shelter-systempip install -r requirements.txtpython app.pyhttp://localhost:5000# Sample code from TAN_CRUD_Python_Module.py
class AnimalShelter:
"""CRUD operations with comprehensive enhancements"""
def read_with_cache(self, query, limit=1000, cache_ttl=300):
"""Read with LRU caching implementation"""
cache_key = self._generate_cache_key(query, limit)
if cache_key in self.cache:
cached_data, timestamp = self.cache[cache_key]
if time.time() - timestamp < cache_ttl:
self.cache_stats['hits'] += 1
self.cache.move_to_end(cache_key)
return cached_data.copy()
# Cache miss - query database
self.cache_stats['misses'] += 1
results = self.read(query, limit)
# Store in cache
self.cache[cache_key] = (results.copy(), time.time())
self.cache.move_to_end(cache_key)
# Enforce size limit
if len(self.cache) > self.max_cache_size:
self.cache.popitem(last=False)
self.cache_stats['evictions'] += 1
return results
This is a static demonstration. For the full interactive dashboard with live database operations, please run the application locally.
Author: Ann Jessica Tan
GitHub: @annjessicatan
Project Repository: annjessicatan.github.io
Capstone Portfolio: https://annjessicatan.github.io