SmartFTP Forums: Not Receiving "On Transfer Queue Item Group Proccessd" Email Notification - SmartFTP Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Not Receiving "On Transfer Queue Item Group Proccessd" Email Notification

#1 User is offline   Jon H 

  • Group: Members
  • Posts: 14
  • Joined: 02-November 09
  • Gender:
    Male

Posted 02 November 2009 - 09:44 PM

We're considering purchasing a professional license for SmartFTP and the must have feature for us is receiving an email after a group of queued items has been processed.

I've checked "On transfer queue item group processed" and tested our email settings (other notification options work great) but for some reason if I drop three items into the monitored folder I get emails for each one, not just one for the entire group.

Is this how the notifications are suppose to work? If so that's fine, I'm wondering if it would it make more sense to have the monitor folder launch an email script "onend", although I'm not sure "onend" refers to an individual file uploading in the queue, or the entire queue being completed.

Any suggestions to accomplish this will result in us immediately purchasing this outstanding product!

- Upon a group of files being uploaded (via the folder monitor) send an email saying that the group has processed.

Thanks,

~ Jon

#2 User is offline   mb 

  • Developer
  • Group: Root Admin
  • Posts: 8910
  • Joined: 11-October 01
  • Gender:
    Male
  • Location:
    Worldwide

Posted 02 November 2009 - 10:29 PM

Hello Jon ..

What version are you running?
-> Please post the system information from the menu: Help->About "System Information" dialog.

Thank you
Regards,
Mat

#3 User is offline   Jon H 

  • Group: Members
  • Posts: 14
  • Joined: 02-November 09
  • Gender:
    Male

Posted 03 November 2009 - 05:19 AM

View Postmb, on 02 November 2009 - 02:29 PM, said:

Hello Jon ..

What version are you running?
-> Please post the system information from the menu: Help->About "System Information" dialog.

Thank you
Regards,
Mat


+- System -----------------------------
Microsoft Windows 2008 R2 Server Enterprise Edition (full installation) 
 (Build 7600)

CPU Speed           : 1861 MHz
Total Memory        : 12287 MB
Free Memory         : 10838 MB

+- SmartFTP ---------------------------
Version             : 4.0.1063.0
Time Stamp          : 2009-10-31 20:55:55
Platform            : x64
Unlicensed
Days in use         : 0

+- Language ---------------------------
en-US

+- Internet Explorer ------------------
Version             : 8.0.7600.16385

+- Winsock ----------------------------
Winsock             : 2.2


Since posting this I've got a vbs script enabled via the tab under the transfer queue monitor. It does work except it send out an alert at the beginning of the transfer rather than when all the items have finished:

Dim objMessage
Set objMessage = CreateObject("CDO.Message")
objMessage.Subject = "The Items in Your Locally Monitored Folder Finished Transferring Successfully"
objMessage.From = "you@you.com"
objMessage.To = "me@me.com"
objMessage.TextBody = "A bunch of items in this particular transfer queue monitored folder finished transferring.  Enjoy!"

