servicestack

ServiceStack: Handler for request not found?

瘦欲@ 提交于 2020-01-24 16:17:14
问题 I have three routes defined. First two work fine but the last one returns error in the subject. Routes.Add<FeeInstructionsList>("/policies/{clientPolicyId}/feeinstructions", "GET"); Routes.Add<FeeInstructionsEdit>("/policies/{clientPolicyId}/feeinstructions/{feetype}", "GET"); Routes.Add<List<FeeInstructionEditInfo>>("/policies{clientPolicyId}/feeinstructions", "POST"); When I had third route as just "/feeinstructions", it worked fine, but when I added route as above it does not work.

404 Not Found error when running ServiceStack on IIS8

a 夏天 提交于 2020-01-24 08:15:27
问题 My ServiceStack web service works fine in IIS Express (VS 2012) and when deployed to Windows Azure, but it does not work under IIS 8 on Window 8. I am getting 404 Not Found Error . My web.config has both sections defined for IIS Express and the web server. <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.web> <compilation debug="true" targetFramework="4.5"> <assemblies> <add assembly="System.Web.WebPages.Razor, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /

404 Not Found error when running ServiceStack on IIS8

强颜欢笑 提交于 2020-01-24 08:12:19
问题 My ServiceStack web service works fine in IIS Express (VS 2012) and when deployed to Windows Azure, but it does not work under IIS 8 on Window 8. I am getting 404 Not Found Error . My web.config has both sections defined for IIS Express and the web server. <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.web> <compilation debug="true" targetFramework="4.5"> <assemblies> <add assembly="System.Web.WebPages.Razor, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /

How can I get AngularJS working with the ServiceStack FallbackRoute attribute to support HTML5 pushstate Urls?

对着背影说爱祢 提交于 2020-01-22 20:40:27
问题 I am building a client/server solution, using an AngularJS Single Page App as the client component and a Self-Host ServiceStack RESTful API as the server component. A single Visual Studio Console Application Project holds HTML and JavaScript files for the AngularJS component, along with C# classes for bootstrapping the ServiceStack AppHost (I have devolved Interface and Service responsibilities to separate Visual Studio Projects). I have set all HTML and JavaScript files to have a 'Build

ServiceStack - is there an up-to date, complete documentation?

纵饮孤独 提交于 2020-01-22 11:24:15
问题 I'm trying to wrap my head around ServiceStack, and while it claims that it has really good documentation, it doesn't seem to be the case so far. Is there a documentation that actually says which interfaces/base classes to use, and what do they do ? Just.. have a bunch of quesitons, and can find very few answers.. A new API design shows an example of DTO implementing IReturn interface, and service inheriting from Service - but there's no explanation if this is the preferred way now, is it

How to get ServiceStack to serialize / deserialize an expando object with correct types

此生再无相见时 提交于 2020-01-21 08:53:07
问题 just trying to work out how well servicestack.text supports serializing expando objects to and from json. I know that an expando object implements an IDictionary. When I serialize to and from json I am having trouble getting the correct types in the deserialized IDictionary. As Json does not support types natively and servicestack has a setting called JsConfig.IncludeTypeInfo I expected it to include the type information in the serialized json to enable service stack to deserialize to the

How to get ServiceStack to serialize / deserialize an expando object with correct types

徘徊边缘 提交于 2020-01-21 08:50:09
问题 just trying to work out how well servicestack.text supports serializing expando objects to and from json. I know that an expando object implements an IDictionary. When I serialize to and from json I am having trouble getting the correct types in the deserialized IDictionary. As Json does not support types natively and servicestack has a setting called JsConfig.IncludeTypeInfo I expected it to include the type information in the serialized json to enable service stack to deserialize to the

利用 serviceStack 搭建web服务器

青春壹個敷衍的年華 提交于 2020-01-18 15:02:25
1,资料地址 参考资料 https://docs.servicestack.net/ https://docs.servicestack.net/create-your-first-webservice 2,参考资料上面安装ServiceStackVs 3,新建WebApplication1,并且可以直接运行 4,输入 5,我们来整理下关系: 该对象是serviceStack AppHostBase的衍生,并且进行初始化. 关联接口类和当前运行程序. 处理输入和输出的逻辑关系. HTTP端进行请求然后生成了 Hello实列,然后运行Any函数返回对象 6,发布项目 未完待续...................... 来源: https://www.cnblogs.com/frogkiller/p/12209010.html

How to set conditions/filters on references when using Load* methods

早过忘川 提交于 2020-01-17 08:14:04
问题 I have two tables: Customer and Orders. The customer has a reference to Orders like such: [Reference] public List<Order> Orders { get; set; } The Order class has an attribute Deleted . I'd like to load all Customers (or a subset), and include the Orders, but not the ones with Deleted=true. Can this be done with LoadSelect methods, or what is the recommended way? Something that would roughly equal the following SQL: select * from Customers C join Orders O on O.CustomerId = C.Id where O.Deleted

ServiceStack Exception: 'Handler for Request not found' when trying to insert Entry to SqlLite db

非 Y 不嫁゛ 提交于 2020-01-16 03:38:48
问题 I'm just learning how to use ServiceStack and I am getting an exception that I can't get past and not sure what is causing the exception. Here it is: Handler for Request not found: Request.ApplicationPath: / Request.CurrentExecutionFilePath: /entry/5/11-11-2012 Request.FilePath: /entry/5/11-11-2012 Request.HttpMethod: GET Request.MapPath('~'): C:\Projects\Tutorials\FirstServiceStackApp\FirstServiceStackApp\ Request.Path: /entry/5/11-11-2012 Request.PathInfo: Request.ResolvedPathInfo: /entry/5