Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3985776
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T05:55:54+00:00 2026-05-20T05:55:54+00:00

I am in the process to implement a Windows Service which is hosting a

  • 0

I am in the process to implement a Windows Service which is hosting a “Sequential Workflow” (Windows Workflow-Foundation).
The sequential workflow is quite simple and, basically, is nested in a while activity which never ends.
The primary purpose is to schedule jobs over a certain period of time.
Since the project shares part of the infrastructure with an ASP.NET MVC application, I would like to re-use what I’ve built so far.
I’ve split the windows-service project in two part: the service itself and the workflow project.
The service is a “stupid” container with the only reference to the workflow; it’s main purpose is to start it:

workflowEngine = new WorkflowRuntime();
WorkflowInstance instance = workflowEngine.CreateWorkflow(typeof(BpReminders.WorkFlow.Scheduler), parameters);
instance.Start();

The workflow-foundation project references all the other projects I need to use and is responsible for the dependency injection (structureMap).

I’ve created a prototype now and everything seem to work.
Now, my dilemma is, should be the windows-service responsible to resolve the dependencies and inject those in the workflow or my approach is good enough considering that one day I might decide to change the host of the workflow?
Is it possible, eventually, to use structureMap to inject the dependencies in a workflow project?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T05:55:55+00:00Added an answer on May 20, 2026 at 5:55 am

    Since you would have to use property injection to inject into the workflow anyway, I would prefer to call the container inside the workflow to build up objects as needed. If you do want to do property injection, take a look at this: http://codebetter.com/jeremymiller/2008/10/09/setter-injection-in-structuremap-2-5/.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to design a windows-service which monitors a process namely Gtalk, if
I have a Windows Service which performs a certain function, and then needs to
I'm in the process of building a Windows Service that implements MEF. The idea
I'm in the process of refactoring some code which includes moving folders around, and
A Windows process created from an exe file has access to the command string
I'm in dilema whether to use windows service for my application or not, below
I have been quite comfortable with windows-services, I have been practicing since from last
I'm writing some dll (on windows in MSVC++2008) which provides some functionality as xmlrpc
I want to implement a Web Service that will allow users to store arbitrary
I need to implement inter-process communication system for processes (in machine-wide) in Win32 using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.