DefineConfig.cs 752 B

12345678910111213141516171819202122232425262728
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace MqttMsgServer.Service
  7. {
  8. public class DefineConfig
  9. {
  10. public const int TcpPort = 1884;
  11. public const int WsPort = 8083;
  12. //如果不需要密码,请将username和pwd赋值为null
  13. public static string UserName = "admin";
  14. public static string Pwd = "admin123456";
  15. public const int ClientStateUsing = 1;
  16. public const int ClientStateClosed = 0;
  17. }
  18. public class CacheName
  19. {
  20. public const string TopicMsgCachePrefix = "Tm-";
  21. public const string ClientMsgCachePrefix = "CM-";
  22. public const string ClientCachePrefix = "C-";
  23. }
  24. }