Query Execution Optimization for Social Networking Data Privacy
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Retrieving user-created content while adhering to privacy settings and constraints in social networking systems is inefficient, leading to significant computing resource consumption and delays due to multiple back-and-forth operations between frontend and backend servers.
Innovation Solution
Utilizing a declarative language to specify query parameters, identifying a database with a corresponding index, and executing queries to return a reduced data set for further privacy checks at the frontend server, allowing parallel execution of data retrievals and privacy checks, thereby reducing network hops and resource usage.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If multiple back-and-forth operations are performed between frontend and backend servers to retrieve and filter information, then privacy compliance can be ensured, but computing resource consumption increases and system performance deteriorates
Solution Approach 1:
The system performs preliminary actions by retrieving and filtering information at the backend server before it reaches the frontend server. The backend server proactively applies privacy filters and constraints during data retrieval, so that only privacy-compliant information is transmitted to the frontend, eliminating the need for subsequent back-and-forth operations.
Solution Approach 2:
The backend server acts as an intermediary between the database and the frontend server. It receives data retrieval requests, applies privacy settings and constraints as intermediate filtering layer, and returns only compliant information to the frontend. This intermediary role consolidates multiple operations into a single efficient data retrieval process.
2Quantity of substance
If all information is retrieved from the database before privacy filtering, then complete data can be processed, but network hops and computing resources are wasted
Solution Approach 1:
The system extracts and removes non-compliant information at the backend server during the data retrieval process. By applying privacy filters and constraints before data transmission, the system extracts only the necessary privacy-compliant information, eliminating wasted network hops and computing resources associated with processing and transmitting unnecessary data.
3Adaptability or versatility
If privacy checks are performed at the frontend server after data retrieval, then flexibility in processing is maintained, but query execution time increases
Solution Approach 1:
The system performs privacy checks as a preliminary action at the backend server during data retrieval, rather than as a subsequent step at the frontend. This preliminary filtering ensures that only privacy-compliant information is transmitted, significantly reducing query execution time while maintaining processing flexibility through the declarative query language.
Solution Approach 2:
The system changes the parameter of where privacy checks are performed from frontend-server-based to backend-server-based. By moving the privacy check operation to the backend during data retrieval, the system optimizes query execution time while preserving adaptability through the declarative query interface that allows flexible specification of retrieval constraints.
Data Source
AI summary
Various embodiments are disclosed for optimizing the execution of a query to retrieve data associated with multiple entities from a database server system, where the entities are associated with a user of a social networking system. At least one embodiment includes analyzing parameters of the query to identify one or more databases at which to execute the query, determining whether to execute constraint type parameters on the data retrieved at a frontend or backend server of the server system, and separating the performance of privacy checks on the data retrieved from the execution of the query. The embodiment further includes executing, based on the databases identified, the query in parallel threads to retrieve individual data sets of a result set, where a particular individual data set is associated with a particular entity.


