Search Results

Search found 3243 results on 130 pages for 'artwork creation'.

Page 10/130 | < Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >

  • Force language change from custom account creation script through url

    - by jax
    I have made a custom 'Account Creation' script so that users can login from my phone application. What I want is to be able to change the responses from the server depending on their locale. So when I request a page I would add lang=en or lang=zh etc. This works http://mysite.com/phone/my_custom_account_creation.php?lang=en Response: <resource classification="error" code="Error (Code: 500)"> <message>Please enter your name:</message> </resource> This does not work: http://mysite.com/phone/my_custom_account_creation.php?lang=zh Response: <resource classification="error" code="Error (Code: 500)"> <message>Please enter your name:</message> </resource> If I go into Joomla at set the default language to chinese, it works. <resource classification="error" code="Error (Code: 500)"> <message>????????</message> </resource> but http://mysite.com/phone/my_custom_account_creation.php?lang=en does not work, instead it continues to show the chinese version. What might I be able to do here?

    Read the article

  • Creation of model in core data on the fly

    - by user1740045
    How can we create a model in core data on the fly? I.e getting the schema of database from somewhere and then creating a Core Data Object graph? *QuesTion:* Yes thats fine, agreed with all the advantages. But, can anybody can tell practically, what is the benefit of integrating Core Data into project instead of using SQL directly. 1.No need to write SQL boiler plate code [but need to learn Core Data Model (steep curve)] 2.WE can undo and redo changes [but practically who needs it] 3.we can migrate to another schema [that can be done by SQLite as well jus need to add another field into table] 4.For say aggregation on some field in table,in Core Data we need to loop through Core Data Objects whereas in SQLite we need to first write SQLite Boiler Plate Code and then the basic aggregation SQL query,which is easy to write,only length of code will increase...But in case of Core Data (need to learn a lot). So apart from reducing the length of Code,does it actually adds value to project? or in terms of Memory Efficiency,Performance,etc.. PS: If anybody has actualy worked on Core Data(Model Creation On the Fly) , if possible share and gve pointers..thanks!

    Read the article

  • file.createNewFile() creates files with last-modified time before actual creation time

    - by Kaleb Pederson
    I'm using JPoller to detect changes to files in a specific directory, but it's missing files because they end up with a timestamp earlier than their actual creation time. Here's how I test: public static void main(String [] files) { for (String file : files) { File f = new File(file); if (f.exists()) { System.err.println(file + " exists"); continue; } try { // find out the current time, I would hope to assume that the last-modified // time on the file will definitely be later than this System.out.println("-----------------------------------------"); long time = System.currentTimeMillis(); // create the file System.out.println("Creating " + file + " at " + time); f.createNewFile(); // let's see what the timestamp actually is (I've only seen it <time) System.out.println(file + " was last modified at: " + f.lastModified()); // well, ok, what if I explicitly set it to time? f.setLastModified(time); System.out.println("Updated modified time on " + file + " to " + time + " with actual " + f.lastModified()); } catch (IOException e) { System.err.println("Unable to create file"); } } } And here's what I get for output: ----------------------------------------- Creating test.7 at 1272324597956 test.7 was last modified at: 1272324597000 Updated modified time on test.7 to 1272324597956 with actual 1272324597000 ----------------------------------------- Creating test.8 at 1272324597957 test.8 was last modified at: 1272324597000 Updated modified time on test.8 to 1272324597957 with actual 1272324597000 ----------------------------------------- Creating test.9 at 1272324597957 test.9 was last modified at: 1272324597000 Updated modified time on test.9 to 1272324597957 with actual 1272324597000 The result is a race condition: JPoller records time of last check as xyz...123 File created at xyz...456 File last-modified timestamp actually reads xyz...000 JPoller looks for new/updated files with timestamp greater than xyz...123 JPoller ignores newly added file because xyz...000 is less than xyz...123 I pull my hair out for a while I tried digging into the code but both lastModified() and createNewFile() eventually resolve to native calls so I'm left with little information. For test.9, I lose 957 milliseconds. What kind of accuracy can I expect? Are my results going to vary by operating system or file system? Suggested workarounds? NOTE: I'm currently running Linux with an XFS filesystem. I wrote a quick program in C and the stat system call shows st_mtime as truncate(xyz...000/1000).

    Read the article

  • apt-get install fuse - MAKEDEV not installed, skipping device node creation

    - by holms
    This happened with command apt-get dist-upgrade to upgrade to debian jessie, after which I've tried to remove fuse, and install it again. Same error: root@msgapp:/dev# apt-get install fuse Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: fuse 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 0 B/69.9 kB of archives. After this operation, 191 kB of additional disk space will be used. Selecting previously unselected package fuse. (Reading database ... 39354 files and directories currently installed.) Preparing to unpack .../fuse_2.9.3-10_amd64.deb ... Unpacking fuse (2.9.3-10) ... Processing triggers for man-db (2.6.7.1-1) ... Setting up fuse (2.9.3-10) ... MAKEDEV not installed, skipping device node creation. device node not found dpkg: error processing package fuse (--configure): subprocess installed post-installation script returned error exit status 2 Errors were encountered while processing: fuse E: Sub-process /usr/bin/dpkg returned an error code (1) UPDATE Reinstalling makedev gives another problem: root@msgapp:/dev# apt-get install makedev Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: makedev 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 0 B/42.6 kB of archives. After this operation, 129 kB of additional disk space will be used. Selecting previously unselected package makedev. (Reading database ... 39347 files and directories currently installed.) Preparing to unpack .../makedev_2.3.1-93_all.deb ... Unpacking makedev (2.3.1-93) ... Processing triggers for man-db (2.6.7.1-1) ... ySetting up makedev (2.3.1-93) ... /run/udev or .udevdb or .udev presence implies active udev. Aborting MAKEDEV invocation. /run/udev or .udevdb or .udev presence implies active udev. Aborting MAKEDEV invocation. /run/udev or .udevdb or .udev presence implies active udev. Aborting MAKEDEV invocation. There's ticket raised, and their fix doesn't give any result: root@msgapp:/dev# cd /dev && ./MAKEDEV fuse /run/udev or .udevdb or .udev presence implies active udev. Aborting MAKEDEV invocation.

    Read the article

  • Google App Engine - SiteMap Creation for a social network

    - by spidee
    Hi all. I am creating a social tool - I want to allow search engines to pick up "public" user profiles - like twitter and face-book. I have seen all the protocol info at http://www.sitemaps.org and i understand this and how to build such a file - along with an index if i exceed the 50K limit. Where i am struggling is the concept of how i make this run. The site map for my general site pages is simple i can use a tool to create the file - or a script - host the file - submit the file and done. What i then need is a script that will create the site-maps of user profiles. I assume this would be something like: <?xml version="1.0" encoding="UTF-8"?> <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> <url> <loc>http://www.socialsite.com/profile/spidee</loc> <lastmod>2010-5-12</lastmod> <changefreq>???</changefreq> <priority>???</priority> </url> <url> <loc>http://www.socialsite.com/profile/webbsterisback</loc> <lastmod>2010-5-12</lastmod> <changefreq>???</changefreq> <priority>???</priority> </url> </urlset> Ive added some ??? as i don't know how i should set these settings for my profiles based on the following:- When a new profile is created it must be added to a site-map. If the profile is changed or if "certain" properties are changed - then i don't know if i update the entry in the map - or do something else? (updating would be a nightmare!) Some users may change their profile. In terms of relevance to the search engine the only way a google or yahoo search will find the users (for my requirement) profile would be for example by means of [user name] and [location] so once the entry for the profile has been added to the map file the only reason to have the search-bot re-index the profile would be if the user changed their user-name - which they cant. or their location - and or set their settings so that their profile would be "hidden" from search engines. I assume my map creation will need to be dynamic. From what i have said above i would imagine that creating a new profile and possible editing certain properties could mark it as needing adding/updating in the sitemap. Assuming i will have millions of profiles added/being edited how can i manage this in a sensible manner. i know i need a script that can append urls as each profile is created i know the script will prob be a TASK - running at a set freq - perhaps the profiles have a property like "indexed" and the TASK sets them to "true" when the profiles are added to the map. I dont see the best way to store the map - do i store it in the datastore i.e; model=sitemaps properties key_name=sitemap_xml_1 (and for my map sitemap_index_xml) mapxml=blobstore (the raw xml map or ror map) full=boolean (set true when url count is 50) # might need this as a shard will tell us To make this work my thoughts are m cache the current site map structure as "sitemap_xml" keep a shard of url count when my task executes 1. build the xml structure for say the first 100 urls marked "index==false" (how many could u run at a time?) 2. test if the current mcache sitemap is full (shardcounter+10050K) 3.a if the map is near full create a new map entry in models "sitemap_xml_2" - update the map_index file (also stored in my model as "sitemap_index" start a new shard - or reset.2 3.b if the map is not full grab it from mcache 4.append the 100 url xml structure 5.save / m cache the map I can now add a handler using a url map/route like /sitemaps/* Get my * as map name and serve the maps from the blobstore/mache on the fly. Now my question is does this work - is this the right way or a good way to start? Will this handle the situation of making sure the search bots update when a user changes their profile - possibly by setting the change freq correctly? - Do i need a more advance system :( ? or have i re-invented the wheel! I hope this is all clear and make some form of sense :-)

    Read the article

  • problem with 512x512 app icon in iTunes Connect

    - by Matthew
    I'm uploading my app to App Store and I created it in iTunes Connect. I just uploaded my 512x512px icon and then I opened Version Summary page to verify my information... I've got a set of icon that just have gloss effect. In Version Summary page I see my 512x512px icon with automatic gloss added. Is there a way to prevent this? My large app icon mustn't have gloss... In my info.plist I added the line "Icon already includes gloss effects" and I checked the box near it... Can anyone help me?

    Read the article

  • Problem in creation MDB Queue connection at Jboss StartUp

    - by Amit Ruwali
    I am not able to create a Queue connection in JBOSS4.2.3GA Version & Java1.5, as I am using MDB as per the below details. I am putting this MDB in a jar file(named utsJar.jar) and copied it in deploy folder of JBOSS, In the test env. this MDB works well but in another env. [ env settings and jboss/java ver is same ] it is throwing error at jboss start up [attached below ]. I have searched for this error but couldn't find any solution till now; was there any issue of port confict or something related with configurations ? UTSMessageListner.java @MessageDriven(activationConfig = { @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"), @ActivationConfigProperty(propertyName="destination", propertyValue="queue/UTSQueue") }) @TransactionAttribute(TransactionAttributeType.NOT_SUPPORTED) public class UTSMessageListner implements MessageListener { public void onMessage(Message msg) { ObjectMessage objmsg = (ObjectMessage) msg; try { UTSListVO utsMessageListVO = (UTSListVO) objmsg.getObject(); if(utsMessageListVO.getUtsMessageList()!=null) { UtsWebServiceLogger.logMessage("UTSMessageListner:onMessage: SIZE Of UTSMessage List =[" +utsMessageListVO.getUtsMessageList().size() + "]"); UTSDataLayerImpl.getInstance().insertUTSMessage(utsMessageListVO); } else { UtsWebServiceLogger.logMessage("UTSMessageListner:onMessage: Message List is NULL"); } } catch (Exception ex) { UtsWebServiceLogger.logMessage("UTSMessageListner:onMessage: Error Receiving Message"+ExceptionUtility.getStackTrace(ex)); } } } [ I have also attached whole server.log as an attach] /// ///////////////////////////////// Error Trace is Below while starting the server /////////////////////////// 2010-03-12 07:05:40,061 WARN [org.jboss.ejb3.mdb.MessagingContainer] Could not find the queue destination-jndi-name=queue/UTSQueue 2010-03-12 07:05:40,061 WARN [org.jboss.ejb3.mdb.MessagingContainer] destination not found: queue/UTSQueue reason: javax.naming.NameNotFoundException: queue not bound 2010-03-12 07:05:40,061 WARN [org.jboss.ejb3.mdb.MessagingContainer] creating a new temporary destination: queue/UTSQueue 2010-03-12 07:05:40,071 WARN [org.jboss.system.ServiceController] Problem starting service jboss.j2ee:ear=uts.ear,jar=utsJar.jar,name=UTSMessageListner,service=EJB3 java.lang.NullPointerException at org.jboss.mq.server.jmx.DestinationManager.createDestination(DestinationManager.java:336) at org.jboss.mq.server.jmx.DestinationManager.createQueue(DestinationManager.java:293) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.ejb3.JmxClientKernelAbstraction.invoke(JmxClientKernelAbstraction.java:44) at org.jboss.ejb3.jms.DestinationManagerJMSDestinationFactory.createDestination(DestinationManagerJMSDestinationFactory.java:75) at org.jboss.ejb3.mdb.MessagingContainer.createTemporaryDestination(MessagingContainer.java:573) at org.jboss.ejb3.mdb.MessagingContainer.createDestination(MessagingContainer.java:512) at org.jboss.ejb3.mdb.MessagingContainer.innerCreateQueue(MessagingContainer.java:438) at org.jboss.ejb3.mdb.MessagingContainer.jmsCreate(MessagingContainer.java:400) at org.jboss.ejb3.mdb.MessagingContainer.innerStart(MessagingContainer.java:166) at org.jboss.ejb3.mdb.MessagingContainer.start(MessagingContainer.java:152) at org.jboss.ejb3.mdb.MDB.start(MDB.java:126) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.ejb3.ServiceDelegateWrapper.startService(ServiceDelegateWrapper.java:103) at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289) at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978) at $Proxy0.start(Unknown Source) at org.jboss.system.ServiceController.start(ServiceController.java:417) at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy53.start(Unknown Source) at org.jboss.ejb3.JmxKernelAbstraction.install(JmxKernelAbstraction.java:120) at org.jboss.ejb3.Ejb3Deployment.registerEJBContainer(Ejb3Deployment.java:301) at org.jboss.ejb3.Ejb3Deployment.start(Ejb3Deployment.java:362) at org.jboss.ejb3.Ejb3Module.startService(Ejb3Module.java:91) at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289) at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978) at $Proxy0.start(Unknown Source) at org.jboss.system.ServiceController.start(ServiceController.java:417) at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy33.start(Unknown Source) at org.jboss.ejb3.EJB3Deployer.start(EJB3Deployer.java:512) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:97) at org.jboss.system.InterceptorServiceMBeanSupport.invokeNext(InterceptorServiceMBeanSupport.java:238) at org.jboss.wsf.container.jboss42.DeployerInterceptor.start(DeployerInterceptor.java:87) at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.start(SubDeployerInterceptorSupport.java:188) at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterceptor.java:95) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy34.start(Unknown Source) at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025) at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1015) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782) at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy9.deploy(Unknown Source) at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421) at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:634) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263) at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:336) at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289) at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978) at $Proxy0.start(Unknown Source) at org.jboss.system.ServiceController.start(ServiceController.java:417) at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy4.start(Unknown Source) at org.jboss.deployment.SARDeployer.start(SARDeployer.java:304) at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:766) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy5.deploy(Unknown Source) at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:482) at org.jboss.system.server.ServerImpl.start(ServerImpl.java:362) at org.jboss.Main.boot(Main.java:200) at org.jboss.Main$1.run(Main.java:508) at java.lang.Thread.run(Thread.java:595)

    Read the article

  • OpenCV Mat creation memory leak

    - by Royi Freifeld
    My memory is getting full fairly quick once using the next piece of code. Valgrind shows a memory leak, but everything is allocated on stack and (supposed to be) freed once the function ends. void mult_run_time(int rows, int cols) { Mat matrix(rows,cols,CV_32SC1); Mat row_vec(cols,1,CV_32SC1); /* initialize vector and matrix */ for (int col = 0; col < cols; ++col) { for (int row = 0; row < rows; ++row) { matrix.at<unsigned long>(row,col) = rand() % ULONG_MAX; } row_vec.at<unsigned long>(1,col) = rand() % ULONG_MAX; } /* end initialization of vector and matrix*/ matrix*row_vec; } int main() { for (int row = 0; row < 20; ++row) { for (int col = 0; col < 20; ++col) { mult_run_time(row,col); } } return 0; } Valgrind shows that there is a memory leak in line Mat row_vec(cols,1,CV_32CS1): ==9201== 24,320 bytes in 380 blocks are definitely lost in loss record 50 of 50 ==9201== at 0x4026864: malloc (vg_replace_malloc.c:236) ==9201== by 0x40C0A8B: cv::fastMalloc(unsigned int) (in /usr/local/lib/libopencv_core.so.2.3.1) ==9201== by 0x41914E3: cv::Mat::create(int, int const*, int) (in /usr/local/lib/libopencv_core.so.2.3.1) ==9201== by 0x8048BE4: cv::Mat::create(int, int, int) (mat.hpp:368) ==9201== by 0x8048B2A: cv::Mat::Mat(int, int, int) (mat.hpp:68) ==9201== by 0x80488B0: mult_run_time(int, int) (mat_by_vec_mult.cpp:26) ==9201== by 0x80489F5: main (mat_by_vec_mult.cpp:59) Is it a known bug in OpenCV or am I missing something?

    Read the article

  • Facebook event creation through iPhone app and Facebook Connect

    - by miorel
    How is this done? Is it even possible? All the function calls seem correct, but the result is always false: NSString *event = @"{\"name\":\"A party\",\"start_time\":\"1215929160\",\"end_time\":\"1215929160\",\"location\":\"Somewhere\"}"; NSDictionary *params = [NSDictionary dictionaryWithObject:event forKey:@"event_info"]; [[FBRequest requestWithDelegate:self] call:@"facebook.events.create" params:params];

    Read the article

  • Blob container creation exception ...

    - by Egon
    I get an exception every time I try to create a container for the blob using the following code blobStorageType = storageAccInfo.CreateCloudBlobClient(); ContBlob = blobStorageType.GetContainerReference(containerName); //everything fine till here ; next line creates an exception ContBlob.CreateIfNotExist(); Microsoft.WindowsAzure.StorageClient.StorageClientException was unhandled Message="One of the request inputs is out of range." Source="Microsoft.WindowsAzure.StorageClient" StackTrace: at Microsoft.WindowsAzure.StorageClient.Tasks.Task1.get_Result() at Microsoft.WindowsAzure.StorageClient.Tasks.Task1.ExecuteAndWait() at Microsoft.WindowsAzure.StorageClient.TaskImplHelper.ExecuteImplWithRetry[T](Func2 impl, RetryPolicy policy) at Microsoft.WindowsAzure.StorageClient.CloudBlobContainer.CreateIfNotExist(BlobRequestOptions options) at Microsoft.WindowsAzure.StorageClient.CloudBlobContainer.CreateIfNotExist() at WebRole1.BlobFun..ctor() in C:\Users\cloud\Documents\Visual Studio 2008\Projects\CloudBlob\WebRole1\BlobFun.cs:line 58 at WebRole1.BlobFun.calling1() in C:\Users\cloud\Documents\Visual Studio 2008\Projects\CloudBlob\WebRole1\BlobFun.cs:line 29 at AzureBlobTester.Program.Main(String[] args) in C:\Users\cloud\Documents\Visual Studio 2008\Projects\CloudBlob\AzureBlobTester\Program.cs:line 19 at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args) at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args) at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart() InnerException: System.Net.WebException Message="The remote server returned an error: (400) Bad Request." Source="System" StackTrace: at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at Microsoft.WindowsAzure.StorageClient.EventHelper.ProcessWebResponse(WebRequest req, IAsyncResult asyncResult, EventHandler1 handler, Object sender) InnerException: Do you guys knw what is it that I am doing wrong ?

    Read the article

  • Web application creation in IIS7 via MS.Web.Admin

    - by Jon Ownbey
    I am attempting to create seperate workflow instances as applications in IIS7 using the Microsoft.Web.Administration dll. When it attempts to add the Application to the Site ApplicationsCollection I get a COM error: "Invalid application path\r\n" using (ServerManager manager = new ServerManager()) { var site = manager.Sites.Where(x => x.Name == Properties.Settings.Default.WorkflowWebsiteName).Single(); StringBuilder stringBuilder = new StringBuilder() .Append(m_workflowDefinition.AccountId) .Append("/") .Append(m_workflowDefinition.WorkflowDefinitionId) .Append("/") .Append(m_workflowDefinition.Version) .Append("/"); string virtualPath = stringBuilder.ToString(); string physicalPath = Properties.Settings.Default.ApplicationPoolString + virtualPath.Replace("/", "\\"); if (!Directory.Exists(physicalPath)) Directory.CreateDirectory(physicalPath); //Create the workflow service definition file using (StreamWriter writer = new StreamWriter(Path.Combine(physicalPath, m_workflowDefinition.WorkflowName + WORKFLOW_FILE_EXTENSION))) { writer.Write(m_workflowDefinition.Definition); } //Copy dependencies string dependencyPath = m_workflowDefinition.DependenciesPath; CopyAll(new DirectoryInfo(dependencyPath), new DirectoryInfo(physicalPath)); //Create a new IIS application for the workflow var apps = site.Applications.Where(x => x.Path == virtualPath); if (apps.Count() > 0) { site.Applications.Remove(apps.Single()); } Application app = site.Applications.Add(virtualPath, physicalPath); app.ApplicationPoolName = "Workflow AppPool"; app.EnabledProtocols = PROTOCOLS; manager.CommitChanges(); } The value assigned to virtualPath is like: "something/something/something" and for physicalPath it is "c:\inetpub\wwwroot\Workflow\something\something\something". Any ideas? Any help is greatly appreciated.

    Read the article

  • How to change the datasource on a YUI datagrid after creation

    - by Simon
    I am using the Yahoo DataTable for which the API is here. I am having difficulty changing the data once I have rendered the grid once. I am using jQuery to get data via AJAX, or from a client side data island and need to put this back into the grid. There is no setDataSource method in the DataTable API, and changing 'dataSource.liveData' does not update the grid. // does not work dataTable.dataSource.liveData = [ {name:"cat"}, {name:"dog"}, {name:"mouse"}; The example I am basing my code on is the basic LocalDataSource example. How can I update the data source without having to completely recreate the table. I do NOT want to use the YUI datasources that make Async calls. I need to know how I can do this 'manually'.

    Read the article

  • OpenGL ES 2.0 FBO creation goes wrong with unknown error

    - by Nick
    Hey guys, I've been struggling with this for a while now, and this code crashes with, to me, unknown reasons. I'm creating an FBO, binding a texture, and then the very first glDrawArrays() crashes with a "EXC_BAD_ACCESS" on my iPhone Simulator. Here's the code I use to create the FBO (and bind texture and...) glGenFramebuffers(1, &lastFrameBuffer); glGenRenderbuffers(1, &lastFrameDepthBuffer); glGenTextures(1, &lastFrameTexture); glBindTexture(GL_TEXTURE1, lastFrameTexture); glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, 768, 1029, 0, GL_RGBA, GL_UNSIGNED_SHORT_5_6_5, NULL); glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); //Bind/alloc depthbuf glBindRenderbuffer(GL_RENDERBUFFER, lastFrameDepthBuffer); glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT16, 768, 1029); glBindFramebuffer(GL_FRAMEBUFFER, lastFrameBuffer); //binding the texture to the FBO :D glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, lastFrameTexture, 0); // attach the renderbuffer to depth attachment point glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, lastFrameDepthBuffer); [self checkFramebufferStatus]; As you can see this takes part in an object, checkFrameBufferStatus looks like this: GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER); switch(status) { case GL_FRAMEBUFFER_COMPLETE: JNLogString(@"Framebuffer complete."); return TRUE; case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT: JNLogString(@"[ERROR] Framebuffer incomplete: Attachment is NOT complete."); return false; case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: JNLogString(@"[ERROR] Framebuffer incomplete: No image is attached to FBO."); return false; case GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS: JNLogString(@"[ERROR] Framebuffer incomplete: Attached images have different dimensions."); return false; case GL_FRAMEBUFFER_UNSUPPORTED: JNLogString(@"[ERROR] Unsupported by FBO implementation."); return false; default: JNLogString(@"[ERROR] Unknown error."); return false; JNLogString is just an NSLog, and in this case it gives me: 2010-04-03 02:46:54.854 Bubbleeh[6634:207] ES2Renderer.m:372 [ERROR] Unknown error. When I call it right there. So, it crashes, and diagnostic tells me there's an unknown error and I'm kinda stuck. I basically copied the code from the OpenGL ES 2.0 Programming Guide... What am I doing wrong? Thanks in Advance,

    Read the article

  • Resources for rails widget creation

    - by Kenji Crosland
    My rails app is about to go live and I'm trying to figure out how to create a widget based on data on the site. My Javascript is not too hot--limited to the O'reilly head first book on JS. I can read simple Javascript okay but when it comes to writing it I'm a little lost. That said, I hope to roll out a widget, maybe a wordpress plugin too soon after my app is launched. Does anyone know of any rails plugins, javascript templates, tutorials or books that can get me going? I did ask a similar question before here: But my limited knowledge of JS kept me from implementing the suggested answer properly.

    Read the article

  • JNLP desktop shortcut creation with Windows 7 : "cannot create shortcut"

    - by Touko
    Hi, we have an Java application deployed with Java Web Start (JNLP) that does a desktop shortcut. One client has issue with Windows 7 : in the end of startup/installation there is a message "cannot create shortcut". With our own Windows 7 machine we don't have problems and unfortunately we don't have much details yet. But if somebody has encountered similar issue or has some ideas to try, they are welcome =) Java version used at the client is 6u18. Br, Touko

    Read the article

  • Unity and Object Creation

    - by William
    I am using unity as my IoC container. I am trying to implement a type of IProviderRepository. The concrete implementation has a constructor that accepts a type of IRepository. When I remove the constructor parameter from the concrete implementation everything works fine. I am sure the container is wired correctly. When I try to create the concrete object with the constructor I receive the following error: "The current build operation (build key Build Key[EMRGen.Infrastructure.Data.IRepository1[EMRGen.Model.Provider.Provider], null]) failed: The current type, EMRGen.Infrastructure.Data.IRepository1[EMRGen.Model.Provider.Provider], is an interface and cannot be constructed. Are you missing a type mapping? (Strategy type BuildPlanStrategy, index 3)". Is it possible to achieve the above mention functionality with Unity? Namely have Unity infer a concrete type from the Interface and also inject the constructor of the concrete type with the appropriate concrete object based on constructor parameters. Below is sample of my types defined in Unity and a skeleton class listing for what I want to achieve. IProviderRepository is implemented by ProviderRepository which has a constructor that expects a type of IRepository. <typeAlias alias="ProviderRepositoryInterface" type="EMRGen.Model.Provider.IProviderRepository, EMRGen.Model" /> <typeAlias alias="ProviderRepositoryConcrete" type="EMRGen.Infrastructure.Repositories.Providers.ProviderRepository, EMRGen.Infrastructure.Repositories" /> <typeAlias alias="ProviderGenericRepositoryInterface" type="EMRGen.Infrastructure.Data.IRepository`1[[EMRGen.Model.Provider.IProvider, EMRGen.Model]], EMRGen.Infrastructure" /> <typeAlias alias="ProviderGenericRepositoryConcrete" type="EMRGen.Infrastructure.Repositories.EntityFramework.ApplicationRepository`1[[EMRGen.Model.Provider.Provider, EMRGen.Model]], EMRGen.Infrastructure.Repositories" /> <!-- Provider Mapping--> <typeAlias alias="ProviderInterface" type="EMRGen.Model.Provider.IProvider, EMRGen.Model" /> <typeAlias alias="ProviderConcrete" type="EMRGen.Model.Provider.Doctor, EMRGen.Model" /> //Illustrate the call being made inside my class public class PrescriptionService { PrescriptionService() { IUnityContainer uc = UnitySingleton.Instance.Container; UnityServiceLocator unityServiceLocator = new UnityServiceLocator(uc); ServiceLocator.SetLocatorProvider(() => unityServiceLocator); IProviderRepository pRepository = ServiceLocator.Current.GetInstance<IProviderRepository>(); } } public class GenericRepository<IProvider> : IRepository<IProvider> { } public class ProviderRepository : IProviderRepository { private IRepository<IProvider> _genericProviderRepository; //Explict public default constructor public ProviderRepository(IRepository<IProvider> genericProviderRepository) { _genericProviderRepository = genericProviderRepository; } }

    Read the article

  • Problem with creation of scheduled task from IIS6 on SR2003

    - by Morten Louw Nielsen
    Hi, I am writing a webapplication using .NET. The webapp creates scheduled tasks using the System.Diagnostics.Process class, calling SCHTASKS.EXE with parameters. I have changed the identity on the app pool, to a specific domain user. The domain-user is local administrator on all the four webservers. From webserver01 I am creating tasks on webserver01 to webserver04. It works perfect for 3-5 days, but then it breaks. It gives me the following errormessage in a messagebox: "The application failed to initialize properly (0xc0000142). Click on OK to terminate the application." If I have the system in the broken state, and I change the identity of the app pool to Domain administrator, it works. As I change it back to my domain-user, it breaks again. If I reboot the server, it works again for the same amount of days, but will break again. It seems like a permission-related problem. I just don't understand why it works sometimes, and sometimes doesn't. I hope someone outthere has seen this problem! Looking forward to hear from you! Kind regards, Morten, Denmark

    Read the article

  • JMS ConnectionFactory creation error WSVR0073W

    - by scottyab
    I must confess I’m not a JMS aficionado, one of our guys has written a Java webservice client [postcode lookup web service] and from a Remote Java client are calling a Message Driven Bean running in Websphere 6.1, using JMS. Getting the following error when attempted to create the Connection Factory. To which configured within Websphere jms/WSProxyQueueConnectionFactory. WARNING: WSVR0073W. Googling WSVR0073W yields little, the error code is an unknown error. Can anyone shed any light on potential issues creating the connection factory. Code Hashtable env = new Hashtable(); env.put(Context.INITIAL_CONTEXT_FACTORY, contextFactoryName); env.put(Context.PROVIDER_URL, providerURL); env.put("com.ibm.CORBA.ORBInit","com.ibm.ws.sib.client.ORB"); namingContext = new InitialContext(env); System.out.println("callRemoteService: get connectionFactoriy, request/response queues, session. Naming contex env =" + env); // Find everything we need to communicate... connectionFactory = (QueueConnectionFactory) namingContext.lookup(getQueueConnectionFactoryName()); requestQueue = (Queue) namingContext.lookup(getRequestQueueName()); Console output: calling RemoteService with hostname[MyServer:2813] and postcode[M4E 3W1]callRemoteService hostname[MyServer:2813] messess text[M4E 3W1] callRemoteService: get connectionFactoriy, request/response queues, session. Naming contex env ={com.ibm.CORBA.ORBInit=com.ibm.ws.sib.client.ORB, java.naming.provider.url=iiop:// MyServer:2813/, java.naming.factory.initial=com.ibm.websphere.naming.WsnInitialContextFactory} 05-Jan-2011 13:51:04 null null WARNING: WSVR0073W 05-Jan-2011 13:51:05 null null WARNING: jndiGetObjInstErr 05-Jan-2011 13:51:05 null null WARNING: jndiNamingException callRemoteService: closing connections and resources com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.NoClassDefFoundError: Invalid Implementation Key, com.ibm.ws.transaction.NonRecovWSTxManager] at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:1000) at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:705) at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:2097) at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1951) at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1866) at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1556) at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1358) at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:172) at javax.naming.InitialContext.lookup(InitialContext.java:450) at com.das.jms.clients.BaseWSProxyClient.callRemoteService(BaseWSProxyClient.java:180) at com.das.jms.clients.RemotePostCodeLookup.findAddress(RemotePostCodeLookup.java:38) at com.das.jms.RemoteServiceAccess.findAddress(RemoteServiceAccess.java:80) at com.das.jms.TestRemoteAccess.testSuccessLookup(TestRemoteAccess.java:20) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:599) at junit.framework.TestCase.runTest(TestCase.java:168) at junit.framework.TestCase.runBare(TestCase.java:134) at junit.framework.TestResult$1.protect(TestResult.java:110) at junit.framework.TestResult.runProtected(TestResult.java:128) at junit.framework.TestResult.run(TestResult.java:113) at junit.framework.TestCase.run(TestCase.java:124) at junit.framework.TestSuite.runTest(TestSuite.java:232) at junit.framework.TestSuite.run(TestSuite.java:227) at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:76) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:45) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.NoClassDefFoundError: Invalid Implementation Key, com.ibm.ws.transaction.NonRecovWSTxManager] [[B@4d794d79 at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196) Caused by: java.lang.NoClassDefFoundError: Invalid Implementation Key, com.ibm.ws.transaction.NonRecovWSTxManager at com.ibm.ws.Transaction.TransactionManagerFactory.getUOWCurrent(TransactionManagerFactory.java:125) at com.ibm.ws.rsadapter.AdapterUtil.<clinit>(AdapterUtil.java:271) at java.lang.J9VMInternals.initializeImpl(Native Method) at java.lang.J9VMInternals.initialize(J9VMInternals.java:200) at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:281) at javax.naming.spi.NamingManager.getObjectInstanceByFactoryInReference(NamingManager.java:480) at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:345) at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:896) ... 31 more

    Read the article

  • Windows Azure: Creation of a file on cloud blob container

    - by veda
    I am writing a program that will be executing on the cloud. The program will generate an output that should be written on to a file and the file should be saved on the blob container. I don't have a idea of how to do that Will this code FileStream fs = new FileStream(file, FileMode.Create); StreamWriter sw = new StreamWriter(fs); generate a file named "file" on the cloud...

    Read the article

  • adjacency list creation , out of Memory error

    - by p1
    Hello , I am trying to create an adjacency list to store a graph.The implementation works fine while storing 100,000 records. However,when I tried to store around 1million records I ran into OutofMemory Error : Exception in thread "main" java.lang.OutOfMemoryError: Java heap space at java.util.Arrays.copyOfRange(Arrays.java:3209) at java.lang.String.(String.java:215) at java.io.BufferedReader.readLine(BufferedReader.java:331) at java.io.BufferedReader.readLine(BufferedReader.java:362) at liarliar.main(liarliar.java:39) Following is my implementation HashMap<String,ArrayList<String>> adj = new HashMap<String,ArrayList<String>>(num); while ((str = in.readLine()) != null) { StringTokenizer Tok = new StringTokenizer(str); name = (String) Tok.nextElement(); cnt = Integer.valueOf(Tok.nextToken()); ArrayList<String> templist = new ArrayList<String>(cnt); while(cnt>0) { templist.add(in.readLine()); cnt--; } adj.put(name,templist); } //done creating a adjacency list I am wondering, if there is any better way to implement the adjacency list. Also, I know number of nodes right in the begining and , in the future I flatten the list as I visit nodes. Any suggestions ? Thanks

    Read the article

  • Compile-time lookup array creation for ANSI-C?

    - by multiproximus
    A previous programmer preferred to generate large lookup tables (arrays of constants) to save runtime CPU cycles rather than calculating values on the fly. He did this by creating custom Visual C++ projects that were unique for each individual lookup table... which generate array files that are then #included into a completely separate ANSI-C micro-controller (Renesas) project. This approach is fine for his original calculation assumptions, but has become tedious when the input parameters need to be modified, requiring me to recompile all of the Visual C++ projects and re-import those files into the ANSI-C project. What I would like to do is port the Visual C++ source directly into the ANSI-C microcontroller project and let the compiler create the array tables. So, my question is: Can ANSI-C compilers compute and generate lookup arrays during compile time? And if so, how should I go about it? Thanks in advance for your help!

    Read the article

  • Package creation issues using SQL Developer

    - by Carter
    So I've never worked with stored procedures and have not a whole lot of DB experience in general and I've been assigned a task that requires I create a package and I'm stuck. Using SQL Developer, I'm trying to create a package called JUMPTO with this code... create or replace package JUMPTO is type t_locations is ref cursor; procedure procGetLocations(locations out t_locations); end JUMPTO; When I run it, it spits out this PL/SQL code block... DECLARE LOCATIONS APPLICATION.JUMPTO.t_locations; BEGIN JUMPTO.PROCGET_LOCATIONS( LOCATIONS = LOCATIONS ); -- Modify the code to output the variable -- DBMS_OUTPUT.PUT_LINE('LOCATIONS = ' || LOCATIONS); END; A tutorial I found said to take out the comment for that second line there. I've tried with and without the comment. When I hit "ok" I get the error... ORA-06550: line 2, column 32: PLS-00302: component 'JUMPTO' must be declared ORA-06550: line 2, column 13: PL/SQL: item ignored ORA-06550: line 6, column 18: PLS-00320: the declaration of the type of this expression is incomplete or malformed ORA-06550: line 5, column 3: PL/SQL: Statement ignored ORA-06512: at line 58 I really don't have any idea what's going on, this is all completely new territory for me. I tried creating a body that just selected some stuff from the database but nothing is working the way it seems like it should in my head. Can anyone give me any insight into this?

    Read the article

  • MATLAB: vectorized array creation from a list of start/end indices

    - by merv
    I have a two-column matrix M that contains the start/end indices of a bunch of intervals: startInd EndInd 1 3 6 10 12 12 15 16 How can I generate a vector of all the interval indices: v = [1 2 3 6 7 8 9 10 12 15 16]; I'm doing the above using loops, but I'm wondering if there's a more elegant vectorized solution? v = []; for i=1:size(M,1) v = [v M(i,1):M(i,2)]; end

    Read the article

  • php.ini file creation in server

    - by tibin mathew
    Hi, I am developing a php website. I cant see php.ini file in my server. my host will not provide it. So i'm now going to create a copy of that php.ini file. so i have tried system() i searched in google and i got this link. http://drupal.org/node/290592 Here they are using like this system("cp /usr/local/php5/lib/php.ini /home/YOURUSERNAME/php.ini"); in my server when i looked the phpinfo my php.ini location is /ms/svc/php5/conf/php.ini and when i looked for the current directory of my server using this $dir_path = str_replace( $_SERVER['DOCUMENT_ROOT'], "", dirname(realpath(FILE)) ) . DIRECTORY_SEPARATOR; i got my current directory as /netapp/whnas-swamp/s11/s11/01712/www.sample.com/webdocs/ so my system command will now look lke this system("/ms/svc/php5/conf/php.ini /netapp/whnas-swamp/s11/s11/01712/www.sample.com/webdocs/php.ini"); i have named this page as getthephpini.php and when i b rowse this page i got a blank page but no new php.ini file created in my server. Is any mistake in that code??? Can any one show me the correct way Please help me Thanks

    Read the article

  • Nested forms and automatic creation of parent, children

    - by Karen
    Guys, I was wondering if it was possible to create new parent, children in a has many relationship, using rails nested forms. Rails documentation clearly says that this works in a one to one relationship. Not sure if its the same in has many relationship. For example: If params = { :employee => { :name => "Tester", :account_attributes => {:login => 'tester'} } } works as one to one relationship. So Employee.new(params) works fine. New employee, account are created. Supposing I had params = { :employee => { :name => "Tester", :account_attributes => { "0" => {:login => 'tester'}, "1" => {:login => 'tester2'} } } } Employee.new(params) doesnt work. It fails on child validations saying parent cant be blank. Any help is appreciated. Thanks Karen

    Read the article

< Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >