public static void CheckRequestContent(Request4Pipe request)
 {
     if (request == null || request.ClientContent == null || string.IsNullOrEmpty(request.ClientContent.Content))
     {
         throw new InvalidOperationException("无效请求");
     }
 }
Ejemplo n.º 2
0
 public static void AnalyseHead(Request4Pipe request)
 {
     if (request.Head != null)
     {
         if (request.Head.ToString().IndexOf("SOA") != -1)
         {
             //对消息进行SOA处理
         }
     }
 }
 public static void AddRequestHead(Request4Pipe request)
 {
     if (request.Head != null)
     {
         request.Head.Append("Request Source:SOA Client");
     }
     else
     {
         throw new NullReferenceException("Request.Head is Null");
     }
 }
        public OperationLogicPipelineObject BuildOperationPipeline(Request4Pipe request)
        {
            var pipeline = new OperationLogicPipelineObject();

            pipeline.Add(requestObj => {
                //对request进行处理,记录dotnet客户端请求Log
            });
            pipeline.Add(requestObj => {
                //对request进行处理,执行dotnet客户端请求
            });
            return(pipeline);
        }
Ejemplo n.º 5
0
        public OperationLogicPipelineObject BuildOperationPipeline(Request4Pipe request)
        {
            var pipeline = new OperationLogicPipelineObject();

            pipeline.Add(requestObj => {
                //对request进行操作,记录App请求Log的方法
            });

            pipeline.Add(requestObj => {
                //对request进行操作,执行App请求的方法
            });

            return(pipeline);
        }
 public void RunPipeline(Request4Pipe request)
 {
     modules(request);
 }
 internal static void Reduce(Request4Pipe request)
 {
     throw new NotImplementedException();
 }
Ejemplo n.º 8
0
 public static void Route(Request4Pipe request)
 {
     //对消息进行路由
 }
Ejemplo n.º 9
0
 public static void RestoreTransfer(Request4Pipe request)
 {
     request.ClientContent.Content = TransferRequestForRest.RestoreTransfer(request.ClientContent.Content);
 }
Ejemplo n.º 10
0
 public static void RestoreReduce(Request4Pipe request)
 {
     ReduceRequestBody.Restore(request);
 }
 public static void TransferRequestFormat(Request4Pipe request)
 {
     request.ClientContent.Content = TransferRequestForRest.Transfer(request.ClientContent.Content);
 }