Overview
TeeBI includes an optional transparent remote web server for fast data access. The server can serve compressed binary streams of raw array data over HTTP, enabling:- Remote data access from client applications
- Centralized data management
- Reduced client-side data processing
- Automatic compression for network efficiency
Architecture
The web server architecture consists of:- Server: Hosts TDataItem datasets and responds to HTTP requests
- Client:
TBIWebClientclass for accessing remote data - Protocol: HTTP-based with query string parameters
- Compression: Optional ZIP compression of binary data streams
Server Setup
See the Web Server demo for a complete server implementation.Basic Server Configuration
The server listens on port 15015 by default (configurable):Client Usage
Creating a Web Client
Quick Load from URL
Load from Full URL
Compression
The web server supports transparent compression of data streams.Enable Compression
Compression Benefits
- Bandwidth Reduction: Typically 70-90% size reduction
- Faster Transfer: Less data to transmit over network
- CPU Trade-off: Uses CPU for compression/decompression
Compression Implementation
FromBI.Web.pas:386-390:
Query Parameters
The web server accepts various query string parameters:data
Specify which dataset to retrieve:children
Include child/related data items:zip
Enable compression:meta
Retrieve only metadata (no data rows):sql
Execute server-side query:format
Output format (for browser viewing):Advanced Features
Proxy Support
Timeout Configuration
Progress Events
Delayed Loading
Load data on-demand using delay providers:Server-Side Processing
Perform queries and aggregations on the server to reduce data transfer:Online Demo
Try the live web server: http://steema.cat:15015/?data=SQLite_demo&format=.jpgVersion Information
FromBI.Web.pas:163-175:
Best Practices
- Enable Compression: Always use compression for network efficiency
- Server-Side Queries: Aggregate data on server before transferring
- Metadata First: Load metadata, then data on-demand if needed
- Connection Pooling: Reuse TBIWebClient instances when possible
- Error Handling: Wrap web calls in try/except for network failures
- Timeout Management: Set appropriate timeouts for your network
- Secure Connections: Consider HTTPS in production (requires web server configuration)
