Skip to content

Commit

Permalink
Zebus.Persistence: Rename Persistence.CQL assembly to Persistence.Cas…
Browse files Browse the repository at this point in the history
…sandra for consistent naming between Directory and Persistence
  • Loading branch information
oktal committed Jan 4, 2022
1 parent d8b963d commit 34626ab
Show file tree
Hide file tree
Showing 37 changed files with 66 additions and 66 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<PackageId>Zebus.Persistence.CQL.Testing</PackageId>
<PackageId>Zebus.Persistence.Cassandra.Testing</PackageId>
<Version>$(ZebusPersistenceVersion)</Version>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\Abc.Zebus.Persistence.CQL\Abc.Zebus.Persistence.CQL.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.Cassandra\Abc.Zebus.Persistence.Cassandra.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.Messages\Abc.Zebus.Persistence.Messages.csproj" PrivateAssets="All" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using System;
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Moq;

namespace Abc.Zebus.Persistence.CQL.Testing
namespace Abc.Zebus.Persistence.Cassandra.Testing
{
// TODO: This entire namespace belongs in Zebus.Testing but it would require the creation of a Zebus.Shared, and we are not ready for that just yet
public class CassandraConfigurationMock<TConfig> : Mock<TConfig> where TConfig : class, ICassandraConfiguration
Expand All @@ -15,4 +15,4 @@ public CassandraConfigurationMock(string host, string keySpace, string localData
As<ICassandraConfiguration>().SetupGet(config => config.LocalDataCenter).Returns(localDataCenter);
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@
<PropertyGroup>
<TargetFrameworks>net48;net5.0</TargetFrameworks>
<Version>$(ZebusPersistenceVersion)</Version>
<RootNamespace>Abc.Zebus.Persistence.Cassandra.Tests</RootNamespace>
</PropertyGroup>

<Import Project="..\Abc.Zebus.Tests.props" />

<ItemGroup>
<ProjectReference Include="..\Abc.Zebus.Persistence.CQL.Testing\Abc.Zebus.Persistence.CQL.Testing.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.Cassandra.Testing\Abc.Zebus.Persistence.Cassandra.Testing.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.Messages\Abc.Zebus.Persistence.Messages.csproj" PrivateAssets="All" />
<ProjectReference Include="..\Abc.Zebus.Testing\Abc.Zebus.Testing.csproj" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using Abc.Zebus.Testing.Extensions;
using NUnit.Framework;

namespace Abc.Zebus.Persistence.CQL.Tests
namespace Abc.Zebus.Persistence.Cassandra.Tests
{
public class BucketIdHelperTests
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
using System.Collections.Generic;
using System.Diagnostics;
using System.Reflection;
using Abc.Zebus.Persistence.CQL.Testing;
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Cassandra.Testing;
using Cassandra;
using Cassandra.Mapping;
using Moq;
using NUnit.Framework;

namespace Abc.Zebus.Persistence.CQL.Tests.Cql
namespace Abc.Zebus.Persistence.Cassandra.Tests.Cql
{
// TODO: This entire namespace belongs in Zebus.Testing but it would require the creation of a Zebus.Shared, and we are not ready for that just yet
public abstract class CqlTestFixture<TDataContext, TConfig>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
using System;
using System.IO;
using System.Linq;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.CQL.Tests.Cql;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Cassandra.Tests.Cql;
using Abc.Zebus.Persistence.Messages;
using Abc.Zebus.Persistence.Storage;
using Abc.Zebus.Serialization;
Expand All @@ -12,7 +12,7 @@
using Abc.Zebus.Transport;
using NUnit.Framework;

namespace Abc.Zebus.Persistence.CQL.Tests
namespace Abc.Zebus.Persistence.Cassandra.Tests
{
public class CqlMessageReaderTests : CqlTestFixture<PersistenceCqlDataContext, ICqlPersistenceConfiguration>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.CQL.Tests.Cql;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Cassandra.Tests.Cql;
using Abc.Zebus.Persistence.Matching;
using Abc.Zebus.Persistence.Messages;
using Abc.Zebus.Persistence.Reporter;
Expand All @@ -17,7 +17,7 @@
using NUnit.Framework;
using ProtoBuf;

namespace Abc.Zebus.Persistence.CQL.Tests
namespace Abc.Zebus.Persistence.Cassandra.Tests
{
public class CqlStorageTests : CqlTestFixture<PersistenceCqlDataContext, ICqlPersistenceConfiguration>
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using System.Security.Cryptography;

namespace Abc.Zebus.Persistence.CQL.Tests
namespace Abc.Zebus.Persistence.Cassandra.Tests
{
public static class MessageIdV2
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.CQL.PeriodicAction;
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.CQL.Tests.Cql;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Cassandra.PeriodicAction;
using Abc.Zebus.Persistence.Cassandra.Tests.Cql;
using Abc.Zebus.Testing;
using Abc.Zebus.Testing.Extensions;
using Abc.Zebus.Util;
using Moq;
using NUnit.Framework;

namespace Abc.Zebus.Persistence.CQL.Tests
namespace Abc.Zebus.Persistence.Cassandra.Tests
{
public class OldestNonAckedMessageUpdaterPeriodicActionTests : CqlTestFixture<PersistenceCqlDataContext, ICqlPersistenceConfiguration>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<PackageId>Zebus.Persistence.CQL</PackageId>
<PackageId>Zebus.Persistence.Cassandra</PackageId>
<Version>$(ZebusPersistenceVersion)</Version>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using System.Linq;
using Cassandra;

namespace Abc.Zebus.Persistence.CQL.Util
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public class CassandraCqlSessionManager : IDisposable
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using Cassandra.Data.Linq;
using TableAttribute = Cassandra.Mapping.Attributes.TableAttribute;

namespace Abc.Zebus.Persistence.CQL.Util
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public abstract class CqlDataContext<TConfig> where TConfig : ICassandraConfiguration
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Messages;
using Abc.Zebus.Persistence.Storage;
using Cassandra;
using Cassandra.Data.Linq;
using log4net;

namespace Abc.Zebus.Persistence.CQL.Storage
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public class CqlMessageReader : IMessageReader
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Cassandra.Util;
using Abc.Zebus.Persistence.Matching;
using Abc.Zebus.Persistence.Messages;
using Abc.Zebus.Persistence.Reporter;
Expand All @@ -15,7 +15,7 @@
using Cassandra.Data.Linq;
using log4net;

namespace Abc.Zebus.Persistence.CQL.Storage
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public class CqlStorage : ICqlStorage, IDisposable
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;

namespace Abc.Zebus.Persistence.CQL.Util
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public interface ICassandraConfiguration
{
Expand All @@ -26,4 +26,4 @@ public interface ICassandraConfiguration
/// </summary>
string LocalDataCenter { get; }
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using System.Threading.Tasks;
using Abc.Zebus.Persistence.Storage;

namespace Abc.Zebus.Persistence.CQL.Storage
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public interface ICqlStorage : IStorage
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using Abc.Zebus.Util;

namespace Abc.Zebus.Persistence.CQL.Storage
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public class PeerState
{
Expand Down Expand Up @@ -31,7 +31,7 @@ public PeerState(PeerId peerId, int nonAckMessageCount = 0, long oldestNonAckedM

/// <summary>
/// Provides a timestamp that is lower than or equal to the timestamp of the last unacked message.
///
///
/// The goal of this value is to make replay efficient by using a recent starting point, thus reducing
/// the number of messages that the replay will scan.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Abc.Zebus.Persistence.CQL.Data;
using Abc.Zebus.Persistence.Cassandra.Data;
using Abc.Zebus.Persistence.Messages;
using Abc.Zebus.Persistence.Util;
using Abc.Zebus.Util;
using Cassandra;
using Cassandra.Data.Linq;
using log4net;

namespace Abc.Zebus.Persistence.CQL.Storage
namespace Abc.Zebus.Persistence.Cassandra.Cql
{
public class PeerStateRepository
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Cassandra.Mapping.Attributes;

namespace Abc.Zebus.Persistence.CQL.Data
namespace Abc.Zebus.Persistence.Cassandra.Data
{
[Table("PeerState", CaseSensitive = true)]
public class CassandraPeerState
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Cassandra.Data.Linq;

namespace Abc.Zebus.Persistence.CQL.Data
namespace Abc.Zebus.Persistence.Cassandra.Data
{
public class PersistenceCqlDataContext : CqlDataContext<ICqlPersistenceConfiguration>
{
Expand All @@ -12,4 +12,4 @@ public PersistenceCqlDataContext(CassandraCqlSessionManager sessionManager, ICql
public Table<PersistentMessage> PersistentMessages => new Table<PersistentMessage>(Session);
public Table<CassandraPeerState> PeerStates => new Table<CassandraPeerState>(Session);
}
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using Cassandra.Mapping.Attributes;

namespace Abc.Zebus.Persistence.CQL.Data
namespace Abc.Zebus.Persistence.Cassandra.Data
{
[Table("PersistentMessage", CaseSensitive = true)]
public class PersistentMessage
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra.Cql;

namespace Abc.Zebus.Persistence.CQL
namespace Abc.Zebus.Persistence.Cassandra
{
public interface ICqlPersistenceConfiguration : ICassandraConfiguration
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
using System.Linq;
using System.Threading.Tasks;
using Abc.Zebus.Hosting;
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Storage;
using Abc.Zebus.Util;
using Abc.Zebus.Util.Extensions;

namespace Abc.Zebus.Persistence.CQL.PeriodicAction
namespace Abc.Zebus.Persistence.Cassandra.PeriodicAction
{
public class OldestNonAckedMessageUpdaterPeriodicAction : PeriodicActionHostInitializer
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

[assembly: InternalsVisibleTo("Abc.Zebus.Integration")]
[assembly: InternalsVisibleTo("Abc.Zebus.PersistenceService.Tests")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.CQL.Testing")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.CQL.Tests")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.Cassandra.Testing")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.Cassandra.Tests")]

[module: SkipLocalsInit]
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System;

namespace Abc.Zebus.Persistence.CQL.Util
namespace Abc.Zebus.Persistence.Cassandra.Util
{
public static class MessageIdExtensions
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\Abc.Zebus.Persistence.CQL\Abc.Zebus.Persistence.CQL.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.Cassandra\Abc.Zebus.Persistence.Cassandra.csproj" />
<ProjectReference Include="..\Abc.Zebus.Persistence.RocksDb\Abc.Zebus.Persistence.RocksDb.csproj" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System;
using Abc.Zebus.Persistence.CQL;
using Abc.Zebus.Persistence.Cassandra;
using FluentDate;

namespace Abc.Zebus.Persistence.Runner
Expand Down
7 changes: 3 additions & 4 deletions src/Abc.Zebus.Persistence.Runner/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@
using Abc.Zebus.Directory;
using Abc.Zebus.Dispatch;
using Abc.Zebus.Monitoring;
using Abc.Zebus.Persistence.CQL;
using Abc.Zebus.Persistence.CQL.PeriodicAction;
using Abc.Zebus.Persistence.CQL.Storage;
using Abc.Zebus.Persistence.CQL.Util;
using Abc.Zebus.Persistence.Cassandra;
using Abc.Zebus.Persistence.Cassandra.Cql;
using Abc.Zebus.Persistence.Cassandra.PeriodicAction;
using Abc.Zebus.Persistence.Initialization;
using Abc.Zebus.Persistence.Matching;
using Abc.Zebus.Persistence.Reporter;
Expand Down
4 changes: 2 additions & 2 deletions src/Abc.Zebus.Persistence/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
[assembly: Guid("acc56b25-51e9-4864-8913-d36ba6d8ffab")]

[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.Tests")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.CQL")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.CQL.Tests")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.Cassandra")]
[assembly: InternalsVisibleTo("Abc.Zebus.Persistence.Cassandra.Tests")]

[module: SkipLocalsInit]
Loading

0 comments on commit 34626ab

Please sign in to comment.