Architecture :: How To Create/trigger A Server-only Script
Sep 13, 2010
I have a site that sends a good bit of emails, some one at a time, and some larger groups of admin emails. I'm running on a shared hosting service. The mailserver is horribly slow, so any script that sends a single email can take as much as 15 seconds to execute (and I can't seem to set Response.BufferOutput to false, so the whole page has to wait the entire duration). On the bulk emailings, it can take minutes for that to run.
I want to create a "mail queue" of my own... I want any script that sends an email to, instead, write a row to a db table containing the necessary email info, which will let the script get on with its business quickly. Then, I want to create a script that runs on the server only, and have it check the table for emails, send them, and remove them from the table.
I know I can have the "mailsender" script run as a scheduled task, and it would thereby run on the server only. But I would prefer to have the initial script somehow "trigger" the mailsender script.
Is there a way in asp.net to create a script that will execute solely on the server, and call that script from another page, so that the calling page doesn't wait for the server script to execute?
I am try to create architecture design for WCF service.
We have WCF service that we have to expose to third party so then can request with xml and get back xml response.
The wcf service should do the following:
- Accept the request call with xml
- Check xml against the schema
- Parse the xml
- Authenticate the incoming xml by username and password that will be in xml
- Send back the response
If anybody can let me know what kind of design I can use or is there any pattern available that I can take it and then extend it as per my requirement.
I was tasked to create 3 tier web application. However, i browsed through many books & tutorials. The examples are doing it using Object data source which my lecturers claimed that it is not 3 tier at all. Shouldn't be dragging any data source into deisgn view. Any comprehensive examples for me to take reference from?
I am trying to use SqlDependencyCache buthave come across a problem that I wouldn't have thought was unique. We have a InformationDatabase which uses a combination of its own tables and views to other databases on the same server. One of these views points to our HRDataWarehouse database. My stored procedure obviously uses this view to get its information but because the table change is happening on the HRDataWarehouse table the notification is not being sent to my app and as a consequence the cache is not removed.
Is there a tidy way of doing this or do I need to create a trigger to update a table in my informationdatabase and then have a listener on this with a removecache callback delegate added to the cache object?
I am building service failure notification system which notifies customers and management whenever there is a delay in the service. How can I use SQL SERVER trigger to send an email to a group of people when I add an alert in the alert database table using c#.
An external application come to my database for inserting row in a Sql server table.I have a web application on my own, and I want on each insert in this table, do some treatement server side.My idea is to create a trigger on insert on the table, and then call appropriate function
I'm creating an application that's supposed to first add a record to table1, and then get the ID from that record to use when adding a record to table2, to be able to associate these two records with eachother.
The user gets to type in some values that goes to table1, and some values that goes to table2, but before the insert statement for table2 is executed i need the ID from the recently added record in table1. Some dude told me to use a trigger for the autopopulate purpose, but does that really work when i also need to save some values that's user input, and when those values doesn't get saved in table1?
Are there any other way to do this or can i send values to a trigger?
i want to create a trigger after i insert record in table1 and in trigger there will be an update sentece which updates x column in table2 so i have a stored procedure like insert into Table1(a,b,c) values(1,2,3)select @@identity then my trigger should update table 2 update table2 set x=5 where id=@a @a parameter must come from my insert stored procedure's select @@identity line how can i create a trigger like this? this will be my first trigger so i dont know anything about them after creating trigger i think i should control if it execute successfully or not in my insert stored procedure so if it works successfully my insert is ok but if trigger doesnt work my insert sentence shouldnt work
I M little bit confuse that Presently i m using SQL server 2005 and for data access i m using Store procedure but now i want to use trigger first thing about trigger is:-
1. what is the benefit of using trigger over store procedure?
2. Is Performance is effected if i use trigger i mean that is my site work fast or is it much secure.
i need trigger function for update. if a change value of a column in one table. The value of different column from the second table should update the value in the third table.
i am using a trigger to insert records into my table2 when records inserted in table1 . i am using SSIS to insert records in table1 when inserting records in table1 i need to fire the trigger i created on table1 .But it is not firing . is that because of SSIS inserting bulk records into table1 at one time?. If so how i can fire my trigger and insert records into table2 from table1.
I want to create a trigger for insert and whenever i insert the data the trigger should fire and notify some value inserted i want to create log table to save this information,now i have created a trigger but i dont know how to map it to log table to notify the changes?
Header Table has a trigger for Delete i.e. when a record from Header Table is deleted, all records from LineItem Table having that HId also gets deleted. Every thing works fine till here, now LineItem table also has a trigger for Delete which Updates/Deletes few other tables.
The problem I am facing is if 5 record having HId = 1 gets deleted from LineItem table the LineItem Delete trigger only runs for first record. Why trigger is not working for all the deleted LineItem records?
i have a gprs device that logs data to a webpage.i am using get method for the data transfer from device to web application. This function is working perfectly. what i want to do now is by clicking a button to send a get method from server to device in order to triggger it to do some actions. the device is correctly receiving the get method and sends a responce. The problem is that the http responce the device is sending might be wrong because the browser is waiting until timeout and then it displays the responce. does anyone knows what is the http responce format?
iam developing web page where i want to create trigger on insert command. iam using vs2008 vb.net and in built sql express 2005 which is in app_data..... under this my datbase.mdf i can see tables, views,stored procedures,functions,synonmes,types ,assemblies. but there is no triggers folder. how to craete trigger in this
I have a Wherehouse app where I have my Inventory table wich has columns like id, code, description,Price1, Price2,Price3 and another table wich is orderdetail with columns id, ordernum, code, quantity.
I recenlty add the columns Price1, Price2,Price3 into orderdetail and I need to populate those columns on the background beacuse users are not allow to see the prices.( I´ts has to be populate when the user insert a new item into the orderdetail table)
I have a third party dll and i need to add some more functionalities (methods, constants etc..) so create a wrapper class. I have no idea about wrapper classes. what is the purpose of this and how to create in .NET for this 3rd party dll.