Sub TransferQueueOperation_onend() 
	'==This section provides the configuration information for the remote SMTP server.
	'==Normally you will only change the server name or IP.
	objMessage.Configuration.Fields.Item _
	("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
	'Name or IP of Remote SMTP Server
	objMessage.Configuration.Fields.Item _
	("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.somewhere.com"
	'Server port (typically 25)
	objMessage.Configuration.Fields.Item _
	("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
	objMessage.Configuration.Fields.Update
	'==End remote SMTP server configuration section==
	objMessage.Send 
End Sub


Thanks for any help!

#4 User is offline   mb 

  • Developer
  • Group: Root Admin
  • Posts: 8910
  • Joined: 11-October 01
  • Gender:
    Male
  • Location:
    Worldwide

Posted 03 November 2009 - 06:17 AM

Items with a monitor operation are handled differently compared to the items with for example a copy operation. First a short overview of the program flow:

Copy Operation (not what you want)
    The operation of the item starts
    The operation creates the new children (there is parent/child relation) and groupid of the item is inherited
    The operation adds the new items to the queue
    The operation ends (the Operation_onend event handler is called here)
    The item status is to "Wait For Children".
    Once all children are processed the parent item status is set to finished. When this happens the queue checks whether there are any more items with the groupid. Since this is the last item the "On Queue Item Group" event is fired.

Monitor Operation
    "Item" detects changes in the monitored folder
    The operation of the item starts
    The operation creates the new children (there is parent/child relation) and the groupid of the item is inherited
    The operation adds the new items to the queue
    The operation ends (the Operation_onend event handler is called here)
    The item status is immediately reset (set to idle). Meaning it does not wait until the new children are finished.

The monitor item does not wait for its children because this way it can add new items to the queue as soon as it detects a change.
As you can see at the time the status is set to idle there is most likely another item with the same groupid in the queue and therefore the "On Queue Item Group" event is not fired.

Possible ways to fix this:
1. For monitor operations use a new groupid for all the items the operation adds.
2. Make the monitor operation wait until all children are finished

I want to see how I can implement number one. I'm not yet convinced that waiting for the monitor operation is a good idea, but it actually might be. Any thoughts on this?

Regards,
Mat

#5 User is offline   Jon H 

  • Group: Members
  • Posts: 14
  • Joined: 02-November 09
  • Gender:
    Male

Posted 04 November 2009 - 12:54 AM

View Postmb, on 02 November 2009 - 10:17 PM, said:

Items with a monitor operation are handled differently compared to the items with for example a copy operation. First a short overview of the program flow:

Copy Operation (not what you want)
    The operation of the item starts
    The operation creates the new children (there is parent/child relation) and groupid of the item is inherited
    The operation adds the new items to the queue
    The operation ends (the Operation_onend event handler is called here)
    The item status is to "Wait For Children".
    Once all children are processed the parent item status is set to finished. When this happens the queue checks whether there are any more items with the groupid. Since this is the last item the "On Queue Item Group" event is fired.

Monitor Operation
    "Item" detects changes in the monitored folder
    The operation of the item starts
    The operation creates the new children (there is parent/child relation) and the groupid of the item is inherited
    The operation adds the new items to the queue
    The operation ends (the Operation_onend event handler is called here)
    The item status is immediately reset (set to idle). Meaning it does not wait until the new children are finished.

The monitor item does not wait for its children because this way it can add new items to the queue as soon as it detects a change.
As you can see at the time the status is set to idle there is most likely another item with the same groupid in the queue and therefore the "On Queue Item Group" event is not fired.

Possible ways to fix this:
1. For monitor operations use a new groupid for all the items the operation adds.
2. Make the monitor operation wait until all children are finished

I want to see how I can implement number one. I'm not yet convinced that waiting for the monitor operation is a good idea, but it actually might be. Any thoughts on this?

Regards,
Mat


Hey Mat,

Thanks for the great feedback. I only see these options for transfer queue operations: Unknown, Copy, Move, Delete, Edit, ReadDirectory, SetPermissions, Custom how would I get it to Monitor and still copy?

Thanks,

~ Jon

#6 User is offline   mb 

  • Developer
  • Group: Root Admin
  • Posts: 8910
  • Joined: 11-October 01
  • Gender:
    Male
  • Location:
    Worldwide

Posted 04 November 2009 - 02:11 AM

I probably confused you when I mentioned "Monitor Operation". There is no monitor operation per se.
So set the operation to copy and then enable the monitor in the Monitor dialog in the transfer queue item properties.

#7 User is offline   Jon H 

  • Group: Members
  • Posts: 14
  • Joined: 02-November 09
  • Gender:
    Male

Posted 04 November 2009 - 11:16 PM

View Postmb, on 03 November 2009 - 06:11 PM, said:

I probably confused you when I mentioned "Monitor Operation". There is no monitor operation per se.
So set the operation to copy and then enable the monitor in the Monitor dialog in the transfer queue item properties.


Hey Mat,

I'm really feeling lost with all the SDK info I've been reading and would like to simply be pointed in the right direction to get this accomplished. I've read up on the "ScriptHost" and "TransferQueueOption" and neither seem to offer what I need, which seems like a small request:

1. If one of the three transfer queues I have adds files via the monitoring, send an email simply stating files have been added to this queue.
2. If one of the three transfer queues finishes transferring X amount of files, send an email simply stating files in that particular queue have finished transferring.

Is there any doc or sample VBS code you could point me to that I can use? At times we have up to 200 files transferring per queue so an email for each would be too much. Just two: one for the beginning and end of the queue would be awesome.

Thanks,

~ Jon

#8 User is offline   mb 

  • Developer
  • Group: Root Admin
  • Posts: 8910
  • Joined: 11-October 01
  • Gender:
    Male
  • Location:
    Worldwide

Posted 04 November 2009 - 11:45 PM

You cannot realize it with the SDK right now but you can use the Email notification that are built-in. Go to the menu: Tools->Settings. Then go to the Queue->Email dialog.

Then enable the "Item Group" notification.

#9 User is offline   Jon H 

  • Group: Members
  • Posts: 14
  • Joined: 02-November 09
  • Gender:
    Male

Posted 05 November 2009 - 12:01 AM

View Postmb, on 04 November 2009 - 03:45 PM, said:

You cannot realize it with the SDK right now but you can use the Email notification that are built-in. Go to the menu: Tools->Settings. Then go to the Queue->Email dialog.

Then enable the "Item Group" notification.


Thanks Mat, I believe this is on the patched version you provided me?

Something odd I'm experiencing with this version though, if I try to upload something to a server (that works perfectly fine with other FTP clients) the transfer fails and I keep getting the following:

[15:58:27] MLST test.zip
[15:58:27] 550 File or directory not found.
[15:58:27] The operation has been added to the Transfer Queue. Check the Transfer Queue for the status.

I've tried multiple servers and not getting anywhere, any ideas?

Thanks,

~ Jon

This post has been edited by Jon H: 05 November 2009 - 12:02 AM


#10 User is offline   mb 

  • Developer
  • Group: Root Admin
  • Posts: 8910
  • Joined: 11-October 01
  • Gender:
    Male
  • Location:
    Worldwide

Posted 05 November 2009 - 01:32 AM

>I believe this is on the patched version you provided me?
Correct

>Upload
This is no error per se. SmartFTP uses multiple connections:
- One connection for the browser
- One or more connections for the transfers

To check whether your transfers complete check the transfer queue. What you see in the log in the remote browser (e.g. the 550 file not found) is irrelevant for the transfers.

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users