您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

AppDbContext.cs 581 B

1234567891011121314
  1. using Microsoft.EntityFrameworkCore;
  2. namespace Sample.Kafka.SqlServer
  3. {
  4. public class AppDbContext : DbContext
  5. {
  6. protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
  7. {
  8. //optionsBuilder.UseSqlServer("Server=192.168.2.206;Initial Catalog=Sample.Kafka.SqlServer;User Id=cmswuliu;Password=h7xY81agBn*Veiu3;MultipleActiveResultSets=True");
  9. optionsBuilder.UseSqlServer("Server=DESKTOP-M9R8T31;Initial Catalog=Sample.Kafka.SqlServer;User Id=sa;Password=P@ssw0rd;MultipleActiveResultSets=True");
  10. }
  11. }
  12. }