Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/goenning/miniprofiler.sharpsaprfc
MiniProfiler Provider for SharpSapRfc
https://github.com/goenning/miniprofiler.sharpsaprfc
Last synced: 13 days ago
JSON representation
MiniProfiler Provider for SharpSapRfc
- Host: GitHub
- URL: https://github.com/goenning/miniprofiler.sharpsaprfc
- Owner: goenning
- License: mit
- Created: 2015-09-16T02:11:21.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-09-19T02:16:37.000Z (over 9 years ago)
- Last Synced: 2024-11-02T19:41:40.295Z (2 months ago)
- Language: C#
- Size: 344 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# MiniProfiler.SharpSapRfc
If you are building a Web Application, you should be using MiniProfiler. It's totally awesome!
This package is a custom provider for [MiniProfiler](http://miniprofiler.com) that automatically records timing of all calls made with [SharpSapRfc](https://github.com/goenning/SharpSapRfc).
## How to install
PM> Install-Package MiniProfiler.SharpSapRfc
## How to configure
`MiniProfiler.SharpSapRfc` provides a new SAP Connection class called `ProfiledSapRfConnection`. You have to wrap your real SAP Connection with this one and you are good to go. It's simple as that!
#### Without profiling
```C#
using (SapRfcConnection sap = new SoapSapRfcConnection("SAP"))
{
var result = conn.ExecuteFunction("Z_SSRT_GET_ALL_CUSTOMERS");
var customers = result.GetTable("t_customers");
}
```
#### With profiling
```C#
using (SapRfcConnection sap = new ProfiledSapRfcConnection(new SoapSapRfcConnection("SAP"), MiniProfiler.Current))
{
var result = conn.ExecuteFunction("Z_SSRT_GET_ALL_CUSTOMERS");
var customers = result.GetTable("t_customers");
}
```## What you should see
![Sample 1](https://raw.githubusercontent.com/goenning/MiniProfiler.SharpSapRfc/master/samples/profile-sap-1.PNG)
![Sample 2](https://raw.githubusercontent.com/goenning/MiniProfiler.SharpSapRfc/master/samples/profile-sap-2.PNG)