Search Results

Search found 879 results on 36 pages for 'c dragon 76'.

Page 20/36 | < Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >

  • T-SQL (SCD) Slowly Changing Dimension Type 2 using a merge statement

    - by AtulThakor
    Working on stored procedure recently which loads records into a data warehouse I found that the existing record was being expired using an update statement followed by an insert to add the new active record. Playing around with the merge statement you can actually expire the current record and insert a new record within one clean statement. This is how the statement works, we do the normal merge statement to insert a record when there is no match, if we match the record we update the existing record by expiring it and deactivating. At the end of the merge statement we use the output statement to output the staging values for the update,  we wrap the whole merge statement within an insert statement and add new rows for the records which we inserted. I’ve added the full script at the bottom so you can paste it and play around.   1: INSERT INTO ExampleFactUpdate 2: (PolicyID, 3: Status) 4: SELECT -- these columns are returned from the output statement 5: PolicyID, 6: Status 7: FROM 8: ( 9: -- merge statement on unique id in this case Policy_ID 10: MERGE dbo.ExampleFactUpdate dp 11: USING dbo.ExampleStag s 12: ON dp.PolicyID = s.PolicyID 13: WHEN NOT MATCHED THEN -- when we cant match the record we insert a new record record and this is all that happens 14: INSERT (PolicyID,Status) 15: VALUES (s.PolicyID, s.Status) 16: WHEN MATCHED --if it already exists 17: AND ExpiryDate IS NULL -- and the Expiry Date is null 18: THEN 19: UPDATE 20: SET 21: dp.ExpiryDate = getdate(), --we set the expiry on the existing record 22: dp.Active = 0 -- and deactivate the existing record 23: OUTPUT $Action MergeAction, s.PolicyID, s.Status -- the output statement returns a merge action which can 24: ) MergeOutput -- be insert/update/delete, on our example where a record has been updated (or expired in our case 25: WHERE -- we'll filter using a where clause 26: MergeAction = 'Update'; -- here   Complete source for example 1: if OBJECT_ID('ExampleFactUpdate') > 0 2: drop table ExampleFactUpdate 3:  4: Create Table ExampleFactUpdate( 5: ID int identity(1,1), 3: go 6: PolicyID varchar(100), 7: Status varchar(100), 8: EffectiveDate datetime default getdate(), 9: ExpiryDate datetime, 10: Active bit default 1 11: ) 12:  13:  14: insert into ExampleFactUpdate( 15: PolicyID, 16: Status) 17: select 18: 1, 19: 'Live' 20:  21: /*Create Staging Table*/ 22: if OBJECT_ID('ExampleStag') > 0 23: drop table ExampleStag 24: go 25:  26: /*Create example fact table */ 27: Create Table ExampleStag( 28: PolicyID varchar(100), 29: Status varchar(100)) 30:  31: --add some data 32: insert into ExampleStag( 33: PolicyID, 34: Status) 35: select 36: 1, 37: 'Lapsed' 38: union all 39: select 40: 2, 41: 'Quote' 42:  43: select * 44: from ExampleFactUpdate 45:  46: select * 47: from ExampleStag 48:  49:  50: INSERT INTO ExampleFactUpdate 51: (PolicyID, 52: Status) 53: SELECT -- these columns are returned from the output statement 54: PolicyID, 55: Status 56: FROM 57: ( 58: -- merge statement on unique id in this case Policy_ID 59: MERGE dbo.ExampleFactUpdate dp 60: USING dbo.ExampleStag s 61: ON dp.PolicyID = s.PolicyID 62: WHEN NOT MATCHED THEN -- when we cant match the record we insert a new record record and this is all that happens 63: INSERT (PolicyID,Status) 64: VALUES (s.PolicyID, s.Status) 65: WHEN MATCHED --if it already exists 66: AND ExpiryDate IS NULL -- and the Expiry Date is null 67: THEN 68: UPDATE 69: SET 70: dp.ExpiryDate = getdate(), --we set the expiry on the existing record 71: dp.Active = 0 -- and deactivate the existing record 72: OUTPUT $Action MergeAction, s.PolicyID, s.Status -- the output statement returns a merge action which can 73: ) MergeOutput -- be insert/update/delete, on our example where a record has been updated (or expired in our case 74: WHERE -- we'll filter using a where clause 75: MergeAction = 'Update'; -- here 76:  77:  78: select * 79: from ExampleFactUpdate 80: 

    Read the article

  • NHibernate Pitfalls: Custom Types and Detecting Changes

    - by Ricardo Peres
    This is part of a series of posts about NHibernate Pitfalls. See the entire collection here. NHibernate supports the declaration of properties of user-defined types, that is, not entities, collections or primitive types. These are used for mapping a database columns, of any type, into a different type, which may not even be an entity; think, for example, of a custom user type that converts a BLOB column into an Image. User types must implement interface NHibernate.UserTypes.IUserType. This interface specifies an Equals method that is used for comparing two instances of the user type. If this method returns false, the entity is marked as dirty, and, when the session is flushed, will trigger an UPDATE. So, in your custom user type, you must implement this carefully so that it is not mistakenly considered changed. For example, you can cache the original column value inside of it, and compare it with the one in the other instance. Let’s see an example implementation of a custom user type that converts a Byte[] from a BLOB column into an Image: 1: [Serializable] 2: public sealed class ImageUserType : IUserType 3: { 4: private Byte[] data = null; 5: 6: public ImageUserType() 7: { 8: this.ImageFormat = ImageFormat.Png; 9: } 10: 11: public ImageFormat ImageFormat 12: { 13: get; 14: set; 15: } 16: 17: public Boolean IsMutable 18: { 19: get 20: { 21: return (true); 22: } 23: } 24: 25: public Object Assemble(Object cached, Object owner) 26: { 27: return (cached); 28: } 29: 30: public Object DeepCopy(Object value) 31: { 32: return (value); 33: } 34: 35: public Object Disassemble(Object value) 36: { 37: return (value); 38: } 39: 40: public new Boolean Equals(Object x, Object y) 41: { 42: return (Object.Equals(x, y)); 43: } 44: 45: public Int32 GetHashCode(Object x) 46: { 47: return ((x != null) ? x.GetHashCode() : 0); 48: } 49: 50: public override Int32 GetHashCode() 51: { 52: return ((this.data != null) ? this.data.GetHashCode() : 0); 53: } 54: 55: public override Boolean Equals(Object obj) 56: { 57: ImageUserType other = obj as ImageUserType; 58: 59: if (other == null) 60: { 61: return (false); 62: } 63: 64: if (Object.ReferenceEquals(this, other) == true) 65: { 66: return (true); 67: } 68: 69: return (this.data.SequenceEqual(other.data)); 70: } 71: 72: public Object NullSafeGet(IDataReader rs, String[] names, Object owner) 73: { 74: Int32 index = rs.GetOrdinal(names[0]); 75: Byte[] data = rs.GetValue(index) as Byte[]; 76: 77: this.data = data as Byte[]; 78: 79: if (data == null) 80: { 81: return (null); 82: } 83: 84: using (MemoryStream stream = new MemoryStream(this.data ?? new Byte[0])) 85: { 86: return (Image.FromStream(stream)); 87: } 88: } 89: 90: public void NullSafeSet(IDbCommand cmd, Object value, Int32 index) 91: { 92: if (value != null) 93: { 94: Image data = value as Image; 95: 96: using (MemoryStream stream = new MemoryStream()) 97: { 98: data.Save(stream, this.ImageFormat); 99: value = stream.ToArray(); 100: } 101: } 102: 103: (cmd.Parameters[index] as DbParameter).Value = value ?? DBNull.Value; 104: } 105: 106: public Object Replace(Object original, Object target, Object owner) 107: { 108: return (original); 109: } 110: 111: public Type ReturnedType 112: { 113: get 114: { 115: return (typeof(Image)); 116: } 117: } 118: 119: public SqlType[] SqlTypes 120: { 121: get 122: { 123: return (new SqlType[] { new SqlType(DbType.Binary) }); 124: } 125: } 126: } In this case, we need to cache the original Byte[] data because it’s not easy to compare two Image instances, unless, of course, they are the same.

    Read the article

  • trying to setup wireless

    - by JohnMerlino
    I'm trying to set up wireless on vostro 1520 dell laptop, with latest Ubuntu install. Here's the output of some of the commands that I was told to run: lshw -C network viggy@ubuntu:~$ lshw -C network WARNING: you should run this program as super-user. *-network description: Ethernet interface product: RTL8111/8168B PCI Express Gigabit Ethernet controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:08:00.0 logical name: eth0 version: 03 serial: 00:24:e8:da:84:25 size: 100Mbit/s capacity: 1Gbit/s width: 64 bits clock: 33MHz capabilities: bus_master cap_list rom ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=full firmware=rtl_nic/rtl8168d-1.fw ip=192.168.2.6 latency=0 multicast=yes port=MII speed=100Mbit/s resources: irq:47 ioport:3000(size=256) memory:f6004000-f6004fff memory:f6000000-f6003fff memory:f6020000-f603ffff *-network description: Network controller product: BCM4312 802.11b/g LP-PHY vendor: Broadcom Corporation physical id: 0 bus info: pci@0000:0e:00.0 version: 01 width: 64 bits clock: 33MHz capabilities: bus_master cap_list configuration: driver=b43-pci-bridge latency=0 resources: irq:18 memory:fa000000-fa003fff *-network DISABLED description: Wireless interface physical id: 1 logical name: wlan0 serial: 0c:60:76:05:ee:74 capabilities: ethernet physical wireless configuration: broadcast=yes driver=b43 driverversion=3.2.0-29-generic firmware=N/A multicast=yes wireless=IEEE 802.11bg lspci 00:00.0 Host bridge: Intel Corporation Mobile 4 Series Chipset Memory Controller Hub (rev 07) 00:02.0 VGA compatible controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 07) 00:02.1 Display controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 07) 00:1a.0 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #4 (rev 03) 00:1a.1 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #5 (rev 03) 00:1a.2 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #6 (rev 03) 00:1a.7 USB controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #2 (rev 03) 00:1b.0 Audio device: Intel Corporation 82801I (ICH9 Family) HD Audio Controller (rev 03) 00:1c.0 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 1 (rev 03) 00:1c.1 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 2 (rev 03) 00:1c.2 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 3 (rev 03) 00:1c.3 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 4 (rev 03) 00:1c.4 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 5 (rev 03) 00:1c.5 PCI bridge: Intel Corporation 82801I (ICH9 Family) PCI Express Port 6 (rev 03) 00:1d.0 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #1 (rev 03) 00:1d.1 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #2 (rev 03) 00:1d.2 USB controller: Intel Corporation 82801I (ICH9 Family) USB UHCI Controller #3 (rev 03) 00:1d.7 USB controller: Intel Corporation 82801I (ICH9 Family) USB2 EHCI Controller #1 (rev 03) 00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev 93) 00:1f.0 ISA bridge: Intel Corporation ICH9M LPC Interface Controller (rev 03) 00:1f.2 SATA controller: Intel Corporation 82801IBM/IEM (ICH9M/ICH9M-E) 4 port SATA Controller [AHCI mode] (rev 03) 00:1f.3 SMBus: Intel Corporation 82801I (ICH9 Family) SMBus Controller (rev 03) 08:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 03) 0e:00.0 Network controller: Broadcom Corporation BCM4312 802.11b/g LP-PHY (rev 01) 1a:00.0 FireWire (IEEE 1394): O2 Micro, Inc. Device 10f7 (rev 01) 1a:00.1 SD Host controller: O2 Micro, Inc. Device 8120 (rev 01) 1a:00.2 Mass storage controller: O2 Micro, Inc. Device 8130 (rev 01) iwconfig lo no wireless extensions. wlan0 IEEE 802.11bg ESSID:off/any Mode:Managed Access Point: Not-Associated Tx-Power=0 dBm Retry long limit:7 RTS thr:off Fragment thr:off Power Management:on eth0 no wireless extensions. At this point in time, I don't have wireless.

    Read the article

  • Cloud Fact for Business Managers #3: Where You Data Is, and Who Has Access to It Might Surprise You

    - by yaldahhakim
    Written by: David Krauss While data security and operational risk conversations usually happen around the desk of a CCO/CSO (chief compliance and/or security officer), or perhaps the CFO, since business managers are now selecting cloud providers, they need to be able to at least ask some high-level questions on the topic of risk and compliance.  While the report found that 76% of adopters were motivated to adopt cloud apps because of quick access to software, most of these managers found that after they made a purchase decision their access to exciting new capabilities in the cloud could be hindered due to performance and scalability constraints put forth  by their cloud provider.  If you are going to let your business consume their mission critical business applications as a service, then it’s important to understand who is providing those cloud services and what kind of performance you are going to get.  Different types of departments, companies and industries will all have unique requirements so it’s key to take this also into consideration.   Nothing puts a CEO in a bad mood like a public data breach or finding out the company lost money when customers couldn’t buy a product or service because your cloud service provider had a problem.  With 42% of business managers having seen a data security breach in their department associated directly with the use of cloud applications, this is happening more than you think.   We’ve talked about the importance of being able to avoid information silos through a unified cloud approach and platform.  This is also important when keeping your data safe and secure, and a key conversation to have with your cloud provider.  Your customers want to know that their information is protected when they do business with you, just like you want your own company information protected.   This is really hard to do when each line of business is running different cloud application services managed by different cloud providers, all with different processes and controls.   It only adds to the complexity, and the more complex, the more risky and the chance that something will go wrong. What about compliance? Depending on the cloud provider, it can be difficult at best to understand who has access to your data, and were your data is actually stored.  Add to this multiple cloud providers spanning multiple departments and it becomes very problematic when trying to comply with certain industry and country data security regulations.  With 73% of business managers complaining that having cloud data handled externally by one or more cloud vendors makes it hard for their department to be compliant, this is a big time suck for executives and it puts the organization at risk. Is There A Complete, Integrated, Modern Cloud Out there for Business Executives?If you are a business manager looking to drive faster innovation for your business and want a cloud application that your CIO would approve of, I would encourage you take a look at Oracle Cloud.  It’s everything you want from a SaaS based application, but without compromising on functionality and other modern capabilities like embedded business intelligence, social relationship management (for your entire business), and advanced mobile.  And because Oracle Cloud is built and managed by Oracle, you can be confident that your cloud application services are enterprise-grade.  Over 25 Million users and 10 thousands companies around the globe rely on Oracle Cloud application services everyday – maybe your business should too.  For more information, visit cloud.oracle.com. Additional Resources •    Try it: cloud.oracle.com•    Learn more: http://www.oracle.com/us/corporate/features/complete-cloud/index.html•    Research Report: Cloud for Business Managers: The Good, the Bad, and the Ugly

    Read the article

  • Why am I getting: InvalidOperationException: Failed to map the path '/app42/App_Code/'.

    - by serialhobbyist
    I've been working on a little Silverlight utility which calls a Silverlight web service. It works from my dev machine (XPsp2). I've tried publishing it to a 2008 R2 IIS 7.5 server and it doesn't work when trying to contact the web service. So I've tried using the WcfTestClient to connect to the web service. That gave an error. So I turned off CustomErrors and used IE and I get the following. Any idea why? There's no App_Code folder in the app. Failed to map the path '/app42/App_Code/'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.InvalidOperationException: Failed to map the path '/app42/App_Code/'. Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [InvalidOperationException: Failed to map the path '/app42/App_Code/'.] System.Web.Configuration.ProcessHostConfigUtils.MapPathActual(String siteName, VirtualPath path) +320 System.Web.Configuration.ProcessHostServerConfig.System.Web.Configuration.IServerConfig.MapPath(IApplicationHost appHost, VirtualPath path) +34 System.Web.Hosting.MapPathBasedVirtualPathEnumerator..ctor(VirtualPath virtualPath, RequestedEntryType requestedEntryType) +169 System.Web.Hosting.MapPathBasedVirtualPathCollection.System.Collections.IEnumerable.GetEnumerator() +43 System.Web.Compilation.CodeDirectoryCompiler.ProcessDirectoryRecursive(VirtualDirectory vdir, Boolean topLevel) +147 System.Web.Compilation.CodeDirectoryCompiler.GetCodeDirectoryAssembly(VirtualPath virtualDir, CodeDirectoryType dirType, String assemblyName, StringSet excludedSubdirectories, Boolean isDirectoryAllowed) +11196502 System.Web.Compilation.BuildManager.CompileCodeDirectory(VirtualPath virtualDir, CodeDirectoryType dirType, String assemblyName, StringSet excludedSubdirectories) +185 System.Web.Compilation.BuildManager.CompileCodeDirectories() +654 System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +658 [HttpException (0x80004005): Failed to map the path '/app42/App_Code/'.] System.Web.Compilation.BuildManager.ReportTopLevelCompilationException() +76 System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +1012 System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters) +1025 [HttpException (0x80004005): Failed to map the path '/app42/App_Code/'.] System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +11301302 System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +88 System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +4338644 Version Information: Microsoft .NET Framework Version:2.0.50727.4927; ASP.NET Version:2.0.50727.4927

    Read the article

  • Having trouble compiling with GDI+ (VC++ 2008)

    - by user146780
    I just simply include gdiplus.h and get all these errors: Warning 32 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Warning 38 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Warning 49 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Warning 55 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Warning 61 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2224 Warning 68 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Warning 74 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2310 Warning 82 warning C4229: anachronism used : modifiers on data are ignored c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2321 Error 112 fatal error C1003: error count exceeds 100; stopping compilation c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 236 Error 1 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 74 Error 7 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 280 Error 8 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 280 Error 94 error C2761: '{ctor}' : member function redeclaration not allowed c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 195 Error 102 error C2761: '{ctor}' : member function redeclaration not allowed c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 212 Error 110 error C2761: '{ctor}' : member function redeclaration not allowed c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 231 Error 21 error C2535: 'Gdiplus::Metafile::Metafile(void)' : member function already defined or declared c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 813 Error 23 error C2535: 'Gdiplus::Metafile::Metafile(void)' : member function already defined or declared c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 820 Error 25 error C2535: 'Gdiplus::Metafile::Metafile(void)' : member function already defined or declared c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 829 Error 27 error C2535: 'Gdiplus::Metafile::Metafile(void)' : member function already defined or declared c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 923 Error 16 error C2535: 'Gdiplus::Image::Image(void)' : member function already defined or declared c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 471 Error 4 error C2470: 'IImageBytes' : looks like a function definition, but there is no parameter list; skipping apparent body c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 74 Error 89 error C2448: 'Gdiplus::Metafile::{ctor}' : function-style initializer appears to be a function definition c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 76 Error 97 error C2447: '{' : missing function header (old-style formal list?) c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 199 Error 105 error C2447: '{' : missing function header (old-style formal list?) c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 218 Error 2 error C2440: 'initializing' : cannot convert from 'const char [37]' to 'int' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 74 Error 72 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2310 Error 76 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2310 Error 80 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2321 Error 84 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2321 Error 92 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 195 Error 100 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 212 Error 108 error C2275: 'HDC' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 231 Error 60 error C2275: 'Gdiplus::MetafileHeader' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2224 Error 67 error C2275: 'Gdiplus::GpMetafile' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Error 31 error C2275: 'Gdiplus::GpImage' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Error 37 error C2275: 'Gdiplus::GpImage' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Error 48 error C2275: 'Gdiplus::GpBitmap' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Error 54 error C2275: 'Gdiplus::GpBitmap' : illegal use of this type as an expression c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Error 3 error C2146: syntax error : missing ';' before identifier 'IImageBytes' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 74 Error 6 error C2146: syntax error : missing ';' before identifier 'id' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 280 Error 73 error C2146: syntax error : missing ')' before identifier 'referenceHdc' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2310 Error 81 error C2146: syntax error : missing ')' before identifier 'referenceHdc' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2321 Error 93 error C2146: syntax error : missing ')' before identifier 'referenceHdc' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 195 Error 101 error C2146: syntax error : missing ')' before identifier 'referenceHdc' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 212 Error 109 error C2146: syntax error : missing ')' before identifier 'referenceHdc' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 231 Error 96 error C2143: syntax error : missing ';' before '{' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 199 Error 104 error C2143: syntax error : missing ';' before '{' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 218 Error 33 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Error 39 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Error 50 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Error 56 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Error 62 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2224 Error 69 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Error 75 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2310 Error 83 error C2078: too many initializers c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2321 Error 29 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Error 35 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Error 46 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Error 52 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Error 58 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2222 Error 65 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Error 71 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2309 Error 79 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2320 Error 88 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 75 Error 91 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 194 Error 99 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 211 Error 107 error C2065: 'stream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 230 Error 66 error C2065: 'metafile' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Error 28 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Error 34 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Error 45 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Error 51 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Error 57 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2222 Error 64 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2262 Error 70 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2309 Error 78 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2320 Error 87 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 75 Error 90 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 194 Error 98 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 211 Error 106 error C2065: 'IStream' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 230 Error 30 error C2065: 'image' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1133 Error 36 error C2065: 'image' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1139 Error 59 error C2065: 'header' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2224 Error 47 error C2065: 'bitmap' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1286 Error 53 error C2065: 'bitmap' : undeclared identifier c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1292 Error 12 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 443 Error 13 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 444 Error 14 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 445 Error 15 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 453 Error 41 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1244 Error 42 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1247 Error 43 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1250 Error 44 error C2061: syntax error : identifier 'PROPID' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1262 Error 9 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 384 Error 10 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 395 Error 11 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 405 Error 17 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 505 Error 18 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 516 Error 19 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 758 Error 20 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 813 Error 22 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 820 Error 24 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 829 Error 26 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusheaders.h 855 Error 40 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 1156 Error 63 error C2061: syntax error : identifier 'IStream' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2242 Error 86 error C2061: syntax error : identifier 'byte' c:\program files\microsoft sdks\windows\v7.0\include\gdipluspath.h 133 Error 5 error C2059: syntax error : 'public' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusimaging.h 74 Error 77 error C2059: syntax error : ')' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2316 Error 85 error C2059: syntax error : ')' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusflat.h 2327 Error 95 error C2059: syntax error : ')' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 198 Error 103 error C2059: syntax error : ')' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 217 Error 111 error C2059: syntax error : ')' c:\program files\microsoft sdks\windows\v7.0\include\gdiplusmetafile.h 236 I tried updating my sdk to 7.0 but it did not help. I'm not even making any calls to the API. Thanks

    Read the article

  • having a weird bug with mongrel - please help!

    - by Ethan
    this is from the development log... /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.5/lib/action_controller/dispatcher.rb:101:in `dispatch_cgi' /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.5/lib/action_controller/dispatcher.rb:27:in `dispatch' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:76:in `process' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:74:in `synchronize' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:74:in `process' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:159:in `process_client' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:158:in `each' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:158:in `process_client' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in `initialize' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in `new' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:in `initialize' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:in `new' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:282:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:281:in `each' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:281:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:128:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/command.rb:212:in `run' /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:281 /usr/bin/mongrel_rails:19:in `load' /usr/bin/mongrel_rails:19 /!\ FAILSAFE /!\ Thu Apr 15 20:19:18 +0000 2010 Status: 500 Internal Server Error please help - any ideas would be amazing - been stuck on trying to fix this thing for a week!

    Read the article

  • WPF binding to ComboBox SelectedItem when reference not in ItemsSource.

    - by juharr
    I'm binding the PageMediaSize collection of a PrintQueue to the ItemSource of a ComboBox (This works fine). Then I'm binding the SelectedItem of the ComboBox to the DefaultPrintTicket.PageMediaSize of the PrintQueue. While this will set the selected value to the DefaultPrintTicket.PageMediaSize just fine it does not set the initially selected value of the ComboBox to the initial value of DefaultPrintTicket.PageMediaSize This is because the DefaultPrintTicket.PageMediaSize reference does not match any of the references in the collection. However I don't want it to compare the objects by reference, but instead by value, but PageMediaSize does not override Equals (and I have no control over it). What I'd really like to do is setup a IComparable for the ComboBox to use, but I don't see any way to do that. I've tried to use a Converter, but I would need more than the value and I couldn't figured out how to pass the collection to the ConverterProperty. Any ideas on how to handle this problem. Here's my xaml <ComboBox x:Name="PaperSizeComboBox" ItemsSource="{Binding ElementName=PrintersComboBox, Path=SelectedItem, Converter={StaticResource printQueueToPageSizesConverter}}" SelectedItem="{Binding ElementName=PrintersComboBox, Path=SelectedItem.DefaultPrintTicket.PageMediaSize}" DisplayMemberPath="PageMediaSizeName" Height="22" Margin="120,76,15,0" VerticalAlignment="Top"/> And the code for the converter that gets the PageMediaSize collection public class PrintQueueToPageSizesConverter : IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { return value == null ? null : ((PrintQueue)value).GetPrintCapabilities().PageMediaSizeCapability; } public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { throw new NotImplementedException(); } }

    Read the article

  • ASP.NET MVC2: Client-side validation not working with Start.js

    - by Shaggy13spe
    Ok, this is strange. I would hope it's something I'm doing wrong and not that MS has two technologies that simply don't work together. (UPDATE: See bottom of post for Script tag order in HEAD section) I'm trying to use the dataView template and client-side validation. If I include a reference to: <script src="http://ajax.microsoft.com/ajax/beta/0911/Start.js" type="text/javascript"></script> by itself, the dataview template works fine. but if I put in the following references: <script src="http://ajax.microsoft.com/ajax/jquery.validate/1.7/jquery.validate.min.js" type="text/javascript"></script> <script src="../../Scripts/MicrosoftAjax.js" type="text/javascript"></script> <script src="../../Scripts/MicrosoftMvcAjax.js" type="text/javascript"></script> <script src="../../Scripts/MicrosoftMvcValidation.js" type="text/javascript"></script> then I get the following error: > Error: Type._registerScript is not a > function Source File: > http://ajax.microsoft.com/ajax/beta/0911/MicrosoftAjaxTemplates.js > Line: 1 and: > Error: Sys.get("$listings") is null > Source File: > http://localhost:12370/Listings Line: > 76 Here's the code calling the dataview: $(document).ready(function () { LoadMap(); Sys.require([Sys.components.dataView, Sys.scripts.jQuery], function() { $("#listings").dataView(); Sys.get("$listings").set_data(listings.Data); updateMap(listings.Data); }); }); I would really appreciate any help with this one. Thanks! UPDATE: I've tried moving around the order of the last 4 script tags, but to no avail.

    Read the article

  • RSolr RequestError Solr Response Severe errors in solr configuration

    - by manalang
    I was reindexing my model when I suddenly shutdown my mac, When I try to reindex again using (Model_name).reindex in script/console I encountered an error that I haven't encountered before. RSolr::RequestError: Solr Response: Severe_errors_in_solr_configuration__Check_your_log_files_for_more_detailed_information_on_what_may_be_wrong__If_you_want_solr_to_continue_after_configuration_errors_change____abortOnConfigurationErrorfalseabortOnConfigurationError__in_null___javalangRuntimeException_javaioIOException_read_past_EOF__at_orgapachesolrcoreSolrCoregetSearcherSolrCorejava1068__at_orgapachesolrcoreSolrCoreinitSolrCorejava579__at_orgapachesolrcoreCoreContainer$InitializerinitializeCoreContainerjava137__at_orgapachesolrservletSolrDispatchFilterinitSolrDispatchFilterjava83__at_orgmortbayjettyservletFilterHolderdoStartFilterHolderjava99__at_orgmortbaycomponentAbstractLifeCyclestartAbstractLifeCyclejava40__at_orgmortbayjettyservletServletHandlerinitializeServletHandlerjava594__at_orgmortbayjettyservletContextstartContextContextjava139__at_orgmortbayjettywebappWebAppContextstartContextWebAppContextjava1218__at_orgmortbayjettyhandlerContextHandlerdoStartContextHandlerjava500__at_orgmortbayjettywebappWebAppContextdoStartWebAppContextjava448__at_orgmortbaycomponentAbstractLifeCyclestartAbstractLifeCyclejava40__at_orgmortbayjettyhandlerHandlerCollectiondoStartHandlerCollectionjava147__at_orgmortbayjettyhandlerContextHandlerCollectiondoStartContextHandlerCollectionjava161__at_orgmortbaycomponentAbstractLifeCyclestartAbstractLifeCyclejava40__at_orgmortbayjettyhandlerHandlerCollectiondoStartHandlerCollectionjava147__at_orgmortbaycomponentAbstractLifeCyclestartAbstractLifeCyclejava40__at_orgmortbayjettyhandlerHandlerWrapperdoStartHandlerWrapperjava117__at_orgmortbayjettyServerdoStartServerjava210__at_orgmortbaycomponentAbstractLifeCyclestartAbstractLifeCyclejava40__at_orgmortbayxmlXmlConfigurationmainXmlConfigurationjava929__at_sunreflectNativeMethodAccessorImplinvoke0Native_Method__at_sun from /usr/local/lib/ruby/gems/1.8/gems/rsolr-0.12.1/lib/rsolr/connection/requestable.rb:39:in `request' from /usr/local/lib/ruby/gems/1.8/gems/rsolr-0.12.1/lib/rsolr/client.rb:34:in `request' from /usr/local/lib/ruby/gems/1.8/gems/rsolr-0.12.1/lib/rsolr/client.rb:22:in `update' from /usr/local/lib/ruby/gems/1.8/gems/rsolr-0.12.1/lib/rsolr/client.rb:76:in `delete_by_query' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot/indexer.rb:55:in `remove_all' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot/session.rb:173:in `remove_all' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot/session.rb:173:in `each' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot/session.rb:173:in `remove_all' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot/session_proxy/abstract_session_proxy.rb:11:in `remove_all' from /usr/local/lib/ruby/gems/1.8/gems/sunspot-1.1.0/lib/sunspot.rb:414:in `remove_all' from /Users/cecilleann/Projects/dhire2/vendor/plugins/sunspot_rails-1.1.0/lib/sunspot/rails/searchable.rb:164:in `solr_remove_all_from_index' from /Users/cecilleann/Projects/dhire2/vendor/plugins/sunspot_rails-1.1.0/lib/sunspot/rails/searchable.rb:183:in `reindex' from (irb):6 Now I haven't been able to fix the error. Please help me. I can't move one. Thanks a lot in advance

    Read the article

  • Java 1.5 crypto on OS X - AccessControlException

    - by bpapa
    I'm trying to do a Google App Engine project on OS X (latest and greatest). I'm using classes from javax.crypto, and I'm seeing an AccessControlException thrown when I try to initialize an instance of the Mac class. Here's the stack trace: WARNING: Nested in java.lang.ExceptionInInitializerError: java.security.AccessControlException: access denied (java.lang.RuntimePermission loadLibrary.keychain) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264) at java.security.AccessController.checkPermission(AccessController.java:427) at java.lang.SecurityManager.checkPermission(SecurityManager.java:532) at com.google.appengine.tools.development.DevAppServerFactory$CustomSecurityManager.checkPermission(DevAppServerFactory.java:76) at java.lang.SecurityManager.checkLink(SecurityManager.java:818) at java.lang.Runtime.loadLibrary0(Runtime.java:816) at java.lang.System.loadLibrary(System.java:993) at com.apple.crypto.provider.HmacCore.<clinit>(HmacCore.java:26) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:494) at java.lang.Class.newInstance0(Class.java:350) at java.lang.Class.newInstance(Class.java:303) at java.security.Provider$Service.newInstance(Provider.java:1130) at javax.crypto.Mac.a(DashoA12275) at javax.crypto.Mac.init(DashoA12275) Any ideas on 1 - what went wrong and how fix it 2 - if it's not fixable (I know Apple has not been the best supporter of Java in recent years), what's an alternative approach?

    Read the article

  • rails with fcgi error

    - by qichunren
    LoadError (Expected /web/zhao_backend2/app/controllers/admin_controller.rb to define AdminController): /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:249:in load_missing_constant' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:453:inconst_missing' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:465:in const_missing' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/inflector.rb:257:inconstantize' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/core_ext/string/inflections.rb:148:in constantize' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/routing.rb:1426:inrecognize' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:170:in handle_request' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:115:indispatch' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:126:in dispatch_cgi' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:9:indispatch' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:101:in process_request' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:149:inwith_signal_handler' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:99:in process_request' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:77:inprocess_each_request' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/fcgi-0.8.8/lib/fcgi.rb:612:in each_cgi' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/fcgi-0.8.8/lib/fcgi.rb:609:ineach' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/fcgi-0.8.8/lib/fcgi.rb:609:in each_cgi' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:76:inprocess_each_request' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:50:in process!' /usr/local/ruby-1.8.7-p248/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:24:inprocess!' /public/dispatch.fcgi:24 Rendering /web/zhao_backend2/public/500.html (500 Internal Server Error)

    Read the article

  • Help with SQL server stack dump

    - by edosoft
    Hi guru's We're running SQL 2005 standard SP2 on a 4cpu box. Suddenly it crashdumps, after which all pooled connections are invalid and it goes into admin-only mode (only sa can connect) The short stackdump is below. After the dump a number of errors show up like '2008-09-16 10:49:34.48 Server Resource Monitor (0xec4) Worker 0x03D1C0E8 appears to be non-yielding on Node 0. Memory freed: 232408 KB. Approx CPU Used: kernel 203 ms, user 140 ms, Interval: 250250.' Have Googled around but couldn't find a definate answer. Anyone? 2008-09-16 10:46:24.98 Server Using 'dbghelp.dll' version '4.0.5' 2008-09-16 10:46:25.40 Server **Dump thread - spid = 0, PSS = 0x00000000, EC = 0x00000000 2008-09-16 10:46:25.40 Server ***Stack Dump being sent to C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\LOG\SQLDump0009.txt 2008-09-16 10:46:25.40 Server * ******************************************************************************* 2008-09-16 10:46:25.40 Server * 2008-09-16 10:46:25.40 Server * BEGIN STACK DUMP: 2008-09-16 10:46:25.40 Server * 09/16/08 10:46:25 spid 0 2008-09-16 10:46:25.42 Server * 2008-09-16 10:46:25.42 Server * Non-yielding Resource Monitor 2008-09-16 10:46:25.42 Server * 2008-09-16 10:46:25.42 Server * ******************************************************************************* 2008-09-16 10:46:25.42 Server * ------------------------------------------------------------------------------- 2008-09-16 10:46:25.42 Server * Short Stack Dump 2008-09-16 10:46:25.76 Server Stack Signature for the dump is 0x00000352 2008-09-16 10:46:32.70 Server External dump process return code 0x20000001.

    Read the article

  • Prism - loading modules causes activation error

    - by Noich
    I've created a small Prism application (using MEF) with the following parts: - Infrastructure project, that contains a global file of region names. - Main project, that has 2 buttons to load other modules. - ModulesInterfaces project, where I've defined an IDataAccess interface for my DataAccess module. - DataAccess project, where there are several files but one main DataAccess class that implements both IDataAccess and IModule. When the user click a button, I want to show him a list of employees, so I need the DataAccess module. My code is as follows: var namesView = new EmployeesListView(); var namesViewModel = new EmployeesListViewModel(employeeRepository); namesView.DataContext = namesViewModel; namesViewModel.EmployeeSelected += EmployeeSelected; LocateManager(); manager.Regions["ContentRegion"].Add(new NoEmployeeView(), "noEmployee"); manager.Regions["NavigationRegion"].Add(namesView); I get an exception in my code when I'm trying to get DataAccess as a service (via ServiceLocator). I'm not sure if that's the right way to go, but trying to get it from the ModuleCatalog (as a type IDataAccess returns an empty enumeration). I'd appreciate some directions. Thanks. The problematic code line: object instance = ServiceLocator.Current.GetInstance(typeof(DataAccess.DataAccess)); The exact exception: Activation error occured while trying to get instance of type DataAccess, key "" The inner exception is null, the stack trace: at Microsoft.Practices.Prism.MefExtensions.MefServiceLocatorAdapter.DoGetInstance(Type serviceType, String key) in c:\release\WorkingDir\PrismLibraryBuild\PrismLibrary\Desktop\Prism.MefExtensions\MefServiceLocatorAdapter.cs:line 76 at Microsoft.Practices.ServiceLocation.ServiceLocatorImplBase.GetInstance(Type serviceType, String key) Edit The same exception is thrown for: container = (CompositionContainer)ServiceLocator.Current.GetInstance(typeof(CompositionContainer));

    Read the article

  • a scala remote actor exception

    - by kula
    hi all i with a scala code like this for echo service. import scala.actors.Actor import scala.actors.Actor._ import scala.actors.remote.RemoteActor._ class Echo extends Actor { def act() { alive(9010) register('myName, self) loop { react { case msg = println(msg) } } } } object EchoServer { def main(args: Array[String]): unit = { val echo = new Echo echo.start println("Echo server started") } } EchoServer.main(null) but there has some exception. java.lang.NoClassDefFoundError: Main$$anon$1$Echo$$anonfun$act$1 at Main$$anon$1$Echo.act((virtual file):16) at scala.actors.Reaction.run(Reaction.scala:76) at scala.actors.Actor$$anonfun$start$1.apply(Actor.scala:785) at scala.actors.Actor$$anonfun$start$1.apply(Actor.scala:783) at scala.actors.FJTaskScheduler2$$anon$1.run(FJTaskScheduler2.scala:160) at scala.actors.FJTask$Wrap.run(Unknown Source) at scala.actors.FJTaskRunner.scanWhileIdling(Unknown Source) at scala.actors.FJTaskRunner.run(Unknown Source) Caused by: java.lang.ClassNotFoundException: Main$$anon$1$Echo$$anonfun$act$1 at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) ... 8 more i don't konw how can cause it. by the way .my scala version is 2.7.5

    Read the article

  • Wrapping mailmessage headers in .net for Sendgrid

    - by mickyjtwin
    Am using SendGrid for some email notifications, specifically utilising their SMTP API's. While they have PHP examples, c# is not so helpful. Essentially, a json string is built that contains the to email addresses, and other custom filters etc, which is then added to a MailMessage header to send. // json string example {"to":["[email protected]", [email protected]", "", ""],"sub":{"<name>":["Name1", Name2"]}} MailMessage m = new MailMessage("[email protected]", "[email protected]"); m.Headers.Add("X-SMTPAPI", jsonString); The problem I am having is that for some MTA's, headers can only be 1000 characters long, and also quoted-principle encoding required only 76 character per line. In their php example, they are splitting the string and adding a linebreak (\n) every 72 characters. While I am doing this in .NET, I am receiving a invalid character exception. After some digging, it seems that pre-.NET4.0 Beta2 MailMessage will not process CLLR characters. Sengrid support is not proving helpful, and looking at ways to make this work?

    Read the article

  • Finding source of over release

    - by Benedict Lowndes
    Hi, I'm consistently seeing the same message sent in as a crash report from users of an app. It's clear that an object is being over-released but I'm unable to replicate it and I'm looking for tips on tracing the source of it. The relevant section from the crash report shows this: Application Specific Information: objc_msgSend() selector name: release Thread 0 Crashed: Dispatch queue: com.apple.main-thread 0 libobjc.A.dylib 0x90892edb objc_msgSend + 27 1 com.apple.CoreFoundation 0x95ec5a40 __CFBasicHashStandardCallback + 384 2 com.apple.CoreFoundation 0x95ec564e __CFBasicHashDrain + 478 3 com.apple.CoreFoundation 0x95ead6f1 _CFRelease + 353 4 com.apple.CoreFoundation 0x95eda0ed _CFAutoreleasePoolPop + 253 5 com.apple.Foundation 0x97ecedd6 NSPopAutoreleasePool + 76 6 com.apple.Foundation 0x97ececfe -[NSAutoreleasePool drain] + 130 7 com.apple.AppKit 0x9211255f -[NSApplication run] + 1013 8 com.apple.AppKit 0x9210a535 NSApplicationMain + 574 9 TheApp 0x000020a6 start + 54 I've used zombies and leaks, but haven't seen anything there. I've gone through the code and can't see it. What's the next step? Are there any hints I can discern from this information as to the source of it? Does the fact that this nearly exact same crash report is coming in repeatedly mean that it's the same object that's being over released, or because this is referring to the autorelease pool mean it could be any object? Does the reference to _CFRelease mean it's a Core Foundation object that's being over released?

    Read the article

  • Eclipse Galileo + Glassfish v3: JPADeployer NullPointerException on deploy

    - by bshacklett
    I've created a very simple "Enterprise Application" project with about 7 entity beans and one stateless session bean. I've also configured an instance of Glassfish v3 to run as my application server. Unfortunately, when I attempt to publish the EAR to Glassfish, I'm getting the following response: SEVERE: Exception while invoking class org.glassfish.persistence.jpa.JPADeployer prepare method java.lang.NullPointerException at org.glassfish.persistence.jpa.JPADeployer.prepare(JPADeployer.java:104) at com.sun.enterprise.v3.server.ApplicationLifecycle.prepareModule(ApplicationLifecycle.java:644) at org.glassfish.javaee.full.deployment.EarDeployer.prepareBundle(EarDeployer.java:269) at org.glassfish.javaee.full.deployment.EarDeployer.access$200(EarDeployer.java:79) at org.glassfish.javaee.full.deployment.EarDeployer$1.doBundle(EarDeployer.java:131) at org.glassfish.javaee.full.deployment.EarDeployer$1.doBundle(EarDeployer.java:129) at org.glassfish.javaee.full.deployment.EarDeployer.doOnBundles(EarDeployer.java:197) at org.glassfish.javaee.full.deployment.EarDeployer.doOnAllTypedBundles(EarDeployer.java:206) at org.glassfish.javaee.full.deployment.EarDeployer.doOnAllBundles(EarDeployer.java:232) at org.glassfish.javaee.full.deployment.EarDeployer.prepare(EarDeployer.java:129) at com.sun.enterprise.v3.server.ApplicationLifecycle.prepareModule(ApplicationLifecycle.java:644) at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:296) at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:183) at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:272) at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:305) at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:320) at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1176) at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$900(CommandRunnerImpl.java:83) at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235) at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1224) at com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:365) at com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:204) at com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:166) at com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:100) at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:245) at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791) at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693) at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954) at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170) at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88) at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76) at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53) at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57) at com.sun.grizzly.ContextTask.run(ContextTask.java:69) at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330) at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309) at java.lang.Thread.run(Thread.java:637)

    Read the article

  • ruby gem not found although it is installed

    - by Eimantas
    I found some similar problems here on SO, but none seem to match my case (sorry if I overlooked). Here's my problem: I installed oauth-plugin gem to ruby gems dir, but trying to use it in rails app tells me that it's not being found. Here's the output of relevant commands: Instalation % s gem install oauth-plugin Successfully installed oauth-plugin-0.3.14 1 gem installed Installing ri documentation for oauth-plugin-0.3.14... Installing RDoc documentation for oauth-plugin-0.3.14... gem which oauth-plugin output: % gem which oauth-plugin /usr/lib/ruby/gems/1.8/gems/oauth-plugin-0.3.14/lib/oauth-plugin.rb gem env output: % gem env RubyGems Environment: - RUBYGEMS VERSION: 1.3.6 - RUBY VERSION: 1.8.7 (2009-12-24 patchlevel 248) [i686-darwin10.2.0] - INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.8 - RUBY EXECUTABLE: /usr/bin/ruby - EXECUTABLE DIRECTORY: /usr/bin - RUBYGEMS PLATFORMS: - ruby - x86-darwin-10 - GEM PATHS: - /usr/lib/ruby/gems/1.8 - /Users/eimantas/.gem/ruby/1.8 - GEM CONFIGURATION: - :update_sources => true - :verbose => true - :benchmark => false - :backtrace => true - :bulk_threshold => 1000 - :gem => ["--no-ri", "--no-rdoc"] - :sources => ["http://gems.ruby.lt/", "http://rubygems.org/"] - REMOTE SOURCES: - http://gems.ruby.lt/ - http://rubygems.org/ Doing ls -l /usr/lib/ruby shows this: % ls -l /usr/lib/ruby lrwxr-xr-x 1 root wheel 76 Aug 14 2009 /usr/lib/ruby -> ../../System/Library/Frameworks/Ruby.framework/Versions/Current/usr/lib/ruby And the gem in question is in intended location. This is not a single gem that is not being found by rubygems (although it's located where it should be). Any guidance towards the solution is much appreciated.

    Read the article

  • Virtual Lan on the Cloud -- Help Confirm my understanding?

    - by marfarma
    [Note: Tried to post this over at ServerFault, but I don't have enough 'points' for more than one link. Powers that be, move this question over there.] Please give this a quick read and let me know if I'm missing something before I start trying to make this work. I'm not a systems admin professional, and I'd hate to end up banging my head into the wall if I can avoid it. Goals: Create a 'road-warrior' capable star shaped virtual LAN for consultants who spend the majority of their time on client sites, and who's firm has no physical network or servers. Enable CIFS access to a cloud-server based installation of Alfresco Allow Eventual implementation of some form of single-sign-on ( OpenLDAP server ) access to Alfresco and other server applications implemented in the future Given: All Servers will live in the public internet cloud (Rackspace Cloud Servers) OpenVPN Server will be a Linux disto, probably Ubuntu 9.x, installed on same server as Alfresco (at least to start) Staff will access server applications and resources from client sites, hotels, trains, planes, coffee shops or their homes over various ISP, using their company laptops or personal home desktops. Based on my Research thus far, to accomplish this, I'll need: OpenVPN with Bridging Enabled to create a star shaped "virtual" LAN http://openvpn.net/index.php/open-source/documentation/miscellaneous/76-ethernet-bridging.html A Road Warrior Network Configuration, as described in this Shorewall article (lower down the page) http://www.shorewall.net/OPENVPN.html Configure bridge addressesing (probably DHCP) http://openvpn.net/index.php/open-source/faq.html#bridge-addressing Configure CIFS / Samba to accept VPN IP address http://serverfault.com/questions/137933/howto-access-samba-share-over-vpn-tunnel Set up Client software, with keys configured for access (potentially through a OpenVPN-Sa client portal) http://www.openvpn.net/index.php/access-server/download-openvpn-as/221-installation-overview.html

    Read the article

  • Trouble with Berkeley DB JE Base API Secondary Databases and Sequences

    - by milosz
    I have a class Document which consists of Id (int) and Url (String). I would like to have a primary index on Id and secondary index on Url. I would also like to have a sequence for Id auto-incrementation. So I create a SecondaryDatabase and then I create a Sequence. During initialisation of the Sequence I get an exception: Exception in thread "main" java.lang.IllegalArgumentException at com.sleepycat.util.UtfOps.getCharLength(UtfOps.java:137) at com.sleepycat.util.UtfOps.bytesToString(UtfOps.java:259) at com.sleepycat.bind.tuple.TupleInput.readString(TupleInput.java:152) at pl.edu.mimuw.zbd.berkeley.zadanie.rozwiazanie.MyDocumentBiding.entryToObject(MyDocumentBiding.java:12) at pl.edu.mimuw.zbd.berkeley.zadanie.rozwiazanie.MyDocumentBiding.entryToObject(MyDocumentBiding.java:1) at com.sleepycat.bind.tuple.TupleBinding.entryToObject(TupleBinding.java:76) at pl.edu.mimuw.zbd.berkeley.zadanie.rozwiazanie.UrlKeyCreator.createSecondaryKey(UrlKeyCreator.java:20) at com.sleepycat.je.SecondaryDatabase.updateSecondary(SecondaryDatabase.java:835) at com.sleepycat.je.SecondaryTrigger.databaseUpdated(SecondaryTrigger.java:42) at com.sleepycat.je.Database.notifyTriggers(Database.java:2004) at com.sleepycat.je.Cursor.putNotify(Cursor.java:1692) at com.sleepycat.je.Cursor.putInternal(Cursor.java:1616) at com.sleepycat.je.Cursor.putNoOverwrite(Cursor.java:663) at com.sleepycat.je.Sequence.<init>(Sequence.java:188) at com.sleepycat.je.Database.openSequence(Database.java:546) at pl.edu.mimuw.zbd.berkeley.zadanie.rozwiazanie.MyFullTextSearchEngine.init(MyFullTextSearchEngine.java:131) at pl.edu.mimuw.zbd.berkeley.zadanie.testy.MyFullTextSearchEngineTest.main(MyFullTextSearchEngineTest.java:18) It seems that during the initialisation of the sequence the secondary database is forced to update. When I debug the entryToObject method of MyDocumentBiding the bytes that it tries to convert to object seem random. What am I doing wrong?

    Read the article

  • Rails - Logic for finding info from a :has_many :through needed!

    - by Jty.tan
    I have 3 relevant tables. User, Orders, and Viewables The idea is that each User has got many Orders, but at the same time, each User can View specific other Orders that belong to other Users. So Viewables has the attributes of user_id and order_id. Orders has a :has_many :Users, :through => :viewables Is it possible to do a find through an Order's view? So something like @viewable_orders = Orders.find(:all, :conditions = ["Viewable.user_id=?",1]) To get a list of Orders which are viewable by user_id=1. (This doesn't work, else I won't be asking. :( ) The idea being that I can do something like a sidebar where the current user (the logged-in one) can view a list of other people's orders that he can view. For example Three other Users who have some Orders that he can view should be eventually displayed like this: Jack (2) Basic Order (registry_id: 1) New Order (registry_id: 29) Amy (4) Short Order (registry_id: 12) Jill (5) Hardware Order (14) Pink Order (17) Software Order (76) (The number in brackets are the respective user_id or registry_id) So to find the list of all of the orders that the current user can find (assuming user_id of the current user is 1), would be found by doing @viewable_orders = Viewable.find(:all, :conditions => ["user_id=?", 1]) And that would give me the collection of the above 6 registries. Now, the easiest way to do this, is for me to just have a list of + Jill's Hardware Order + Jill's Pink Order + Amy's Short Order + etc But that gets ugly for long lists. Thanks!

    Read the article

  • How do you configure jax-ws to work with Spring using jax-ws commons?

    - by LES2
    In web.xml I have the following: <servlet> <description>JAX-WS endpoint - EARM</description> <display-name>jaxws-servlet</display-name> <servlet-name>jaxws-servlet</servlet-name> <servlet-class>com.sun.xml.ws.transport.http.servlet.WSSpringServlet</servlet-class> </servlet> <servlet-mapping> <servlet-name>jaxws-servlet</servlet-name> <url-pattern>/webServices/*</url-pattern> </servlet-mapping> In my application context I have the following definitions: <bean id="helloService" class="com.foo.HelloServiceImpl"> <property name="regularService" ref="regularService" /> </bean> <wss:binding url="/webServices/helloService" service="#helloService" /> I get a NullPointerException when trying to access the WSDL: java.lang.NullPointerException at com.sun.xml.ws.transport.http.HttpAdapter.<init>(HttpAdapter.java:145) at com.sun.xml.ws.transport.http.servlet.ServletAdapter.<init>(ServletAdapter.java:76) at com.sun.xml.ws.transport.http.servlet.ServletAdapterList.createHttpAdapter(ServletAdapterList.java:5 0) at com.sun.xml.ws.transport.http.servlet.ServletAdapterList.createHttpAdapter(ServletAdapterList.java:4 7) at com.sun.xml.ws.transport.http.HttpAdapterList.createAdapter(HttpAdapterList.java:73) at com.sun.xml.ws.transport.http.servlet.SpringBinding.create(SpringBinding.java:24) at com.sun.xml.ws.transport.http.servlet.WSSpringServlet.init(WSSpringServlet.java:46) Strange ... appears to be a configuration error but the darn thing just dies with a NullPointerException!!!!!!!! No logging is provided. Deployed in Resin.

    Read the article

  • Why This Maintainability Index Increase?

    - by Timothy
    I would be appreciative if someone could explain to me the difference between the following two pieces of code in terms of Visual Studio's Code Metrics rules. Why does the Maintainability Index increase slightly if I don't encapsulate everything within using ( )? Sample 1 (MI score of 71) public static String Sha1(String plainText) { using (SHA1Managed sha1 = new SHA1Managed()) { Byte[] text = Encoding.Unicode.GetBytes(plainText); Byte[] hashBytes = sha1.ComputeHash(text); return Convert.ToBase64String(hashBytes); } } Sample 2 (MI score of 73) public static String Sha1(String plainText) { Byte[] text, hashBytes; using (SHA1Managed sha1 = new SHA1Managed()) { text = Encoding.Unicode.GetBytes(plainText); hashBytes = sha1.ComputeHash(text); } return Convert.ToBase64String(hashBytes); } I understand metrics are meaningless outside of a broader context and understanding, and programmers should exercise discretion. While I could boost the score up to 76 with return Convert.ToBase64String(sha1.ComputeHash(Encoding.Unicode.GetBytes(plainText))), I shouldn't. I would clearly be just playing with numbers and it isn't truly any more readable or maintainable at that point. I am curious though as to what the logic might be behind the increase in this case. It's obviously not line-count.

    Read the article

  • Encoding h.264 with libavcodec/x264

    - by Leviathan
    I am attempting to encode video using libavcodec/libavformat. I'm trying to change the standard output-example.c from ffmpeg source. The AVI file is created on the disk, but the only sound is encoded. I tried adding a lot of options for x264 from here. All the other codecs works fine, mpeg2, mpeg4, mjpeg, xvid. In addition to specifying the parameters x264, I also set the codec to AVOutputFormat structure. That's all I've done. AVOutputFormat *pOutFormat; // in header file av_register_all(); AVCodec *codec = avcodec_find_encoder_by_name("libx264"); pOutFormat = guess_format("avi", NULL, NULL); pOutFormat->video_codec = codec->id; The debug output of my application: Output #0, mp4, to 'D:\1.avi': Stream #0.0: Video: libx264, yuv420p, 320x240, q=10-51, 500 kb/s, 90k tbn, 25 tbc Stream #0.1: Audio: aac, 44100 Hz, 1 channels, s16, 128 kb/s [libx264 @ 0x694010]using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2 [libx264 @ 0x694010]bitrate tolerance too small, using .01 [libx264 @ 0x694010]profile Main, level 2.0 [libx264 @ 0x694010]frame I:150 Avg QP:14.76 size: 2534 [libx264 @ 0x694010]mb I I16..4: 75.9% 0.0% 24.1% [libx264 @ 0x694010]final ratefactor: 17.57 [libx264 @ 0x694010]coded y,uvDC,uvAC intra: 42.7% 92.4% 47.4% [libx264 @ 0x694010]i16 v,h,dc,p: 11% 14% 2% 73% [libx264 @ 0x694010]i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 18% 29% 5% 8% 10% 3% 3% 2% [libx264 @ 0x694010]kb/s:506.79

    Read the article

< Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >