Search Results

Search found 35 results on 2 pages for 'tamas ionut'.

Page 1/2 | 1 2  | Next Page >

  • Wammu, Samsung J700 error GetNextMemory code: 56

    - by Tamas
    I have got a (old) Samsung J700i. When connecting with a USB cabel to Wammu first the access was denied. Now it is oké... However, when I try to get info out from the phone... I get error message: Error whlie communicating with phone Desciption: Internal phone error. Function: GetNextMemory Error code: 56 I am using Ubuntu 12.04 and Wammu 0.36 Running on Python 2.7.3 Using wxPython 2.8.12.1 Using python-gammu 1.31.0 and Gammu 1.31.0 How may I access data on the phone? Thanks, Tamas

    Read the article

  • Static objects and concurrency in a web application

    - by Ionut
    I'm developing small Java Web Applications on Tomcat server and I'm using MySQL as my database. Up until now I was using a connection singleton for accessing the database but I found out that this will ensure just on connection per Application and there will be problems if multiple users want to access the database in the same time. (They all have to make us of that single Connection object). I created a Connection Pool and I hope that this is the correct way of doing things. Furthermore it seems that I developed the bad habit of creating a lot of static object and static methods (mainly because I was under the wrong impression that every static object will be duplicated for every client which accesses my application). Because of this all the Service Classes ( classes used to handle database data) are static and distributed through a ServiceFactory: public class ServiceFactory { private static final String JDBC = "JDBC"; private static String impl; private static AccountService accountService; private static BoardService boardService; public static AccountService getAccountService(){ initConfig(); if (accountService == null){ if (impl.equalsIgnoreCase(JDBC)){ accountService = new JDBCAccountService(); } } return accountService; } public static BoardService getBoardService(){ initConfig(); if (boardService == null){ if (impl.equalsIgnoreCase(JDBC)){ boardService = new JDBCBoardService(); } } return boardService; } private static void initConfig(){ if (StringUtil.isEmpty(impl)){ impl = ConfigUtil.getProperty("service.implementation"); // If the config failed initialize with standard if (StringUtil.isEmpty(impl)){ impl = JDBC; } } } This was the factory class which, as you can see, allows just one Service to exist at any time. Now, is this a bad practice? What happens if let's say 1k users access AccountService simultaneously? I know that all this questions and bad practices come from a bad understanding of the static attribute in a web application and the way the server handles this attributes. Any help on this topic would be more than welcomed. Thank you for your time!

    Read the article

  • Splitting big request in multiple small ajax requests

    - by Ionut
    I am unsure regarding the scalability of the following model. I have no experience at all with large systems, big number of requests and so on but I'm trying to build some features considering scalability first. In my scenario there is a user page which contains data for: User's details (name, location, workplace ...) User's activity (blog posts, comments...) User statistics (rating, number of friends...) In order to show all this on the same page, for a request there will be at least 3 different database queries on the back-end. In some cases, I imagine that those queries will be running quite a wile, therefore the user experience may suffer while waiting between requests. This is why I decided to run only step 1 (User's details) as a normal request. After the response is received, two ajax requests are sent for steps 2 and 3. When those responses are received, I only place the data in the destined wrappers. For me at least this makes more sense. However there are 3 requests instead of one for every user page view. Will this affect the system on the long term? I'm assuming that this kind of approach requires more resources but is this trade of UX for resources a good dial or should I stick to one plain big request?

    Read the article

  • How to deal with tautology in comments?

    - by Tamás Szelei
    Sometimes I find myself in situations when the part of code that I am writing is (or seems to be) so self-evident that its name would be basically repeated as a comment: class Example { /// <summary> /// The location of the update. /// </summary> public Uri UpdateLocation { get; set; }; } (C# example, but please refer to the question as language-agnostic). A comment like that is useless; what am I doing wrong? Is it the choice of the name that is wrong? How could I comment parts like this better? Should I just skip the comment for things like this?

    Read the article

  • Session serialization in JavaEE environment

    - by Ionut
    Please consider the following scenario: We are working on a JavaEE project for which the scalability starts to become an issue. Up until now, we were able to scale up but this is no longer an option. Therefore we need to consider scaling out and preparing the App for a clustered environment. Our main concern right now is serializing the user sessions. Sadly, we did not consider from the beginning the issue and we are encountering the following excetion: java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.apache.catalina.session.StandardSessionFacade I did some research and this exception is thrown because there are objects stored on the session which does not implement the Serializable interface. Considering that all over the app there are quite a few custom objects which are stored on the session without implementing this interface, it would require a lot of tedious work and dedication to fix all these classes declaration. We will fix all this declarations but the main concern is that, in the future, there may be a developer which will add a non Serializable object on the session and break the session serialization & replication over multiple nodes. As a quick overview of the project, we are developing using a home grown framework based on Struts 1 with the Servlet 3.0 API. This means that at this point, we are using the standard session.getAttribute() and session.setAttribute() to work with the session and the session handling is scattered all over the code base. Besides updating the classes of the objects stored on session and making sure that they implement the Serializable interface, what other measures of precaution should we take in order to ensure a reliable Session replication capability on the Application layer? I know it is a little bit late to consider this but what would be the best practice in this case? Furthermore, are there any other issues we should consider regarding this transition? Thank you in advance!

    Read the article

  • Is it better to build HTML Code string on the server or on the client side?

    - by Ionut
    The result of the following process should be a html form. This form's structure varies from one to user. For example there might be a different number of rows or there may be the need for rowspan and colspan. When the user chooses to see this table an ajax call is made to the server where the structure of the table is decided from the database. Then I have to create the html code for the table structure which will be inserted in the DOM via JavaScript. The following problem comes to my mind: Where should I build the HTML code which will be inserted in the DOM? On the server side or should I send some parameters in the ajax call method and process the structure there? Therefore the main question involves good practice when it comes to decide between Server side processing or client side processing. Thank you!

    Read the article

  • Complete deployment to AWS

    - by Ionut
    I'm trying to deploy a Java Application to AWS free tier. I need the following: RDS provider. Using MySQL client S3 service. This is required for the Lucene Index and image uploading SES service. I need to be able to send emails to new registered users. Namecheap is my domain provider. EC2 instance Elastic Beanstalk instance. I managed to create an EC2 instance, upload the WAR file and link it to the Namecheap domain. However I find it difficult to link the other instances to the current application. I find the documentation a little messy and I can't find the right way to do this. Can you provide a simple walk through to deployment for this use case? Thanks!

    Read the article

  • Is it a good practice to use branches to maintain different editions of the same software?

    - by Tamás Szelei
    We have a product that has a few different editions. The differences are minor: different strings here and there, very little additional logic in one, very little difference in logic in the other. When the software is being developed, most changes need to be added to each edition; however, there are a few that don't and a few that needs to differ. Is it a valid use of branches if I have release-editionA and release-editionB (..etc) branches? Are there any gotchas? Good practices? Update: Thanks for the insight everyone, lots of good answers here. The general consensus seems to be that it is a bad idea to use branches for this purpose. For anyone wondering, my final solution to the problem is to externalize strings as configuration, and externalize the differing logic as plugins or scripts.

    Read the article

  • Encoding video stream for playback on a vanilla Windows XP with mencoder

    - by Tamás
    I have a bunch of PNG files, generated from a script. They represent consecutive frames of a video sequence and I'd like to encode them into a single AVI file (or some other video format) using mencoder. What parameters should I use to ensure that the video can be viewed on a vanilla Windows XP using Windows Media Player with no extra codecs installed apart from the default ones? So far I've tried -ovc lavc -lavcopts vcodec=wmv2 and -ovc lavc -lavcopts vcodec=msmpeg4 with no success. (Background story: some of the people I'm collaborating with on a scientific project cannot install any codecs on their university computers without the help of the local sysadmins, who are of course not very willing to install anything. I'd like to ensure that they can also view the video files I am creating).

    Read the article

  • Asterisk Connection not working

    - by Tamas Ionut
    I have installed Asterisk on VirtualBox by following the steps from here. Everything went ok until I got to navigate to an IP to configure Asterisk using FreePBX: 10.0.2.15 (Shouldn't be something like 192.168.x.y?? ). However, when I navigated to that url from outside of VirtualBox, that url pointed to nothing. Also I am logged in as root@localhost. Should I be logged in as root@server? I have also validated the installation as described here and everything went well. I am a complete beginner at Asterisk.

    Read the article

  • Good firefox extension to download .flv flash video?

    - by Tamás Szelei
    I'm looking for a decent flash video downloader for Firefox. There are tons of them. I'd like to use it for a custom site with some random flash video player, not Youtube. How can it be accomplished? Edit: None of these methods you guys suggested worked so far; I looked up various places where the temporary file might end up - it just doesn't. It is indeed a flash player, but it seems like it's not caching - is that possible?

    Read the article

  • DNS Server (2008 r2) MMC The server DC01 could not be contacted. The error was: Access was denied

    - by Silviu-Ionut Radu
    I've just migrated the AD with the whole nine yards, FSMO, PDC, RID, Schema, etc, from an SBS 2003 to a Win 2008 R2 Std. I have managed to have no error in the dcdiag before I demoted the SBS 2003 from the AD, fsmocheck, conectivity, advertising, dns, etc. The SBS 2003 demoted successfully. After this step I have restarted both, the old SBS and the new Win 2008 r2. After restart the new DC (which is the GC) started with an Access denied to the DNS Server MMC, actually it is looking like I would try to connect to the 2008 r2 DNS server from an older server console I can NOT manage DNS server through MMC nor through dnscmd (Command failed: ERROR_ACCESS_DENIED 5 0x5) I cannot even use the Action Option from the DNS Server MMC because all the options are DISABLED but for "Launch nslookup". I've made a lot of research on the internet but no luck, yet. So I come to ask for help. Thank you very much.

    Read the article

  • understanding mount -o bind

    - by Ionut
    Few questions after the following commands: mount -o bind /new_disk/home/user/ /home/user/ mount -o bind --no-mtab /new_disk/home/user/ /home/user/ What is the difference between the two commands other than " Mount without writing in /etc/mtab. This is necessary for example when /etc is on a read-only filesystem." What is the difference between mount -o bind and mount --bind ...if there are Let's suppose i don't know there is a partition mounted using -o bind --no-mtab...where can I find if there is any mound point with bind ? The only way i can detect this is grep user /proc/mounts but in that line there is no info abut bind. Thank you.

    Read the article

  • Drawing a clamped uniform cubic B-spline using Cairo

    - by Tamás
    I have a bunch of coordinates which are the control points of a clamped uniform cubic B-spline on the 2D plane. I would like to draw this curve using Cairo calls (in Python, using Cairo's Python bindings), but as far as I know, Cairo supports Bézier curves only. I also know that the segments of a B-spline between two control points can be drawn using Bézier curves, but I can't find the exact formulae anywhere. Given the coordinates of the control points, how can I derive the control points of the corresponding Bézier curves? Is there any efficient algorithm for that?

    Read the article

  • Using @Context, @Provider and ContextResolver in JAX-RS

    - by Tamás
    I'm just getting acquainted with implementing REST web services in Java using JAX-RS and I ran into the following problem. One of my resource classes requires access to a storage backend, which is abstracted away behind a StorageEngine interface. I would like to inject the current StorageEngine instance into the resource class serving the REST requests and I thought a nice way of doing this would be by using the @Context annotation and an appropriate ContextResolver class. This is what I have so far: In MyResource.java: class MyResource { @Context StorageEngine storage; [...] } In StorageEngineProvider.java: @Provider class StorageEngineProvider implements ContextResolver<StorageEngine> { private StorageEngine storage = new InMemoryStorageEngine(); public StorageEngine getContext(Class<?> type) { if (type.equals(StorageEngine.class)) return storage; return null; } } I'm using com.sun.jersey.api.core.PackagesResourceConfig to discover the providers and the resource classes automatically, and according to the logs, it picks up the StorageEngineProvider class nicely (timestamps and unnecessary stuff left out intentionally): INFO: Root resource classes found: class MyResource INFO: Provider classes found: class StorageEngineProvider However, the value of storage in my resource class is always null - neither the constructor of StorageEngineProvider nor its getContext method is called by Jersey, ever. What am I doing wrong here?

    Read the article

  • How do I open a new browser tab?

    - by Ionut Staicu
    Hi guys. I'm working on this project and I have to open a new browser tab. Actually, I have to open a target="_blank" link without the link. I know is not right to interfere with the user preferences, but hey, this is the project requirements. So, long story short, i have to replicate the target="_blank" behavior only with javascript. Is this even possible? Thanks!

    Read the article

  • RESTful API design question - how should one allow users to create new resource instances?

    - by Tamás
    I'm working in a research group where we intend to publish implementations of some of the algorithms we develop on the web via a RESTful API. Most of these algorithms work on small to medium size datasets, and in many cases, a user of our services might want to run multiple queries (with different parameters) on the same dataset, so for me it seems reasonable to allow users to upload their datasets in advance and refer to them in their queries later. In this sense, a dataset could be a resource in my API, and an algorithm could be another. My question is: how should I let the users upload their own datasets? I cannot simply let users upload their data to /dataset/dataset_id as letting the users invent their own dataset_ids might result in ID collision and users overwriting each other's datasets by accident. (I believe one of the most frequently used dataset ID would be test). I think an ideal way would be to have a dedicated URL (like /dataset/upload) where users can POST their datasets and the response would contain a unique ID under which the dataset was stored, but I'm not sure that it does not violate the basic principles of REST. What is the preferred way of dealing with such scenarios?

    Read the article

  • Ipad Magazines App How do they work?

    - by Terente Ionut Alexandru
    How are built the magazines apps? For example Popular Science, Auto Trends and PARIS MATCH I want to build an app like this. But how do these app render the content? How the app knows where is an video, an photo, scroll views and so on? Is there any library to use, and do this easy way or do I need my own engine that renders the content? Is just an webView that loads html5, css and java script or is much more than that?

    Read the article

  • ID/Class Selector

    - by Ionut Staicu
    Hi. I have some kind of problem with jQuery selectors. Let's say i want to select $('#elementID') but the elementID is a variable. There is any other possiblity to do this other way than var variable = elementID; $('#'+variable) ? I mean without specifying the # anywhere else? Thanks!

    Read the article

  • Efficient method to calculate the rank vector of a list in Python

    - by Tamás
    I'm looking for an efficient way to calculate the rank vector of a list in Python, similar to R's rank function. In a simple list with no ties between the elements, element i of the rank vector of a list l should be x if and only if l[i] is the x-th element in the sorted list. This is simple so far, the following code snippet does the trick: def rank_simple(vector): return [rank for rank in sorted(range(n), key=vector.__getitem__)] Things get complicated, however, if the original list has ties (i.e. multiple elements with the same value). In that case, all the elements having the same value should have the same rank, which is the average of their ranks obtained using the naive method above. So, for instance, if I have [1, 2, 3, 3, 3, 4, 5], the naive ranking gives me [0, 1, 2, 3, 4, 5, 6], but what I would like to have is [0, 1, 3, 3, 3, 5, 6]. Which one would be the most efficient way to do this in Python? Footnote: I don't know if NumPy already has a method to achieve this or not; if it does, please let me know, but I would be interested in a pure Python solution anyway as I'm developing a tool which should work without NumPy as well.

    Read the article

  • Calling javascript function from android webview?

    - by Edmond Tamas
    I try to call a javascript function from directly form my application (webview.apk), in order to start a script which would autoplay a html5 video clip, I have tried to add itt right after webview loadURL but wwithout luck. Maybe someone could take a look at the code. What am I missing? Thanks! package tscolari.mobile_sample; import android.app.Activity; import android.os.Bundle; import android.view.View; import android.webkit.WebSettings; import android.webkit.WebView; import android.webkit.WebViewClient; import android.webkit.WebChromeClient; import android.media.MediaPlayer; public class InfoSpotActivity extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); WebView mainWebView = (WebView) findViewById(R.id.mainWebView); WebSettings webSettings = mainWebView.getSettings(); webSettings.setJavaScriptEnabled(true); mainWebView.setWebChromeClient(new WebChromeClient()); mainWebView.setWebViewClient(new MyCustomWebViewClient()); mainWebView.setScrollBarStyle(View.SCROLLBARS_INSIDE_OVERLAY); mainWebView.loadUrl("http://server.info-spot.net"); mainWebView.loadUrl("javascript:playVideo()"); } private class MyCustomWebViewClient extends WebViewClient { @Override public boolean shouldOverrideUrlLoading(WebView view, String url) { view.loadUrl(url); return true; } } }

    Read the article

  • Strange problems with PHP SOAP (private variable not persist + variables passed from client not work

    - by Tamas Gal
    I have a very strange problems in a PHP Soap implementation. I have a private variable in the Server class which contains the DB name for further reference. The private variable name is "fromdb". I have a public function on the soap server where I can set this variable. $client-setFromdb. When I call it form my client works perfectly and the fromdb private variable can be set. But a second soap client call this private variable loses its value... Here is my soap server setup: ini_set('soap.wsdl_cache_enabled', 0); ini_set('session.auto_start', 0); ini_set('always_populate_raw_post_data', 1); global $config_dir; session_start(); /*if(!$HTTP_RAW_POST_DATA){ $HTTP_RAW_POST_DATA = file_get_contents('php://input'); }*/ $server = new SoapServer("{$config_dir['template']}import.wsdl"); $server-setClass('import'); $server-setPersistence(SOAP_PERSISTENCE_SESSION); $server-handle(); Problem is that I passed this to the server: $client = new SoapClient('http://import.ingatlan.net/wsdl', array('trace' = 1)); $xml=''; $xml.=''; $xml.=''; $xml.=''; $xml.='Valaki'; $xml.=''; $xml.=''; $xml.=''; $xml.=''; $tarray = array("type" = 1, "xml" = $xml); try{ $s = $client-sendXml( $tarray ); print "$s"; } catch( SOAPFault $exception){ print "--- SOAP exception :{$exception}---"; print "LAST REQUEST :"; var_dump($client-_getLastRequest()); print "---"; print "LAST RESPONSE :".$client-_getLastResponse(); } So passed an Array of informations to the server. Then I got this exception: LAST REQUEST : <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Body><type>Array</type><xml/></SOAP-ENV:Body></SOAP-ENV:Envelope> Can you see the Array word between the type tag? Seems that the client only passed a reference or something like this. So I totaly missed :(

    Read the article

1 2  | Next Page >