cppcms-users Mailing List for CppCMS C++ Web Framework (Page 77)
Brought to you by:
artyom-beilis
You can subscribe to this list here.
2009 |
Jan
|
Feb
(22) |
Mar
|
Apr
(3) |
May
|
Jun
(4) |
Jul
|
Aug
|
Sep
|
Oct
(15) |
Nov
(16) |
Dec
(13) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2010 |
Jan
(4) |
Feb
|
Mar
(8) |
Apr
(8) |
May
(8) |
Jun
(36) |
Jul
(63) |
Aug
(126) |
Sep
(47) |
Oct
(66) |
Nov
(46) |
Dec
(42) |
2011 |
Jan
(87) |
Feb
(24) |
Mar
(54) |
Apr
(21) |
May
(22) |
Jun
(18) |
Jul
(22) |
Aug
(101) |
Sep
(57) |
Oct
(33) |
Nov
(34) |
Dec
(66) |
2012 |
Jan
(64) |
Feb
(76) |
Mar
(73) |
Apr
(105) |
May
(93) |
Jun
(83) |
Jul
(84) |
Aug
(88) |
Sep
(57) |
Oct
(59) |
Nov
(35) |
Dec
(49) |
2013 |
Jan
(67) |
Feb
(17) |
Mar
(49) |
Apr
(64) |
May
(87) |
Jun
(64) |
Jul
(93) |
Aug
(23) |
Sep
(15) |
Oct
(16) |
Nov
(62) |
Dec
(73) |
2014 |
Jan
(5) |
Feb
(23) |
Mar
(21) |
Apr
(11) |
May
(1) |
Jun
(19) |
Jul
(27) |
Aug
(16) |
Sep
(5) |
Oct
(37) |
Nov
(12) |
Dec
(9) |
2015 |
Jan
(7) |
Feb
(7) |
Mar
(44) |
Apr
(28) |
May
(5) |
Jun
(12) |
Jul
(8) |
Aug
|
Sep
(39) |
Oct
(34) |
Nov
(30) |
Dec
(34) |
2016 |
Jan
(66) |
Feb
(23) |
Mar
(33) |
Apr
(15) |
May
(11) |
Jun
(15) |
Jul
(26) |
Aug
(4) |
Sep
(1) |
Oct
(30) |
Nov
(10) |
Dec
|
2017 |
Jan
(52) |
Feb
(9) |
Mar
(24) |
Apr
(16) |
May
(9) |
Jun
(12) |
Jul
(33) |
Aug
(8) |
Sep
|
Oct
(1) |
Nov
(2) |
Dec
(6) |
2018 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
(14) |
Jun
(1) |
Jul
(9) |
Aug
(1) |
Sep
(13) |
Oct
(8) |
Nov
(2) |
Dec
(2) |
2019 |
Jan
(1) |
Feb
(1) |
Mar
(3) |
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
2020 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
(9) |
Jul
(6) |
Aug
(25) |
Sep
(10) |
Oct
(10) |
Nov
(6) |
Dec
|
2021 |
Jan
|
Feb
|
Mar
(7) |
Apr
(1) |
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
(9) |
Oct
(1) |
Nov
|
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Artyom B. <art...@ya...> - 2012-08-01 07:14:58
|
----- Original Message ----- > From: "ele...@ex..." <ele...@ex...> > To: Artyom Beilis <art...@ya...>; cpp...@li... > Cc: > Sent: Wednesday, August 1, 2012 10:01 AM > Subject: [Cppcms-users] URGENT: strange bug ocurring > > Hi Artyom, > > We've been doing data entry into our software and we've found a strange > bug. But im not really sure how to debug it. > > We have not changed any of our code in the last week or so. > > Basically what's happening is that we have a list of aircraft parts, and > all of sudden, the whole page started repeating itself untill infinity > (including the HTML DOCTYPE), and there's weird characters all over the > page. > > The cppcms logfile is saying this: > > cppcms, warning: Failed to write response:system: Broken pipe > (http_response.cpp:279) > > but I suppose thats because we have to click the browser stop button to > stop it from infinitely repeating itself. > > Any clues? > Petr > The broken pipe warning says that the peer (client - browser) reset the connection before receiving entire page - probably because it was too big. Now I don't know what is the bug but it seems that you have some loop here... or you may got some memory corruption. Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ |
From: <ele...@ex...> - 2012-08-01 07:01:38
|
Hi Artyom, We've been doing data entry into our software and we've found a strange bug. But im not really sure how to debug it. We have not changed any of our code in the last week or so. Basically what's happening is that we have a list of aircraft parts, and all of sudden, the whole page started repeating itself untill infinity (including the HTML DOCTYPE), and there's weird characters all over the page. The cppcms logfile is saying this: cppcms, warning: Failed to write response:system: Broken pipe (http_response.cpp:279) but I suppose thats because we have to click the browser stop button to stop it from infinitely repeating itself. Any clues? Petr |
From: Artyom B. <art...@ya...> - 2012-07-31 06:21:40
|
Seems nice. I'll get to it this weekend :-) Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ ----- Original Message ----- > From: kpeo <sla...@ya...> > To: cpp...@li... > Cc: > Sent: Monday, July 30, 2012 6:11 PM > Subject: Re: [Cppcms-users] forms - select_base::msg patch > >T hank you for remarks! > I correcting mistakes, so this is new patch with tests. >>> ________________________________ >>> From: kpeo<sla...@ya...> >>> To: > "cpp...@li..."<cpp...@li...> >>> Sent: Wednesday, July 18, 2012 1:59 PM >>> Subject: [Cppcms-users] forms - select_base::msg patch >>> >>> Hello all! >>> >>> Sometimes we need to return a message, attached to selectable widget. >>> For example, we have a content structure and form inside it with > selectable widget, that has a displayed text (message) for every options. >>> As i understand, original API can't return a message - just id (int > or string). >> The problem with message that it is locale dependent. >> That is why you can specify some general id you know is constant and > unique. >> >> So getting the message is problematic and in fact your implementation > contains an error. >> >> As for example if you want to call >> >> return elements_[i].tr_option; >> >> you need to convert it according to locale (otherwise it by default is > converted according to global locale) >> >> >>> Shure, we can use id = message, but what if message >>> is not unique or we need less alphabets for option's >>> storing? We also may want to display this option as >>> message in content structure and store this option as id. >>> Well, we can use own component (map or kind of enum) to >>> store id-to-text mapping, but we already have one in original library. >>> >>> So, i decide to write this little patch for src/form.cpp and > cppcms/form.h. >>> Shure, you can use it freely at your own risk, as me ;) And i'll be > glad to see any criticism about it. >>> >>> Suggest, may be after reviewing by maintainers and if this patch looks >>> useful - it will be included in new revisions o f framework. >>> >> If you want to get message according to id you need to pass a locale > parameter and even localization domain >> to convert it. >> >> std::string msg(std::locale const&l) >> std::string msg(std::locale const&l,std::string const&domain) >> >> But I think it is bad idea in general... >> >> >> So it would probably be better to return the booster::locale::message or > std::string like >> >> >> bool selected_message_is_localized(); >> booster::locale::message selected_localized_message(); >> >> std::string selected_message(); >> >> bool message_is_localized(int num); >> booster::locale::message localized_message(int num); >> >> std::string message(int num); >> >> bool message_is_localized(std::string const&id); >> >> booster::locale::message localized_message(std::string const&id); >> >> std::string message(std::string const&id); >> >> >> And each one of the (selected_)?(localized_)?_message() >> would throw an error if the type is not correct >> >> >> >>> Regards, >>> kpeo >>> > ------------------------------------------------------------------------------ >>> Live Security Virtual Conference >>> Exclusive live event will cover all the ways today's security and >>> threat landscape has changed and how IT managers can respond. > Discussions >>> will include endpoint security, mobile security and the latest in > malware >>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >>> _______________________________________________ >>> Cppcms-users mailing list >>> Cpp...@li... >>> https://lists.sourceforge.net/lists/listinfo/cppcms-users >>> >>> >>> >> > ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |
From: kpeo <sla...@ya...> - 2012-07-30 15:12:09
|
Thank you for remarks! I correcting mistakes, so this is new patch with tests. >> ________________________________ >> From: kpeo<sla...@ya...> >> To: "cpp...@li..."<cpp...@li...> >> Sent: Wednesday, July 18, 2012 1:59 PM >> Subject: [Cppcms-users] forms - select_base::msg patch >> >> Hello all! >> >> Sometimes we need to return a message, attached to selectable widget. >> For example, we have a content structure and form inside it with selectable widget, that has a displayed text (message) for every options. >> As i understand, original API can't return a message - just id (int or string). > The problem with message that it is locale dependent. > That is why you can specify some general id you know is constant and unique. > > So getting the message is problematic and in fact your implementation contains an error. > > As for example if you want to call > > return elements_[i].tr_option; > > you need to convert it according to locale (otherwise it by default is converted according to global locale) > > >> Shure, we can use id = message, but what if message >> is not unique or we need less alphabets for option's >> storing? We also may want to display this option as >> message in content structure and store this option as id. >> Well, we can use own component (map or kind of enum) to >> store id-to-text mapping, but we already have one in original library. >> >> So, i decide to write this little patch for src/form.cpp and cppcms/form.h. >> Shure, you can use it freely at your own risk, as me ;) And i'll be glad to see any criticism about it. >> >> Suggest, may be after reviewing by maintainers and if this patch looks >> useful - it will be included in new revisions o f framework. >> > If you want to get message according to id you need to pass a locale parameter and even localization domain > to convert it. > > std::string msg(std::locale const&l) > std::string msg(std::locale const&l,std::string const&domain) > > But I think it is bad idea in general... > > > So it would probably be better to return the booster::locale::message or std::string like > > > bool selected_message_is_localized(); > booster::locale::message selected_localized_message(); > > std::string selected_message(); > > bool message_is_localized(int num); > booster::locale::message localized_message(int num); > > std::string message(int num); > > bool message_is_localized(std::string const&id); > > booster::locale::message localized_message(std::string const&id); > > std::string message(std::string const&id); > > > And each one of the (selected_)?(localized_)?_message() > would throw an error if the type is not correct > > > >> Regards, >> kpeo >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> >> >> > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users |
From: Lee E. <le...@el...> - 2012-07-27 19:26:52
|
it keeps the union aligned properly by making sure its size fits the other memeber and fits a multiplication of the alignment size On Fri, Jul 27, 2012 at 6:58 AM, 郭春晓 <rj...@12...> wrote: > > > > -------- Forwarding messages -------- > From: "郭春晓" <rj...@12...> > Date: 2012-07-27 11:57:16 > To: art...@ya... > Subject: sorry to ask this question but i do not know where to ask > Hi all: > In high performance server,we all see the code as follow. > typedef *union* > { > erts_smp_rwmtx_t rwmtx; > byte > cache_line_align_[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(erts_smp_rwmtx_t))]; > }*erts_meta_main_tab_lock_t*; > > *erts_meta_main_tab_lock_t* main_tab_lock[16]; > > what can cache_line_align_ do and the benefit of it ? > > > > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > |
From: 郭春晓 <rj...@12...> - 2012-07-27 03:58:37
|
-------- Forwarding messages -------- From: "郭春晓" <rj...@12...> Date: 2012-07-27 11:57:16 To: art...@ya... Subject: sorry to ask this question but i do not know where to ask Hi all: In high performance server,we all see the code as follow. typedef union { erts_smp_rwmtx_t rwmtx; byte cache_line_align_[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(erts_smp_rwmtx_t))]; }erts_meta_main_tab_lock_t; erts_meta_main_tab_lock_t main_tab_lock[16]; what can cache_line_align_ do and the benefit of it ? |
From: Artyom B. <art...@ya...> - 2012-07-19 13:40:14
|
----- Original Message ----- > From: Christian Gmeiner <chr...@gm...> > To: Artyom Beilis <art...@ya...>; cpp...@li... > Cc: > Sent: Thursday, July 19, 2012 3:58 PM > Subject: Re: [Cppcms-users] cppcms::service and system(..) > > 2012/7/19 Artyom Beilis <art...@ya...>: >> Make sure you do not call system from asynchronous application - call it >> only from thread pool >> > > The asynchronous application (javascript RPC) get the call to execute > a bash script Asynchronous JavaScript or Asynchronously mounted CppCMS Application/RPC http://cppcms.com/wikipp/en/page/cppcms_1x_application_lifetime I mean if you mount an application asynchronously than you can't call system from there as all I/O would be blocked by system > via system(..). How can I trigger the calling from thread pool? See in cppcms::service::thread_pool and cppcms::thread_pool documentation Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > thanks > --- > Christian Gmeiner, MSc > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |
From: Christian G. <chr...@gm...> - 2012-07-19 12:58:53
|
2012/7/19 Artyom Beilis <art...@ya...>: > Make sure you do not call system from asynchronous application - call it > only from thread pool > The asynchronous application (javascript RPC) get the call to execute a bash script via system(..). How can I trigger the calling from thread pool? thanks --- Christian Gmeiner, MSc |
From: Artyom B. <art...@ya...> - 2012-07-19 08:34:06
|
>________________________________ > From: kpeo <sla...@ya...> >To: "cpp...@li..." <cpp...@li...> >Sent: Wednesday, July 18, 2012 1:59 PM >Subject: [Cppcms-users] forms - select_base::msg patch > >Hello all! > >Sometimes we need to return a message, attached to selectable widget. >For example, we have a content structure and form inside it with selectable widget, that has a displayed text (message) for every options. >As i understand, original API can't return a message - just id (int or string). The problem with message that it is locale dependent. That is why you can specify some general id you know is constant and unique. So getting the message is problematic and in fact your implementation contains an error. As for example if you want to call return elements_[i].tr_option; you need to convert it according to locale (otherwise it by default is converted according to global locale) > Shure, we can use id = message, but what if message > is not unique or we need less alphabets for option's > storing? We also may want to display this option as > message in content structure and store this option as id. > Well, we can use own component (map or kind of enum) to > store id-to-text mapping, but we already have one in original library. > > So, i decide to write this little patch for src/form.cpp and cppcms/form.h. > Shure, you can use it freely at your own risk, as me ;) And i'll be glad to see any criticism about it. > > Suggest, may be after reviewing by maintainers and if this patch looks > useful - it will be included in new revisions o f framework. > If you want to get message according to id you need to pass a locale parameter and even localization domain to convert it. std::string msg(std::locale const &l) std::string msg(std::locale const &l,std::string const &domain) But I think it is bad idea in general... So it would probably be better to return the booster::locale::message or std::string like bool selected_message_is_localized(); booster::locale::message selected_localized_message(); std::string selected_message(); bool message_is_localized(int num); booster::locale::message localized_message(int num); std::string message(int num); bool message_is_localized(std::string const &id); booster::locale::message localized_message(std::string const &id); std::string message(std::string const &id); And each one of the (selected_)?(localized_)?_message() would throw an error if the type is not correct >Regards, >kpeo >------------------------------------------------------------------------------ >Live Security Virtual Conference >Exclusive live event will cover all the ways today's security and >threat landscape has changed and how IT managers can respond. Discussions >will include endpoint security, mobile security and the latest in malware >threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >_______________________________________________ >Cppcms-users mailing list >Cpp...@li... >https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > |
From: Stanimir M. <sta...@zo...> - 2012-07-19 08:06:02
|
Sorry for bothering you! It should be my something wrong with my ubuntu development machine, so i will setup a new clean one and i bet the problem will disappear. If it doesn't then i will write back again. Actually, this looks to be very common problem, i.e. messing up something bad with multiple installations. That's why i am tring to do everything in a new virtual machine first, before posting again for help. On Thu, Jul 19, 2012 at 10:54 AM, Artyom Beilis <art...@ya...> wrote: > - What exactly the error? > - What symbols are missing? > - How exactly do you link? > > Artyom Beilis > -------------- > CppCMS - C++ Web Framework: http://cppcms.com/ > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > ________________________________ > From: Stanimir Mladenov <sta...@zo...> > To: CppCMS users group <cpp...@li...> > Sent: Monday, July 16, 2012 7:10 PM > Subject: [Cppcms-users] Boost locale with icu backend static linking. > > Boost locale with dynamic linking works just fine. When i try to link > it statically i get bunch of unresolved externals. > > 1. I did try with plain icu api call and static linking. Works. > 2. I tried a simple libboost_filesystem api call with static linking. Works. > > The only problem is when I try to link libboost_locale statically. > Does someone is able to statically link it? > > Greetings, > Stanimir > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |
From: Artyom B. <art...@ya...> - 2012-07-19 07:56:56
|
Make sure you do not call system from asynchronous application - call it only from thread pool In general I don't see why shouldn't system work. I have some project that run latex from the application (even thou not using system but rather using fork+exec) Bottom line show the code. Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >________________________________ > From: Christian Gmeiner <chr...@gm...> >To: cpp...@li... >Sent: Wednesday, July 18, 2012 2:03 PM >Subject: [Cppcms-users] cppcms::service and system(..) > >Hi all, > >I would like to implement a Service class based on cppcms::service. I would like >to trigger the rpc call via java script (works) and in the Service >class I would like >to use system() function to execute a bash script. > >If after executing/while executing the system function the cppcms apps >hangs completely. >My Service implements also a RPC call which does a reboot of the >system - which works. > >Any idea what could went wrong? > >thanks >--- >Christian Gmeiner, MSc > >------------------------------------------------------------------------------ >Live Security Virtual Conference >Exclusive live event will cover all the ways today's security and >threat landscape has changed and how IT managers can respond. Discussions >will include endpoint security, mobile security and the latest in malware >threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >_______________________________________________ >Cppcms-users mailing list >Cpp...@li... >https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > |
From: Artyom B. <art...@ya...> - 2012-07-19 07:54:54
|
- What exactly the error? - What symbols are missing? - How exactly do you link? Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >________________________________ > From: Stanimir Mladenov <sta...@zo...> >To: CppCMS users group <cpp...@li...> >Sent: Monday, July 16, 2012 7:10 PM >Subject: [Cppcms-users] Boost locale with icu backend static linking. > >Boost locale with dynamic linking works just fine. When i try to link >it statically i get bunch of unresolved externals. > >1. I did try with plain icu api call and static linking. Works. >2. I tried a simple libboost_filesystem api call with static linking. Works. > >The only problem is when I try to link libboost_locale statically. >Does someone is able to statically link it? > >Greetings, >Stanimir > >------------------------------------------------------------------------------ >Live Security Virtual Conference >Exclusive live event will cover all the ways today's security and >threat landscape has changed and how IT managers can respond. Discussions >will include endpoint security, mobile security and the latest in malware >threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >_______________________________________________ >Cppcms-users mailing list >Cpp...@li... >https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > |
From: kpeo <sla...@ya...> - 2012-07-18 12:12:14
|
Ugh, never write a letter and especially code online, sorry ) (if it possible - please remove last my message from maillist) "while" in function originally looks like this, but needs in timeout implementation: while(fgets(buf, MAX_BUFFER, pipe) != NULL) { out.append(buf); } See additionally: Application Lifetime: http://cppcms.com/wikipp/en/page/cppcms_1x_application_lifetime Thread Safety: http://cppcms.com/wikipp/en/page/thread_safety Async programming: http://cppcms.com/wikipp/en/page/cppcms_1x_aio Thread about background processes: http://comments.gmane.org/gmane.comp.lib.cppcms.user/1326 Regards, kpeo 18.07.2012, 15:03, "Christian Gmeiner" <chr...@gm...>: > Hi all, > > I would like to implement a Service class based on cppcms::service. I would like > to trigger the rpc call via java script (works) and in the Service > class I would like > to use system() function to execute a bash script. > > If after executing/while executing the system function the cppcms apps > hangs completely. > My Service implements also a RPC call which does a reboot of the > system - which works. > > Any idea what could went wrong? > > thanks > --- > Christian Gmeiner, MSc > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users |
From: kpeo <sla...@ya...> - 2012-07-18 11:48:16
|
sorry, accidentally hit "send" ) # define MAX_BUFFER 1024 std::string vexec(std::string const &cmd, int timeout) { char buf[MAX_BUFFER]; std::string out; FILE* pipe = popen(cmd.c_str(), "r" ); if (pipe == NULL ) { BOOSTER_LOG(debug,__FUNCTION__) << "invoking " << cmd << " is failed"; return ""; } while(fgets(buf, MAX_BUFFER, pipe) != NULL) { out.append(buf); } pclose(pipe); return out; } 18.07.2012, 15:03, "Christian Gmeiner" <chr...@gm...>: > Hi all, > > I would like to implement a Service class based on cppcms::service. I would like > to trigger the rpc call via java script (works) and in the Service > class I would like > to use system() function to execute a bash script. > > If after executing/while executing the system function the cppcms apps > hangs completely. > My Service implements also a RPC call which does a reboot of the > system - which works. > > Any idea what could went wrong? > > thanks > --- > Christian Gmeiner, MSc > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users |
From: kpeo <sla...@ya...> - 2012-07-18 11:42:35
|
Hello, Fast answer: system() is not so thread-safe way for calling system scripts. E.g., you can use booster::aio::deadline_timer (async_wait method) or simple "old" pipe-method like this: # define MAX_BUFFER 1024 std::string vexec(std::string const &cmd) { char buf[MAX_BUFFER]; std::string out; FILE* pipe = popen(cmd.c_str(), "r" ); if (pipe == NULL ) { BOOSTER_LOG(debug,__FUNCTION__) << "invoking " << cmd << " is failed"; return ""; } while(1) { fgets(buf, MAX_BUFFER, pipe) != NULL ) { out.append(buf); } pclose(pipe); return out; } Shure, this realisation needs in implementing of timeout for waiting of answer. Regards, kpeo 18.07.2012, 15:03, "Christian Gmeiner" <chr...@gm...>: > Hi all, > > I would like to implement a Service class based on cppcms::service. I would like > to trigger the rpc call via java script (works) and in the Service > class I would like > to use system() function to execute a bash script. > > If after executing/while executing the system function the cppcms apps > hangs completely. > My Service implements also a RPC call which does a reboot of the > system - which works. > > Any idea what could went wrong? > > thanks > --- > Christian Gmeiner, MSc > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users |
From: Christian G. <chr...@gm...> - 2012-07-18 11:04:19
|
Hi all, I would like to implement a Service class based on cppcms::service. I would like to trigger the rpc call via java script (works) and in the Service class I would like to use system() function to execute a bash script. If after executing/while executing the system function the cppcms apps hangs completely. My Service implements also a RPC call which does a reboot of the system - which works. Any idea what could went wrong? thanks --- Christian Gmeiner, MSc |
From: kpeo <sla...@ya...> - 2012-07-18 10:59:18
|
Hello all! Sometimes we need to return a message, attached to selectable widget. For example, we have a content structure and form inside it with selectable widget, that has a displayed text (message) for every options. As i understand, original API can't return a message - just id (int or string). Shure, we can use id = message, but what if message is not unique or we need less alphabets for option's storing? We also may want to display this option as message in content structure and store this option as id. Well, we can use own component (map or kind of enum) to store id-to-text mapping, but we already have one in original library. So, i decide to write this little patch for src/form.cpp and cppcms/form.h. Shure, you can use it freely at your own risk, as me ;) And i'll be glad to see any criticism about it. Suggest, may be after reviewing by maintainers and if this patch looks useful - it will be included in new revisions of framework. Regards, kpeo |
From: Stanimir M. <sta...@zo...> - 2012-07-16 16:11:29
|
Boost locale with dynamic linking works just fine. When i try to link it statically i get bunch of unresolved externals. 1. I did try with plain icu api call and static linking. Works. 2. I tried a simple libboost_filesystem api call with static linking. Works. The only problem is when I try to link libboost_locale statically. Does someone is able to statically link it? Greetings, Stanimir |
From: Shiv S. D. <shi...@gm...> - 2012-07-14 17:01:37
|
Hi, You can wrap several document based DBs APis to provide a consistent familiar interface to user. Only requirement is that they should return similar sort of data if not same. On Fri, Jul 13, 2012 at 11:32 PM, 陈抒 <csf...@gm...> wrote: > I used CppCMS with MongoDB for several months. > Don't need to wrap it. MongoDB is a document database(or NoSQL database), I > don't think you could get any benefit from wrapping it. > > > > 陈抒 > Best regards > http://blog.csdn.net/sheismylife > > > > On Sat, Jul 14, 2012 at 1:02 AM, Daniel Vallejos <chi...@gm...> > wrote: >> >> I am curious. >> >> What is the benefit for wrapping mongodb instead of just using native >> mongodb C++ API in cppcms? >> >> Bests. >> >> Daniel Vallejos. >> >> On Thu, 2012-07-12 at 19:20 +0530, Shiv Shankar Dayal wrote: >> > I think as a separation I can put all code in a namespace inside cppdb >> > like nosql. The problem is that these are not like RDBMS and interface >> > will have to use individual DBs C++ API. So, to nullify the effect on >> > existing cppdb I think putting new code in a new namespace should >> > suffice. >> > Once the wrappers are complete and interface is similar or same we can >> > go forward or leave it inside the new namespace if interfaces are not >> > alike. >> > >> > On Thu, Jul 12, 2012 at 6:36 PM, Artyom Beilis <art...@ya...> >> > wrote: >> > > See, technically, if your queries results are tables and data-types >> > > are >> > > string, datetime, integer, floating point, blob >> > > you can develop your own backend for CppDB. And than do queries like: >> > > >> > > cppdb::session db("mongodb:some-parameter=somevalue"); >> > > cppdb::result r = db << "db.users.find({'last_name': 'Smith'})"; >> > > while(r.next()) { >> > > std::string first_name = r.get<std::string>("first_name"); >> > > } >> > > >> > > But I'm not sure it would be the best approach >> > > >> > > Still, if you want to take a look on: >> > > >> > > http://cppcms.com/sql/cppdb/backenddev.html >> > > >> > > >> > > >> > > Artyom Beilis >> > > -------------- >> > > CppCMS - C++ Web Framework: http://cppcms.com/ >> > > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >> > > >> > > ________________________________ >> > > From: Shiv Shankar Dayal <shi...@gm...> >> > > To: cpp...@li... >> > > Sent: Thursday, July 12, 2012 3:25 PM >> > > Subject: Re: [Cppcms-users] MongoDB and Hypertable support >> > > >> > > Then this means that I should start some new module like CppNoSQL. >> > > How difficult it can be to adapt such a module to CppCMS? >> > > >> > > On Thu, Jul 12, 2012 at 5:50 PM, Artyom Beilis <art...@ya...> >> > > wrote: >> > >> See, CppDB is an engine for relational databases - SQL, it is >> > >> designed for >> > >> them. >> > >> >> > >> So I don't really see how can you fit stuff like MongoDB to such >> > >> database >> > >> layer. >> > >> >> > >> Artyom Beilis >> > >> -------------- >> > >> CppCMS - C++ Web Framework: http://cppcms.com/ >> > >> CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >> > >> >> > >> ________________________________ >> > >> From: Shiv Shankar Dayal <shi...@gm...> >> > >> To: cpp...@li... >> > >> Sent: Thursday, July 12, 2012 2:08 PM >> > >> Subject: [Cppcms-users] MongoDB and Hypertable support >> > >> >> > >> Hi, >> > >> >> > >> I want to add MongoDB and Hypertable (and possibly more noSQL DBs) >> > >> support to CppDB. What do you think is the best approach to achieve >> > >> this? >> > >> >> > >> -- >> > >> Best regards, >> > >> Shiv Shankar Dayal >> > >> >> > >> >> > >> >> > >> ------------------------------------------------------------------------------ >> > >> Live Security Virtual Conference >> > >> Exclusive live event will cover all the ways today's security and >> > >> threat landscape has changed and how IT managers can respond. >> > >> Discussions >> > >> will include endpoint security, mobile security and the latest in >> > >> malware >> > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> > >> _______________________________________________ >> > >> Cppcms-users mailing list >> > >> Cpp...@li... >> > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > >> >> > >> >> > >> >> > >> >> > >> >> > >> ------------------------------------------------------------------------------ >> > >> Live Security Virtual Conference >> > >> Exclusive live event will cover all the ways today's security and >> > >> threat landscape has changed and how IT managers can respond. >> > >> Discussions >> > >> will include endpoint security, mobile security and the latest in >> > >> malware >> > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> > >> _______________________________________________ >> > >> Cppcms-users mailing list >> > >> Cpp...@li... >> > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > >> >> > > >> > > >> > > >> > > -- >> > > Best regards, >> > > Shiv Shankar Dayal >> > > >> > > >> > > ------------------------------------------------------------------------------ >> > > Live Security Virtual Conference >> > > Exclusive live event will cover all the ways today's security and >> > > threat landscape has changed and how IT managers can respond. >> > > Discussions >> > > will include endpoint security, mobile security and the latest in >> > > malware >> > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> > > _______________________________________________ >> > > Cppcms-users mailing list >> > > Cpp...@li... >> > > https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > > >> > > >> > > >> > > >> > > ------------------------------------------------------------------------------ >> > > Live Security Virtual Conference >> > > Exclusive live event will cover all the ways today's security and >> > > threat landscape has changed and how IT managers can respond. >> > > Discussions >> > > will include endpoint security, mobile security and the latest in >> > > malware >> > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> > > _______________________________________________ >> > > Cppcms-users mailing list >> > > Cpp...@li... >> > > https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > > >> > >> > >> > >> >> >> >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > -- Best regards, Shiv Shankar Dayal |
From: 陈抒 <csf...@gm...> - 2012-07-13 18:03:25
|
I used CppCMS with MongoDB for several months. Don't need to wrap it. MongoDB is a document database(or NoSQL database), I don't think you could get any benefit from wrapping it. 陈抒 Best regards http://blog.csdn.net/sheismylife On Sat, Jul 14, 2012 at 1:02 AM, Daniel Vallejos <chi...@gm...>wrote: > I am curious. > > What is the benefit for wrapping mongodb instead of just using native > mongodb C++ API in cppcms? > > Bests. > > Daniel Vallejos. > > On Thu, 2012-07-12 at 19:20 +0530, Shiv Shankar Dayal wrote: > > I think as a separation I can put all code in a namespace inside cppdb > > like nosql. The problem is that these are not like RDBMS and interface > > will have to use individual DBs C++ API. So, to nullify the effect on > > existing cppdb I think putting new code in a new namespace should > suffice. > > Once the wrappers are complete and interface is similar or same we can > > go forward or leave it inside the new namespace if interfaces are not > alike. > > > > On Thu, Jul 12, 2012 at 6:36 PM, Artyom Beilis <art...@ya...> > wrote: > > > See, technically, if your queries results are tables and data-types are > > > string, datetime, integer, floating point, blob > > > you can develop your own backend for CppDB. And than do queries like: > > > > > > cppdb::session db("mongodb:some-parameter=somevalue"); > > > cppdb::result r = db << "db.users.find({'last_name': 'Smith'})"; > > > while(r.next()) { > > > std::string first_name = r.get<std::string>("first_name"); > > > } > > > > > > But I'm not sure it would be the best approach > > > > > > Still, if you want to take a look on: > > > > > > http://cppcms.com/sql/cppdb/backenddev.html > > > > > > > > > > > > Artyom Beilis > > > -------------- > > > CppCMS - C++ Web Framework: http://cppcms.com/ > > > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > > > > > ________________________________ > > > From: Shiv Shankar Dayal <shi...@gm...> > > > To: cpp...@li... > > > Sent: Thursday, July 12, 2012 3:25 PM > > > Subject: Re: [Cppcms-users] MongoDB and Hypertable support > > > > > > Then this means that I should start some new module like CppNoSQL. > > > How difficult it can be to adapt such a module to CppCMS? > > > > > > On Thu, Jul 12, 2012 at 5:50 PM, Artyom Beilis <art...@ya...> > wrote: > > >> See, CppDB is an engine for relational databases - SQL, it is > designed for > > >> them. > > >> > > >> So I don't really see how can you fit stuff like MongoDB to such > database > > >> layer. > > >> > > >> Artyom Beilis > > >> -------------- > > >> CppCMS - C++ Web Framework: http://cppcms.com/ > > >> CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > >> > > >> ________________________________ > > >> From: Shiv Shankar Dayal <shi...@gm...> > > >> To: cpp...@li... > > >> Sent: Thursday, July 12, 2012 2:08 PM > > >> Subject: [Cppcms-users] MongoDB and Hypertable support > > >> > > >> Hi, > > >> > > >> I want to add MongoDB and Hypertable (and possibly more noSQL DBs) > > >> support to CppDB. What do you think is the best approach to achieve > > >> this? > > >> > > >> -- > > >> Best regards, > > >> Shiv Shankar Dayal > > >> > > >> > > >> > ------------------------------------------------------------------------------ > > >> Live Security Virtual Conference > > >> Exclusive live event will cover all the ways today's security and > > >> threat landscape has changed and how IT managers can respond. > Discussions > > >> will include endpoint security, mobile security and the latest in > malware > > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > >> _______________________________________________ > > >> Cppcms-users mailing list > > >> Cpp...@li... > > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > > >> > > >> > > >> > > >> > > >> > ------------------------------------------------------------------------------ > > >> Live Security Virtual Conference > > >> Exclusive live event will cover all the ways today's security and > > >> threat landscape has changed and how IT managers can respond. > Discussions > > >> will include endpoint security, mobile security and the latest in > malware > > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > >> _______________________________________________ > > >> Cppcms-users mailing list > > >> Cpp...@li... > > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > > >> > > > > > > > > > > > > -- > > > Best regards, > > > Shiv Shankar Dayal > > > > > > > ------------------------------------------------------------------------------ > > > Live Security Virtual Conference > > > Exclusive live event will cover all the ways today's security and > > > threat landscape has changed and how IT managers can respond. > Discussions > > > will include endpoint security, mobile security and the latest in > malware > > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > > _______________________________________________ > > > Cppcms-users mailing list > > > Cpp...@li... > > > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > > > > > > > > > > ------------------------------------------------------------------------------ > > > Live Security Virtual Conference > > > Exclusive live event will cover all the ways today's security and > > > threat landscape has changed and how IT managers can respond. > Discussions > > > will include endpoint security, mobile security and the latest in > malware > > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > > _______________________________________________ > > > Cppcms-users mailing list > > > Cpp...@li... > > > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > > > > > > > > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |
From: Daniel V. <chi...@gm...> - 2012-07-13 17:03:01
|
I am curious. What is the benefit for wrapping mongodb instead of just using native mongodb C++ API in cppcms? Bests. Daniel Vallejos. On Thu, 2012-07-12 at 19:20 +0530, Shiv Shankar Dayal wrote: > I think as a separation I can put all code in a namespace inside cppdb > like nosql. The problem is that these are not like RDBMS and interface > will have to use individual DBs C++ API. So, to nullify the effect on > existing cppdb I think putting new code in a new namespace should suffice. > Once the wrappers are complete and interface is similar or same we can > go forward or leave it inside the new namespace if interfaces are not alike. > > On Thu, Jul 12, 2012 at 6:36 PM, Artyom Beilis <art...@ya...> wrote: > > See, technically, if your queries results are tables and data-types are > > string, datetime, integer, floating point, blob > > you can develop your own backend for CppDB. And than do queries like: > > > > cppdb::session db("mongodb:some-parameter=somevalue"); > > cppdb::result r = db << "db.users.find({'last_name': 'Smith'})"; > > while(r.next()) { > > std::string first_name = r.get<std::string>("first_name"); > > } > > > > But I'm not sure it would be the best approach > > > > Still, if you want to take a look on: > > > > http://cppcms.com/sql/cppdb/backenddev.html > > > > > > > > Artyom Beilis > > -------------- > > CppCMS - C++ Web Framework: http://cppcms.com/ > > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > > > ________________________________ > > From: Shiv Shankar Dayal <shi...@gm...> > > To: cpp...@li... > > Sent: Thursday, July 12, 2012 3:25 PM > > Subject: Re: [Cppcms-users] MongoDB and Hypertable support > > > > Then this means that I should start some new module like CppNoSQL. > > How difficult it can be to adapt such a module to CppCMS? > > > > On Thu, Jul 12, 2012 at 5:50 PM, Artyom Beilis <art...@ya...> wrote: > >> See, CppDB is an engine for relational databases - SQL, it is designed for > >> them. > >> > >> So I don't really see how can you fit stuff like MongoDB to such database > >> layer. > >> > >> Artyom Beilis > >> -------------- > >> CppCMS - C++ Web Framework: http://cppcms.com/ > >> CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > >> > >> ________________________________ > >> From: Shiv Shankar Dayal <shi...@gm...> > >> To: cpp...@li... > >> Sent: Thursday, July 12, 2012 2:08 PM > >> Subject: [Cppcms-users] MongoDB and Hypertable support > >> > >> Hi, > >> > >> I want to add MongoDB and Hypertable (and possibly more noSQL DBs) > >> support to CppDB. What do you think is the best approach to achieve > >> this? > >> > >> -- > >> Best regards, > >> Shiv Shankar Dayal > >> > >> > >> ------------------------------------------------------------------------------ > >> Live Security Virtual Conference > >> Exclusive live event will cover all the ways today's security and > >> threat landscape has changed and how IT managers can respond. Discussions > >> will include endpoint security, mobile security and the latest in malware > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > >> _______________________________________________ > >> Cppcms-users mailing list > >> Cpp...@li... > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > >> > >> > >> > >> > >> ------------------------------------------------------------------------------ > >> Live Security Virtual Conference > >> Exclusive live event will cover all the ways today's security and > >> threat landscape has changed and how IT managers can respond. Discussions > >> will include endpoint security, mobile security and the latest in malware > >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > >> _______________________________________________ > >> Cppcms-users mailing list > >> Cpp...@li... > >> https://lists.sourceforge.net/lists/listinfo/cppcms-users > >> > > > > > > > > -- > > Best regards, > > Shiv Shankar Dayal > > > > ------------------------------------------------------------------------------ > > Live Security Virtual Conference > > Exclusive live event will cover all the ways today's security and > > threat landscape has changed and how IT managers can respond. Discussions > > will include endpoint security, mobile security and the latest in malware > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > _______________________________________________ > > Cppcms-users mailing list > > Cpp...@li... > > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > > > > > ------------------------------------------------------------------------------ > > Live Security Virtual Conference > > Exclusive live event will cover all the ways today's security and > > threat landscape has changed and how IT managers can respond. Discussions > > will include endpoint security, mobile security and the latest in malware > > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > _______________________________________________ > > Cppcms-users mailing list > > Cpp...@li... > > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > > |
From: Artyom B. <art...@ya...> - 2012-07-12 22:36:00
|
>________________________________ > From: Manveru <ma...@ma...> >To: Artyom Beilis <art...@ya...>; cpp...@li... >Sent: Thursday, July 12, 2012 11:18 PM >Subject: Re: [Cppcms-users] wikipp: all uri returns 302 on internal cppcms webserver > > >Oh yes! Thank you, that helped. But these two steps are not mentioned on documentation page. > Because you are not supposed to run wikipp behind internal web server. It is always recommended to use full web server like Lighttpd, Nginx or Apache. Internal web server should be used for development and embedded systems only >Is it possible to pass some configuration to the Discount markdown library? I would like to enable inline HTML and definition lists. > >Thanks in advance. > No, just edit the code :-) Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ |
From: Manveru <ma...@ma...> - 2012-07-12 20:19:01
|
Oh yes! Thank you, that helped. But these two steps are not mentioned on documentation page. Is it possible to pass some configuration to the Discount markdown library? I would like to enable inline HTML and definition lists. Thanks in advance. 2012/7/12 Artyom Beilis <art...@ya...> > Two points: > > 1. You should configure the script name as "/wikipp", see: > http://cppcms.com/wikipp/en/page/cppcms_1x_config#http.script > 2. You had not enabled internal file server :-) you need to serve > static file as well. Point its document root to correct location such > that, see: > http://cppcms.com/wikipp/en/page/cppcms_1x_config#file_server > > > Artyom Beilis > -------------- > CppCMS - C++ Web Framework: http://cppcms.com/ > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > -- Manveru jabber: ma...@ma... gg: 1624001 http://www.manveru.pl |
From: Shiv S. D. <shi...@gm...> - 2012-07-12 13:50:41
|
I think as a separation I can put all code in a namespace inside cppdb like nosql. The problem is that these are not like RDBMS and interface will have to use individual DBs C++ API. So, to nullify the effect on existing cppdb I think putting new code in a new namespace should suffice. Once the wrappers are complete and interface is similar or same we can go forward or leave it inside the new namespace if interfaces are not alike. On Thu, Jul 12, 2012 at 6:36 PM, Artyom Beilis <art...@ya...> wrote: > See, technically, if your queries results are tables and data-types are > string, datetime, integer, floating point, blob > you can develop your own backend for CppDB. And than do queries like: > > cppdb::session db("mongodb:some-parameter=somevalue"); > cppdb::result r = db << "db.users.find({'last_name': 'Smith'})"; > while(r.next()) { > std::string first_name = r.get<std::string>("first_name"); > } > > But I'm not sure it would be the best approach > > Still, if you want to take a look on: > > http://cppcms.com/sql/cppdb/backenddev.html > > > > Artyom Beilis > -------------- > CppCMS - C++ Web Framework: http://cppcms.com/ > CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ > > ________________________________ > From: Shiv Shankar Dayal <shi...@gm...> > To: cpp...@li... > Sent: Thursday, July 12, 2012 3:25 PM > Subject: Re: [Cppcms-users] MongoDB and Hypertable support > > Then this means that I should start some new module like CppNoSQL. > How difficult it can be to adapt such a module to CppCMS? > > On Thu, Jul 12, 2012 at 5:50 PM, Artyom Beilis <art...@ya...> wrote: >> See, CppDB is an engine for relational databases - SQL, it is designed for >> them. >> >> So I don't really see how can you fit stuff like MongoDB to such database >> layer. >> >> Artyom Beilis >> -------------- >> CppCMS - C++ Web Framework: http://cppcms.com/ >> CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >> >> ________________________________ >> From: Shiv Shankar Dayal <shi...@gm...> >> To: cpp...@li... >> Sent: Thursday, July 12, 2012 2:08 PM >> Subject: [Cppcms-users] MongoDB and Hypertable support >> >> Hi, >> >> I want to add MongoDB and Hypertable (and possibly more noSQL DBs) >> support to CppDB. What do you think is the best approach to achieve >> this? >> >> -- >> Best regards, >> Shiv Shankar Dayal >> >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> >> >> >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > > > > -- > Best regards, > Shiv Shankar Dayal > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > -- Best regards, Shiv Shankar Dayal |
From: Artyom B. <art...@ya...> - 2012-07-12 13:07:08
|
See, technically, if your queries results are tables and data-types are string, datetime, integer, floating point, blob you can develop your own backend for CppDB. And than do queries like: cppdb::session db("mongodb:some-parameter=somevalue"); cppdb::result r = db << "db.users.find({'last_name': 'Smith'})"; while(r.next()) { std::string first_name = r.get<std::string>("first_name"); } But I'm not sure it would be the best approach Still, if you want to take a look on: http://cppcms.com/sql/cppdb/backenddev.html Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >________________________________ > From: Shiv Shankar Dayal <shi...@gm...> >To: cpp...@li... >Sent: Thursday, July 12, 2012 3:25 PM >Subject: Re: [Cppcms-users] MongoDB and Hypertable support > >Then this means that I should start some new module like CppNoSQL. >How difficult it can be to adapt such a module to CppCMS? > >On Thu, Jul 12, 2012 at 5:50 PM, Artyom Beilis <art...@ya...> wrote: >> See, CppDB is an engine for relational databases - SQL, it is designed for >> them. >> >> So I don't really see how can you fit stuff like MongoDB to such database >> layer. >> >> Artyom Beilis >> -------------- >> CppCMS - C++ Web Framework: http://cppcms.com/ >> CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >> >> ________________________________ >> From: Shiv Shankar Dayal <shi...@gm...> >> To: cpp...@li... >> Sent: Thursday, July 12, 2012 2:08 PM >> Subject: [Cppcms-users] MongoDB and Hypertable support >> >> Hi, >> >> I want to add MongoDB and Hypertable (and possibly more noSQL DBs) >> support to CppDB. What do you think is the best approach to achieve >> this? >> >> -- >> Best regards, >> Shiv Shankar Dayal >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> >> >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Cppcms-users mailing list >> Cpp...@li... >> https://lists.sourceforge.net/lists/listinfo/cppcms-users >> > > > >-- >Best regards, >Shiv Shankar Dayal > >------------------------------------------------------------------------------ >Live Security Virtual Conference >Exclusive live event will cover all the ways today's security and >threat landscape has changed and how IT managers can respond. Discussions >will include endpoint security, mobile security and the latest in malware >threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >_______________________________________________ >Cppcms-users mailing list >Cpp...@li... >https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > |