ServiceStack 3.9.* to 4.*

RGPT

I am trying to change ServiceStack in my service from 3.9.43 to 4.0.9.

I had to change several things in my code and mostly followed the release notes for this.

There were a couple of weird things for me, like not finding anything to replace ServiceStack.WebHost.Endpoints or AppHostHttpListenerLongRunningBase but I could check those things after and was able to make my code to compile.

The problem is that when I run my code I get this exception in the very begining and it just kills the service:

Method 'ExecuteMessage' in type 'ServiceStack.Host.ServiceController' from assembly 'ServiceStack, Version=4.0.9.0, Culture=neutral, PublicKeyToken=null' does not have an implementation.

I get this when hitting the base:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ServiceStack;
using ServiceStack.Text;
//using ServiceStack.WebHost.Endpoints;
using ServiceStack.Web;


namespace ThisService {
    public class AppHost : AppHostHttpListenerPoolBase { //AppHostHttpListenerLongRunningBase {
        public AppHost(int wthreadMax)
            : base("This Service " + VcsInfo.ChangesetId, wthreadMax, typeof(ThisService).Assembly) {
        }
 ...

I am referencing in my project: ServiceStack (4.0.9.0); ServiceStack.Client; ServiceStack.Common; ServiceStack.Interfaces; ServiceStack.Text

I am sure I am doing something wrong changing to version 4.* and am lost with what is trying to call the Execute Message since I think removed everything from the previous version. Any suggestion to where I should be looking to?

By the way, this a simple service: get json -> math + stuff -> return json.

I want to find out if a bug I found the version 3.9.43 still happens in version 4.0.9 (can't find anything specific about that bug but I believe one fix there is related) to see if I should actually re-factor my code for this version.

mythz

Update in v4.10

This should now be resolved in ServiceStack v4.10 where now all NuGet packages specify a minimum version for all dependencies matching the current version. This will force NuGet to pull down the latest packages instead of the oldest matching ones.


NuGet seems to have the weird behavior that it will pull in the lowest dependencies when you install a package, so if you install the latest version of ServiceStack, e.g:

PM> Install-Package ServiceStack -Version 4.0.9

It will pull in the lowest matching dependenices, e.g:

<package id="ServiceStack.Client" version="4.0.3" targetFramework="net45" />
<package id="ServiceStack.Common" version="4.0.3" targetFramework="net45" />
<package id="ServiceStack.Interfaces" version="4.0.3" targetFramework="net45" />
<package id="ServiceStack.Text" version="4.0.3" targetFramework="net45" />

Which is an unexpected surprise. Unfortunately ServiceStack assumes that it's always working with the latest dependencies with the same version it was built with.

So after installing ServiceStack you will need to update all your packages which will bring them in-line with the latest versions, which you can easily do in the Updates tab in the NuGet UI, or in the NuGet Package Console Manager with:

PM> Update-Package

Manually remove any assembly redirects

Installing the previous v4.02 of ServiceStack (now removed) created new assembly redirects for ServiceStack.Interfaces in the Web.config which you should also manually remove if they exist. These now shouldn't be created for new projects.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

ServiceStack V3 vs V4

From Dev

Upgrading to serviceStack 4

From Dev

ServiceStack 4 new licensing

From Dev

ServiceStack JOIN 3 tables

From Dev

Razor dependency issues in ServiceStack 4

From Dev

ServiceStack 3.9.* to 4.*

From Dev

MVC4 + ServiceStack +....Glimpse?

From Dev

Why is the display resolution not exactly 16:9 or 4:3?

From Dev

1 2 3 4 7 8 9 p and backspace not working

From Dev

JWPlayer aspect ratio keeps 4:3 for my 16:9 video

From Dev

Using Guid Ids with ServiceStack 4 and MySQL

From Dev

Porting Razor RockStars to ServiceStack V4

From Dev

MVC4 and ServiceStack session in Redis

From Dev

ServiceStack 4 user registration doesn't work

From Dev

ServiceStack 4 user registration doesn't work

From Dev

MVC4 and ServiceStack session in Redis

From Dev

How to set defaultcontentype in ServiceStack version 4

From Dev

Applying a function on every 3 columns (cols: 1-3, 4-6, 7-9) in dataframe

From Dev

IdentityServer3 with ServiceStack and MVC Client

From Dev

Is there a build issue in the recent versions of ServiceStack 3?

From Dev

Add elements of an array as a[0],a[1]+a[2],a[3]+a[4]+a[5],a[6]+a[7]+a[8]+a[9]...and so on

From Dev

Retrieve 16:9 youtube thumbnails instead of the 4:3 black bordered ones?

From Dev

reshaping a 1x9 dataframe into a 4 x 3 without looping

From Dev

How to change a LibreOffice Impress presentation from 4:3 to 16:9 ratio?

From Dev

How can I crop a 16:9 video to 4:3, cutting off the edges?

From Dev

How to change a LibreOffice Impress presentation from 4:3 to 16:9 ratio?

From Dev

LibreOffice Impress: change screen format from 4:3 to 16:9 without stretching images?

From Dev

can't get 16:9 ratio on kvm, only 16:10 or 4:3

From Dev

an application required libstdc++ for GLIBCXX_3_4_9 library on RHEL 5 64bit system

Related Related

  1. 1

    ServiceStack V3 vs V4

  2. 2

    Upgrading to serviceStack 4

  3. 3

    ServiceStack 4 new licensing

  4. 4

    ServiceStack JOIN 3 tables

  5. 5

    Razor dependency issues in ServiceStack 4

  6. 6

    ServiceStack 3.9.* to 4.*

  7. 7

    MVC4 + ServiceStack +....Glimpse?

  8. 8

    Why is the display resolution not exactly 16:9 or 4:3?

  9. 9

    1 2 3 4 7 8 9 p and backspace not working

  10. 10

    JWPlayer aspect ratio keeps 4:3 for my 16:9 video

  11. 11

    Using Guid Ids with ServiceStack 4 and MySQL

  12. 12

    Porting Razor RockStars to ServiceStack V4

  13. 13

    MVC4 and ServiceStack session in Redis

  14. 14

    ServiceStack 4 user registration doesn't work

  15. 15

    ServiceStack 4 user registration doesn't work

  16. 16

    MVC4 and ServiceStack session in Redis

  17. 17

    How to set defaultcontentype in ServiceStack version 4

  18. 18

    Applying a function on every 3 columns (cols: 1-3, 4-6, 7-9) in dataframe

  19. 19

    IdentityServer3 with ServiceStack and MVC Client

  20. 20

    Is there a build issue in the recent versions of ServiceStack 3?

  21. 21

    Add elements of an array as a[0],a[1]+a[2],a[3]+a[4]+a[5],a[6]+a[7]+a[8]+a[9]...and so on

  22. 22

    Retrieve 16:9 youtube thumbnails instead of the 4:3 black bordered ones?

  23. 23

    reshaping a 1x9 dataframe into a 4 x 3 without looping

  24. 24

    How to change a LibreOffice Impress presentation from 4:3 to 16:9 ratio?

  25. 25

    How can I crop a 16:9 video to 4:3, cutting off the edges?

  26. 26

    How to change a LibreOffice Impress presentation from 4:3 to 16:9 ratio?

  27. 27

    LibreOffice Impress: change screen format from 4:3 to 16:9 without stretching images?

  28. 28

    can't get 16:9 ratio on kvm, only 16:10 or 4:3

  29. 29

    an application required libstdc++ for GLIBCXX_3_4_9 library on RHEL 5 64bit system

HotTag

Archive