diff --git a/src/DotNetCore.CAP.EntityFrameworkCore/ConsistencyDbContext.cs b/src/DotNetCore.CAP.EntityFrameworkCore/ConsistencyDbContext.cs
index bf05568..34a4526 100644
--- a/src/DotNetCore.CAP.EntityFrameworkCore/ConsistencyDbContext.cs
+++ b/src/DotNetCore.CAP.EntityFrameworkCore/ConsistencyDbContext.cs
@@ -24,7 +24,9 @@ namespace DotNetCore.CAP.EntityFrameworkCore
///
/// Gets or sets the of Messages.
///
- public DbSet Messages { get; set; }
+ public DbSet CapSentMessages { get; set; }
+
+ public DbSet CapReceivedMessages { get; set; }
///
/// Configures the schema for the identity framework.
@@ -34,10 +36,15 @@ namespace DotNetCore.CAP.EntityFrameworkCore
///
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
- modelBuilder.Entity(b =>
+ modelBuilder.Entity(b =>
{
b.HasKey(m => m.Id);
- b.ToTable("ConsistencyMessages");
+ b.Property(p => p.StateName).HasMaxLength(50);
+ });
+
+ modelBuilder.Entity(b =>
+ {
+ b.Property(p => p.StateName).HasMaxLength(50);
});
}
}
diff --git a/src/DotNetCore.CAP/CAP.Options.cs b/src/DotNetCore.CAP/CAP.Options.cs
index e0c5801..51d293f 100644
--- a/src/DotNetCore.CAP/CAP.Options.cs
+++ b/src/DotNetCore.CAP/CAP.Options.cs
@@ -7,12 +7,7 @@ namespace DotNetCore.CAP.Infrastructure
///
public class CapOptions
{
- ///
- /// kafka or rabbitMQ brokers connection string.
- ///
- public string BrokerUrlList { get; set; } = "localhost:9092";
-
- ///
+ ///
/// Corn expression for configuring retry cron job. Default is 1 min.
///
public string CronExp { get; set; } = Cron.Minutely();
diff --git a/src/DotNetCore.CAP/IConsumerClientFactory.cs b/src/DotNetCore.CAP/IConsumerClientFactory.cs
index e49e3c7..6c53fd7 100644
--- a/src/DotNetCore.CAP/IConsumerClientFactory.cs
+++ b/src/DotNetCore.CAP/IConsumerClientFactory.cs
@@ -9,8 +9,6 @@
/// Create a new instance of .
///
///
- ///
- ///
- IConsumerClient Create(string groupId, string clientHostAddress);
+ IConsumerClient Create(string groupId);
}
}
\ No newline at end of file
diff --git a/src/DotNetCore.CAP/IConsumerHandler.Default.cs b/src/DotNetCore.CAP/IConsumerHandler.Default.cs
index a48b88d..74d01ba 100644
--- a/src/DotNetCore.CAP/IConsumerHandler.Default.cs
+++ b/src/DotNetCore.CAP/IConsumerHandler.Default.cs
@@ -66,7 +66,7 @@ namespace DotNetCore.CAP
{
Task.Factory.StartNew(() =>
{
- using (var client = _consumerClientFactory.Create(matchGroup.Key, _options.BrokerUrlList))
+ using (var client = _consumerClientFactory.Create(matchGroup.Key))
{
client.MessageReceieved += OnMessageReceieved;
diff --git a/src/DotNetCore.CAP/Infrastructure/CapMessage.cs b/src/DotNetCore.CAP/Infrastructure/CapMessage.cs
index ce310ff..c41c29a 100644
--- a/src/DotNetCore.CAP/Infrastructure/CapMessage.cs
+++ b/src/DotNetCore.CAP/Infrastructure/CapMessage.cs
@@ -3,7 +3,7 @@
namespace DotNetCore.CAP.Infrastructure
{
///
- /// The default implementation of which uses a string as a primary key.
+ /// cap messages store model.
///
public abstract class CapMessage : MessageBase
{
@@ -36,6 +36,9 @@ namespace DotNetCore.CAP.Infrastructure
public string StateName { get; set; }
}
+ ///
+ /// The message state name.
+ ///
public struct StateName
{
public const string Enqueued = nameof(Enqueued);