Created
December 6, 2013 12:44
-
-
Save dlidstrom/7823173 to your computer and use it in GitHub Desktop.
Create projections from C#.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private static void Main(string[] args) | |
| { | |
| var projectionsManager = new ProjectionsManager(new ConsoleLogger(), new IPEndPoint(IPAddress.Loopback, 1113)); | |
| const string projStr = | |
| "fromCategory('12-testentity').foreachStream().whenAny(function(s, e) { linkTo('test-12', e) })"; | |
| var credentials = new UserCredentials("admin", "changeit"); | |
| projectionsManager.CreateContinuous("$test-12", projStr, credentials); | |
| projectionsManager.Enable("$test-12", credentials); | |
| Console.ReadLine(); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment