Reputation
Top tag
Next privilege 125 Rep.
Vote down
Badges
4
Newest
 Supporter
Impact
~133 people reached

  • 0 posts edited
  • 0 helpful flags
  • 1 vote cast
Jun
13
awarded  Supporter
Jun
4
comment Sync client-side data after service invocation in SPAs
Well, it could be as simple as the completion date must be displayed on the UI after a task is marked completed. Should the UI issue a new request to retrieve the task entity as a whole (which would now have the completedOn) or is it ok for such services to return data which is expected to be synchronized on the client?
Jun
4
asked Sync client-side data after service invocation in SPAs
Apr
18
comment Eventual consistency in Banking systems
You may find this interesting highscalability.com/blog/2013/5/1/…
Jan
21
revised Initialize physical resources in constructor
Added repository pattern idea.
Jan
21
revised Initialize physical resources in constructor
added 119 characters in body
Jan
21
comment Initialize physical resources in constructor
I'm sorry, but you are still misunderstanding the question. My point is, where the SQL table creation code shall go in the stated example. Is it fine to have that resource created when invoking the SQLTableMessageQueue constructor or not? If not, what would be more appropriate?
Jan
21
comment Initialize physical resources in constructor
@RobertHarvey I removed that as it was confusing since I chose the wrong words. I meant that for instance, if your class was a Timer you wouldn't start it right away when the constructor is called, but even that point is not very important for the question.
Jan
21
awarded  Editor
Jan
21
revised Initialize physical resources in constructor
deleted 63 characters in body
Jan
21
comment Initialize physical resources in constructor
I see that, but that's out of the question's scope and is irrelevant to my question. I haven't even mentionned anything about processing the queue and about the factory, if the goal is to abstract away the concrete class being used, you must make sure that the factory's interface doesn't leak specific concrete class's implementation details. Otherwise, client code will still have to be modified if the concrete class changes within the factory.
Jan
21
comment Initialize physical resources in constructor
@JTrana Well, I'll have to implement this in ColdFusion, a dynamic language where there's no real static members or static classes, but let's just say it's Java.
Jan
21
comment Initialize physical resources in constructor
Well, I do not see how your exemple is different than mine? The creation of the database table still would have to occur in the SQLTableMessageQueue constructor. Also, abstracting away the concrete queue class behind a factory isin't as simple as this. Different queue types might require different arguments to be constructed.
Jan
21
awarded  Student
Jan
21
asked Initialize physical resources in constructor
Mar
18
awarded  Promoter