AnyDAC
ContentsIndexHome
PreviousUpNext
Connect to DataSnap server

Describes how to connect to Multi-Tier DataSnap servers.

Group
Links
Supported versions

The Multi-Tier AnyDAC DataSnap driver supports:

  • DataSnap servers built with RAD Studio 2007 and higher;
  • DataSnap clients built with RAD Studio XE2 Enterprise and higher.

 

Client software

AnyDAC statically links Embarcadero DataSnap dbExpress driver, so no additional files and DLLs is required. Supported is RAD Studio XE2 Enterprise and higher. 

 

Driver linkage

To link the DataSnap driver:

 

Connection definition parameters

To connect to the DataSnap server, most applications will need to specify DriverID, Protocol, Server, Port, User_Name, Password

 

DriverID=DataSnap  

Parameter 
Description 
Example value 
Protocol 
The protocol used to connect to the DataSnap server. It may be one of the following values:
  • TCP/IP. Connect using TCP/IP protocol. Is default protocol.
  • HTTP. Connect using HTTP protocol.
 
TCP/IP 
Server 
Server address to connect to. 
127.0.0.1 
Port 
The TCP/IP or HTTP port on which the DataSnap server is listening. The default value for TCP/IP is 211, for HTTP - 8080. 
211 
User_Name 
DataSnap server authentication user name. 
 
Protocol 
DataSnap server authentication user password. 
 
BufferKBSize 
Buffer size in kilobytes to use for read and write operations. The default value is 32Kb. 
64 
Filters 
Client filters, used to store the filter configuration. The default value is empty. 
 
URLPath 
HTTP only. URL path used for HTTP DataSnap Service when http protocol is used. The default value is empty. 
 
DatasnapContext 
HTTP only. Path toward the DS HTTP Service, used to compose the URL. The current convention is: http://x.com/datasnap/provider/classname/method/params. The user may change or delete datasnap word from it. The default value is 'datasnap/'. 
 
DSProxyHost 
HTTP only. The host to proxy requests through, or empty string to not use a proxy. The default value is empty. 
 
DSProxyPort 
HTTP only. The port on the proxy host to proxy requests through. Ignored if DSProxyHost isn't set. The default value is empty. 
 
DSProxyUsername 
HTTP only. User name for proxy authentication. The default value is empty. 
 
DSProxyPassword 
HTTP only. Password for proxy authentication. The default value is empty. 
 
DSAuthenticationScheme 
HTTP only. DataSnap authentication scheme. Used in conjunction with DataSnap user name and password for authentication using the HTTP protocol. Set to "basic" in order to send User_Name / Password values using basic HTTP authentication, in addition to sending these values in the DBX connection string. Basic HTTP authentication may be used to pass credentials to an inter-process DataSnap HTTP tunnel server. The default value is empty. 
 
LoginTimeout 
HTTP only. Connect timeout value. The values provides the number of milliseconds the client waits for the connection to be possible. The value provides the time out for the first server response acknowledgment rather than for the entire connect/authenticate phase. It should be used in order to avoid application freeze when it may be possible to attempt connections to older DataSnap Server versions or different application that will not acknowledge current communication protocol. The default value is empty. 
 
CommunicationTimeout 
HTTP only. Timeout value in milliseconds for a response after the connection is established. The default value is empty. 
 

 

Usage cases
  • Connect to local DataSnap server with default settings:

 

DriverID=DataSnap

 

  • Connect to DataSnap server using TCP/IP protocol running on local host:

 

DriverID=DataSnap
Protocol=tcp/ip
Server=127.0.0.1
Port=211
User_Name=dsusr
Password=123
What do you think about this topic? Send feedback!