Skip to content

Using CF Agent and Manager

April 25, 2010

Concept

Tools and Services:

  • CF Agent – The Agent that collects and uploads data
  • CF Agent Manager – To Configure CF Agent
  • CF Web Service (https://cloudfunnel.com/webservice) – To communicate directly with CF Server and you can integrate into you existing application for custom solutions
  • CF Website (https://cloudfunnel.com/<accountname>/Website – To visualize data that are being collected and available in the CF Server

The objective of the Tools is to collect data and upload the CF Server

Install one “CF Agent” on each Computer/Network location where data is collected

The CF Agent runs in the background and executes the configured jobs assigned to that Agent

You will use “CF Agent Manager” to configure “CF Agent”

Cloud Funnel Agent (CFA) collects data and uploads to Cloud Funnel Server (Azure SQL Server).

  • Agent – a Network Location, where data will be collected
  • Job – a set configuration that defines what data to collect (Data Source), and how often (Schedule).
  • An Agent can have multiple Jobs, each job maintains is own data source and schedule

 

Configuring CF Agent

Step 1: Run CF Agent Manager

 

  • Login

  • Create Agent(s) and Jobs(s)
  • The Left site tree shows existing Agents and Jobs (will be empty/blank if none exists)

  • Click “New Agent” from the Agents menu to create a new Agent


  • Select the Agent that you want to add a new Job and Click “New Job” from the Jobs menu

 

 

 

  • Creating a new Job, make sure to select the appropriate Job Type

  • Configure the Database – the screen shot shows configuring SQL server express database in the local system where CF Agent Manager is being run with a trusted connection.

  • Query should be written to always return new data, as each time job is executed by the Agent

    For example the following query below returns the transactions happened last hour, will be useful when the job is run every hour.

    SELECT * FROM transactions WHERE transactiondate between DATEADD(hh,DATEPART(hh,GETDATE())-1,DATEADD(dd,0, DATEDIFF(dd,0,GETDATE()))) AND DATEADD(ss,-1,DATEADD(hh,DATEPART(hh,GETDATE()),DATEADD(dd,0, DATEDIFF (dd,0,GETDATE()))))


  • Unique Column(s) is optional, but very useful when query cannot be written to pull only new data. By defining the Unique column simplifies and CF Agent automatically pulls only new data.

For Example if the query is simply written as

    Select * from transactions

And then define a unique column as shown below:

  • Here you enter a column name that is part of the query (select * from transactions should have column with a name transactiondate)
  • Enter a default value to be used when a job runs first time, here since the job is never run, enter a value that will pull all the transactions when job is run first time
  • Running Value – defined by a query or formula. (Note: formula will be available in future version)
  • Enter a query that returns a scalar value, and this value will be retained each time job is run as per schedule

Explanation:

Let’s say first time the job is run on 4/25/2010 at 10 am, the database has data for the past 2 months. And you are creating a job that will be run every hour. But when the job is run first time, you will want all the data that is there in the database.    

  • So you can enter a default value with a much older date : 1/1/2001, so when the query runs
  • Select * from transactions where transactiondate > ’1/1/2001′ for the first time on 4/25/2010 10:00am.
  • Since you have defined a unique column with a running value ‘select getdate()’, it keeps the value 4/25/2010 10:00 am.
  • And when the job is run next hour, query runs like this (since the job is configured to run every hour):
  • Select * from transactions where transactiondate > ’4/25/2010 10:00am’

 

  • Here the schedule shows that is configured to run every hour

     


  • After saving, you will on the left side


 

 

Uploading Data

  • To upload data download and run the CF Agent on the system
  • Available at https://cloudfunnel.com/downloads/cfa/cfa.application and also available in the website


  • When run for the first time, it will ask to select an Agent, enter account, user and password and click Connect and then select the Agent (created earlier using CF Agent Manager) and Click Save

  • After Clicking Save, you will the CF Agent Status Window, and you can minimize the window, it will hide and run in the background.

  • You can anytime bring it from the system task tray:


  • By double clicking on the Cloud Funnel Agent Icon you can bring back the CF Agent Status window
No comments yet

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.