Closed GoogleCodeExporter closed 9 years ago
You shouldn't need to copy an XMLTemplateParser. The design intent is to parse
the templates once into a template registry and share them among all threads
that need them. The TemplateRegistryPtr can be safely copied and used by
multiple threads.
With that in mind, I am considering addressing this issue by defining a private
copy construction and a private assignment operator for XMLTemplateParser to
disallow copying, but before I do so, I want to let you make a case for
supporting copying of the parser.
PS: I haven't checked to see if Xerces is thread-safe. Parsing templates in
multiple threads simultaneously could be iffy.
Dale
Original comment by dale.wil...@gmail.com
on 5 Oct 2010 at 3:01
Disabling copy construction sounds like a reasonable way to go, along with a
note in the docs about the dangers of multithreaded template parsing.
Original comment by da...@optionmetrics.com
on 5 Oct 2010 at 3:29
Done: R447
Original comment by dale.wil...@gmail.com
on 5 Oct 2010 at 6:51
Original issue reported on code.google.com by
da...@optionmetrics.com
on 5 Oct 2010 at 4:17