I would like to understand how many datapoints (maximum limit ) we can add in dpConnect() function in a single script.
Also how it will effect event manager of the project if we add around 300 points in single dpConnect()?
Thank you
dpConnect() function
- leoknipp
- Posts:2928
- Joined: Tue Aug 24, 2010 7:28 pm
Re: dpConnect() function
Hello,
there is no (technical) limit for the number of dp elements for a dpConnect().
If it useful to add 300 elements in one dpConnect() depends on the work function which will be called everytime if one of the connected values changes.
Maybe using a dpQueryConnectSingle() is better when addressing a lot of dp elements, then only you get those elements which have been changed.
Best Regards
Leopold Knipp
Senior Support Specialist
there is no (technical) limit for the number of dp elements for a dpConnect().
If it useful to add 300 elements in one dpConnect() depends on the work function which will be called everytime if one of the connected values changes.
Maybe using a dpQueryConnectSingle() is better when addressing a lot of dp elements, then only you get those elements which have been changed.
Best Regards
Leopold Knipp
Senior Support Specialist
- Gertjan van Schijndel
- Posts:634
- Joined: Mon Aug 02, 2010 10:37 am
Re: dpConnect() function
The config entry 'maxConnectMessageSize' limits the number of dp elements for a dpConnect.
The performance also depends on how much of the connected dpes are written together. In the best case all values are written together, only 300 values are send to the callback function. But in the worst case the values are written one by one, causing 300x300=90.000 values to be send to the callback function.
The performance also depends on how much of the connected dpes are written together. In the best case all values are written together, only 300 values are send to the callback function. But in the worst case the values are written one by one, causing 300x300=90.000 values to be send to the callback function.
- Shweta Sawant
- Posts:17
- Joined: Tue Mar 24, 2015 6:18 am
Re: dpConnect() function
Thank you for replying 
@Leopold:
I will try dpQueryConnectSingle() option. As far as the help says, this function accepts single query.
However, I need to connect to dps of different datatypes and also selected dps of single datatype.
I need to form query accordingly.
@Gertjan:
maxConnectMessageSize = 300
does it mean event manager can handle 300 dp changes that occur at a time ??
Thank you again
Best Regards,
Shweta
@Leopold:
I will try dpQueryConnectSingle() option. As far as the help says, this function accepts single query.
However, I need to connect to dps of different datatypes and also selected dps of single datatype.
I need to form query accordingly.
@Gertjan:
maxConnectMessageSize = 300
does it mean event manager can handle 300 dp changes that occur at a time ??
Thank you again
Best Regards,
Shweta
- leoknipp
- Posts:2928
- Joined: Tue Aug 24, 2010 7:28 pm
Re: dpConnect() function
Hello,
the config entry maxConnectMessageSize limits the number of dp elements which can be used in one dpConnect().
It is not a limitation for the number of value changes at the same time.
Best Regards
Leopold Knipp
Senior Support Specialist
the config entry maxConnectMessageSize limits the number of dp elements which can be used in one dpConnect().
It is not a limitation for the number of value changes at the same time.
Best Regards
Leopold Knipp
Senior Support Specialist
- Shweta Sawant
- Posts:17
- Joined: Tue Mar 24, 2015 6:18 am
Re: dpConnect() function
Ok. Thank you Leopold 
Best Regards,
Shweta
Best Regards,
Shweta