Call to GetService<OrderTracking> Failing

Discussions concerning general integration topics.

Moderator: Phil Barton

roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Call to GetService<OrderTracking> Failing

Post by roteague »

I've got a strange one here that I haven't been able to resolve. I've got a code module, where the following line:

Code: Select all

ot = server.GetService<OrderTracking>();
is failing. It throws a null exception (Object reference not set to an instance of an object) whenever I call it. What could cause this call to fail?

I've validated that SelectServer object is not null and contains the correct uri to connect to. Likewise, the User Name and Password are also correct. The code works in the development environment (Windows XP), but fails on the server (Windows 2003 Server).

I suspect it may be related to a security issue, since I get errors trying to write to the event log. The module is part of a WCF service (I'm building an Order Notification Handler), running under IIS.
Robert
roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Re: Call to GetService<OrderTracking> Failing

Post by roteague »

Here is the Stack Trace (from the Event Log):

Code: Select all

SoftProOrderActivity::Execute - Looking up Order #: 09001003 failed. Error: Object reference not set to an instance of an object.. Stack Trace:    at SoftPro.Select.Client.SelectServer.InitLegacySupport()
   at SoftPro.Select.Client.SelectServer.Authenticate()
   at SoftPro.Select.Client.SelectServer.EnsureAuthenticated()
   at SoftPro.Select.Client.SelectServer.GetService[T]()
   at TG.SoftPro.LoadOrderActivity.SoftProOrderActivity.Execute(ActivityExecutionContext executionContext) in C:\Projects\SoftPro\Code\TG.SoftPro.EventNotification\TG.SoftPro.LoadOrderActivity\SoftProOrderActivity.cs:line 155
Robert
Mark McKenna

Re: Call to GetService<OrderTracking> Failing

Post by Mark McKenna »

What version of Select are you running?
roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Re: Call to GetService<OrderTracking> Failing

Post by roteague »

Sorry, it's version 2.3.30216.50. I keep forgetting you guys are working multiple versions.
Robert
Mark McKenna

Re: Call to GetService<OrderTracking> Failing

Post by Mark McKenna »

Could you provide a listing of the Select services that are installed on that Select Server ?

sps services /s:yourserveraddress
roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Re: Call to GetService<OrderTracking> Failing

Post by roteague »

Mark McKenna wrote:Could you provide a listing of the Select services that are installed on that Select Server ?

sps services /s:yourserveraddress
Service : OrderTracking
-------------------------------------------------------------------------------
Guid : c4c55687-a771-42f4-8feb-3ec0640f3afc
Endpoints : {Count = 2}
ID Name Address
------------------------------------ -------------- ------------
688d586d-63c2-410b-af4d-598d7b523a8d ScreenRegistry http://softp
69952518-49d0-4c59-8b2d-b1341720bcfa Lookups http://softp
Events : {Count = 5}
ID Name
------------------------------------ ---------------------------
c4edbd4f-f11d-4c48-be08-8c105181f5c9 OrderChanged
cec82641-2d23-4072-bd81-4ac126ba2567 OrderClosed
c3088264-4f52-4256-9132-ccb0b9ff0906 TasksChanged
cacdf1c3-d4be-4471-b345-1f7a81a6fa87 CommitmentChanged
dc43850f-04c4-4ebc-bc23-7d863462820d InvoiceChanged
Attributes : {Count = 0}

Service : Accounting
-------------------------------------------------------------------------------
Guid : 6b0c588d-9f10-485f-963e-443594479ac0
Endpoints : {Count = 0}
Events : {Count = 1}
ID Name
------------------------------------ ---------------------------
0d670a83-cc37-4d7e-b507-186f2ecf23f4 Disbursement
Attributes : {Count = 0}

Service : Integration
-------------------------------------------------------------------------------
Guid : 3dd607a1-3389-4455-8752-96031a784748
Endpoints : {Count = 6}
ID Name Address
------------------------------------ ----------------- ---------
c1c59a83-2f73-427e-96d8-0151c5510302 ServerStatus http://so
70d05be4-9205-454f-b8e4-26e5d148b55c Authorization http://so
296170c7-93b0-429e-aa53-78cb2677eca1 EventNotification http://so
c1270162-acb0-4b05-883a-ad5d6eafb297 Authentication http://so
3bf32ae8-7d7c-477d-809f-bb8bb29adbf4 Licensing http://so
ced8102e-502a-4af3-be7c-ff70bcd963d6 Registration http://so
Events : {Count = 0}
Attributes : {Count = 8}
Name Value
---------------------------------- -----------------------------
BusinessObjectCollectionAssemblies SoftPro.BusinessObjects.Core
DocAndReportDefsPath Data\DocAndReportDefs
ManagerAssemblies SoftPro.SPAdminManagers.Core;
ManagerControlAssemblies SoftPro.Administration.Contro
ManagerObjectMapsPath Data\ManagerObjectMaps
RuleInstanceDefsPath Data\RuleInstanceDefs
StorageSystem SoftPro.Documents.Storage.Fil
DbConnectionString Data Source=SoftPro;Initial C
Robert
Mark McKenna

Re: Call to GetService<OrderTracking> Failing

Post by Mark McKenna »

Is there anything in the Event Log immediately prior to the Error you've reported (perhaps a warning or another error)? Or is the one error all that you see?
roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Re: Call to GetService<OrderTracking> Failing

Post by roteague »

Mark McKenna wrote:Is there anything in the Event Log immediately prior to the Error you've reported (perhaps a warning or another error)? Or is the one error all that you see?
Mark,

There are no errors either before or after. The only event log entries are: "Select Server started successfully." before the call and "Select Server stopped successfully." just after the call. Both are Information level entries.
Robert
John Morris
Posts: 411
Joined: Thu Sep 11, 2008 11:35 am
Location: Raleigh, NC, USA
Contact:

Re: Call to GetService<OrderTracking> Failing

Post by John Morris »

In your 2003 environment, where are you placing your custom developed code? Are you copying our dlls into your folder, or are you placing you dlls into the SoftPro installation folder?
John Morris
Sr. Software Architect
SoftPro
roteague
Posts: 292
Joined: Thu Sep 25, 2008 4:49 pm
Location: Honolulu, Hawaii

Re: Call to GetService<OrderTracking> Failing

Post by roteague »

John Morris wrote:In your 2003 environment, where are you placing your custom developed code? Are you copying our dlls into your folder, or are you placing you dlls into the SoftPro installation folder?
We don't have the SoftPro client installed on this machine, so I've taken to copying all the dll's from a client install to the server. The server install is under the InetPub directory since it is part of a WCF service.
Robert
Post Reply