Coder Social home page Coder Social logo

yusufyilmazfr / asmin Goto Github PK

View Code? Open in Web Editor NEW
93.0 10.0 16.0 20.28 MB

Asmin is .NET CORE project infrastructure, to get a quick start on the project.

C# 20.28% HTML 8.76% CSS 26.13% JavaScript 44.84%
n-layer-architecture repository-pattern unit-of-work aspect-oriented-programming dependency-injection asp-net-core interceptor entity-framework-core

asmin's Introduction

Welcome to Asmin, .NET CORE Project Infrastructure👋

Asmin Logo


Asmin provides you with a basic infrastructure when starting your .NET CORE projects. In this way, you can develop your projects faster and focus on your work.

Usage and Install

If you want to get information about the project structure and code blocks, you can look at the Documentation.


Monolithic Architecture

Monolithic Architecture


When projects start, we spend a great deal of time with the infrastructure. These; Such as

  • Exception Handling
  • Log Operations
  • Transaction Management
  • Cache Operations
  • Authorization Management
  • Performance Counters

Asmin provides these to us by benefiting from Aspect Oriented Programming, thus providing a clean code and a readable environment.

🤩 Clean and Readable

asmin manager class



👌 In addition to the features provided as infrastructure, you do not stop with time-consuming things such as home pages and designs, as it comes with a ready admin panel.

Screenshots

Asmin Login Page
Asmin Dashboard
Asmin User List



Author

👤 Yusuf

Show your support

If you like or are using this project to learn or start your solution, please give it a ⭐️. Thanks!


This README was generated with ❤️ by readme-md-generator

asmin's People

Contributors

atakancskndr avatar yusufyilmazfr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

asmin's Issues

IInterceptor does not work when invocation method is async

I created new PR: #6

I seperated AOP modules from Asmin.Core to Asmin.Packages.AOP. It provided modular and independent app. It works but we have a problem. IInterceptor does not work when invocation method is async.

We have code in this name space Asmin.Packages.AOP/Interceptor/MethodInterceptorBase.cs

namespace Asmin.Packages.AOP.Interceptor
{
    public abstract class MethodInterceptorBase : Attribute, IInterceptor
    {
        /// <summary>
        /// Working priority
        /// </summary>
        public int Priority { get; set; }
        /// <summary>
        /// Intercept defined method
        /// </summary>
        /// <param name="invocation"></param>
        public abstract void Intercept(IInvocation invocation);
    }
}
namespace Asmin.Packages.AOP.Interceptor
{
    /// <summary>
    /// MethodInterceptor provides writing aspect.
    /// </summary>
    public class MethodInterceptor : MethodInterceptorBase
    {
        /// <summary>
        /// OnBefore works before method working
        /// </summary>
        /// <param name="invocation"></param>
        public virtual void OnBefore(IInvocation invocation) { }

        /// <summary>
        /// OnAfter works last
        /// </summary>
        /// <param name="invocation"></param>
        public virtual void OnAfter(IInvocation invocation) { }

        /// <summary>
        /// OnSuccess works when method done successfully
        /// </summary>
        /// <param name="invocation"></param>
        public virtual void OnSuccess(IInvocation invocation) { }

        /// <summary>
        /// OnException works when method throws exception
        /// </summary>
        /// <param name="invocation"></param>
        /// <param name="exception">Throwed exception</param>
        public virtual void OnException(IInvocation invocation, Exception exception) { }

        /// <summary>
        /// Intercept works while method is working
        /// </summary>
        /// <param name="invocation"></param>
        public override void Intercept(IInvocation invocation)
        {
            bool isSuccess = true;

            OnBefore(invocation);

            try
            {
                invocation.Proceed();
            }
            catch (Exception e)
            {
                isSuccess = false;

                OnException(invocation, e);
            }
            finally
            {
                if (isSuccess)
                {
                    OnSuccess(invocation);
                }

                OnAfter(invocation);
            }
        }
    }
}

I need async operation. I use Castle.Core package for intercepting.

There is documentation for async operation: https://github.com/castleproject/Core/blob/master/docs/dynamicproxy-async-interception.md

I will check it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.