Options

Job Queue Setup error in NAV 2013 R2 with multi-tenancy

benrbenr Member Posts: 11
edited 2013-12-31 in NAV Three Tier
Hi All,

I am trying to get NAS services working in a NAV 2013 R2 multi-tenant environment. We have our application database separate from our business tenant databases. I would like to enable NAS services on a separate service instance that points to the same application database that all of the tenants use. Each tenant needs to have their own Job Queue.

I have enabled NAS services at the service instance level. I set a Services Default Company although some of the tenants have identically named companies. I picked a company that was unique among the tenants. I have set the Startup Codeunit to 450 and the Startup Argument to JOBQUEUE and the service starts successfully. I have mounted the tenants and set Enable NAS Services to True when mounting them.

I created a Job Queue called ALLJOBS within a tenant, but I can't get the queue to start. If I set it to start automatically, then it never appears to even try to start no matter how many times I restart the service. If I set the queue to start manually, then I do see this error in the Session Event table in the tenant: The Job Queue does not exist. Identification fields and values: Code=''

Any help would be greatly appreciated...

Thanks,
Ben

Comments

  • Options
    benrbenr Member Posts: 11
    I finally got this all working. There were a couple of separate issues. Starting the queue manually was failing due to some of our own code in the job queue dispatcher. Once that was resolved I still couldn't get a queue to start automatically though. I discovered through trial and error that in a multi-tenant environment the Services Default Company is not actually where you want to put the default company. Instead, you must specify a Default Company when you mount the tenant in addition to enabling NAS services for that tenant. You must do this even if there is only 1 company within that tenant. Also, the Windows account running the service must be a user within the tenant - even if you aren't using Windows Authentication for that service.

    Now that it's all set up though it works well - I can have 1 NAS service instance with all of the tenants mounted to it each with their own job queue, entries, and recurrences.

    Ben
Sign In or Register to comment.